PHP Unframework
PHP Unframework
Adds JSON functionality to fActiveRecord and fRecordSet
| 1.0.0b3 | Removed the $pointer parameter from toJSONRecordSet() since fRecordSet no longer has a pointer 9/28/10 |
|---|---|
| 1.0.0b2 | Updated the code to remove the $associate parameter for the record set method callback 6/2/09 |
| 1.0.0b | The initial implementation 6/25/08 |
Please note: this method is public, however it is primarily intended for internal use by Flourish and will normally not be useful in site/application code
Adjusts the fActiveRecord::reflect() signatures of columns that have been added by this class
void reflect( string $class, array &$signatures, boolean $include_doc_comments )
| string | $class | The class to reflect |
| array | &$signatures | The associative array of {method name} => {signature} |
| boolean | $include_doc_comments | If doc comments should be included with the signature |
Please note: this method is public, however it is primarily intended for internal use by Flourish and will normally not be useful in site/application code
Returns a JSON object representation of the record
string toJSON( fActiveRecord $object, array &$values, array &$old_values, array &$related_records, array &$cache, string $method_name, array $parameters )
| fActiveRecord | $object | The fActiveRecord instance |
| array | &$values | The current values |
| array | &$old_values | The old values |
| array | &$related_records | Any records related to this record |
| array | &$cache | The cache array for the record |
| string | $method_name | The method that was called |
| array | $parameters | The parameters passed to the method |
The JSON object that represents the values of this record
Please note: this method is public, however it is primarily intended for internal use by Flourish and will normally not be useful in site/application code
Returns a JSON object representation of a record set
string toJSONRecordSet( fRecordSet $record_set, string $class, array &$records )
| fRecordSet | $record_set | The fRecordSet instance |
| string | $class | The class of the records |
| array | &$records | The fActiveRecord objects |
The JSON object that represents an array of all of the fActiveRecord objects