PropertyManager: Difference between revisions

From Sunhill Framework Documentation
+Incomplete
 
+ Creating a property
Line 1: Line 1:
{{Incomplete}}
{{Incomplete}}
== Creating a property ==
For creating a property there is the createProperty() method. This takes three parameters
=== Parameter "property" ===
This parameter could be:
* The instance of a property
* A string, then it could be
** The fully qualified class name (including namespace) of a property
** The name of a class
=== Parameter "name" ===
Is a string that gives the name of the property
=== Parameter "storage" ===
This parameter could be:
* null then a storage must be defined internally or explicitly via setStorage()
* the instance of a storage
* a string of the fully qualified class name (including namespace) of a storage
* a callable closure. Then a [[CallbackStorage]] is created and this closure passed as a callback
[[Category:Properties]]
[[Category:Facade]]

Revision as of 13:37, 22 October 2024


This page is incomplete

Creating a property

For creating a property there is the createProperty() method. This takes three parameters

Parameter "property"

This parameter could be:

  • The instance of a property
  • A string, then it could be
    • The fully qualified class name (including namespace) of a property
    • The name of a class

Parameter "name"

Is a string that gives the name of the property

Parameter "storage"

This parameter could be:

  • null then a storage must be defined internally or explicitly via setStorage()
  • the instance of a storage
  • a string of the fully qualified class name (including namespace) of a storage
  • a callable closure. Then a CallbackStorage is created and this closure passed as a callback