Base class for active record relationships.
Located in /Data/ActiveRecord/Relations/TActiveRecordRelation.php (line 26)
Class | Description |
---|---|
TActiveRecordBelongsTo | Implements the foreign key relationship (TActiveRecord::BELONGS_TO) between the source objects and the related foreign object. Consider the entity relationship between a Team and a Player. |
TActiveRecordHasMany | Implements TActiveRecord::HAS_MANY relationship between the source object having zero or more foreign objects. Consider the entity relationship between a Team and a Player. |
TActiveRecordHasManyAssociation | Implements the M-N (many to many) relationship via association table. |
TActiveRecordHasOne | TActiveRecordHasOne models the object relationship that a record (the source object) property is an instance of foreign record object having a foreign key related to the source object. The HAS_ONE relation is very similar to the HAS_MANY relationship (in fact, it is equivalent in the entities relationship point of view). |
Fetch results for current relationship.
Returns foreign keys in $fromRecord with source column names as key and foreign column names in the corresponding $matchesRecord as value.
The method returns the first matching foreign key between these 2 records.
Fetches the foreign objects using TActiveRecord::findAllByIndex()
Obtain the foreign key index values from the results.
Populate the results with the foreign objects found.
Sets the foreign objects to the given property on the source object.
Populates the result array with foreign objects (matched using foreign key hashed property values).
Dispatch the method calls to the source record finder object. When an instance of TActiveRecord or an array of TActiveRecord is returned the corresponding foreign objects are also fetched and assigned.
Multiple relationship calls can be chain together.
Documentation generated on Mon, 21 Apr 2008 11:29:56 -0400 by phpDocumentor 1.3.0RC4