TPropertyAccess class provides dot notation stype property access and setting.
Access object's properties (and subproperties) using dot path notation. The following are equivalent.
- echo $obj->property1;
- echo $obj->getProperty1();
- echo $obj['property1']; //$obj may be an array or object
- echo TPropertyAccess($obj, 'property1');
Setting a property value.
- $obj1->propert1 = 'hello';
- $obj->setProperty('hello');
- $obj['property1'] = 'hello'; //$obj may be an array or object
- TPropertyAccess($obj, 'property1', 'hello');
Subproperties are supported using the dot notation. E.g.
- echo $obj->property1->property2->property3
- echo TPropertyAccess::get($obj, 'property1.property2.property3');
Located in /Data/SqlMap/DataMapper/TPropertyAccess.php (line 44)
Gets the property value.
Sets the property value.
Documentation generated on Mon, 21 Apr 2008 11:35:54 -0400 by phpDocumentor 1.3.0RC4