diff options
author | wei <> | 2007-04-30 03:44:49 +0000 |
---|---|---|
committer | wei <> | 2007-04-30 03:44:49 +0000 |
commit | ea0601cdd4a732fc15b83104a47788989bb004b3 (patch) | |
tree | 3366e670cc904001c02f71f969fcedd90129f6a9 /framework/Data/ActiveRecord/Relations/TActiveRecordHasMany.php | |
parent | 970057f16ae4ca2a85ad6710c0d6e371f0bf003d (diff) |
Reverted TActiveRecord::populateObject to protected
Diffstat (limited to 'framework/Data/ActiveRecord/Relations/TActiveRecordHasMany.php')
-rw-r--r-- | framework/Data/ActiveRecord/Relations/TActiveRecordHasMany.php | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/framework/Data/ActiveRecord/Relations/TActiveRecordHasMany.php b/framework/Data/ActiveRecord/Relations/TActiveRecordHasMany.php index 27ffd194..795630ab 100644 --- a/framework/Data/ActiveRecord/Relations/TActiveRecordHasMany.php +++ b/framework/Data/ActiveRecord/Relations/TActiveRecordHasMany.php @@ -17,14 +17,14 @@ Prado::using('System.Data.ActiveRecord.Relations.TActiveRecordRelation'); /**
* Implements TActiveRecord::HAS_MANY relationship between the source object having zero or
- * more foreign objects. Consider the relationship between a Team and a Player.
+ * more foreign objects. Consider the <b>entity</b> relationship between a Team and a Player.
* <code>
* +------+ +--------+
- * | Team | 1 -----> * | Player |
+ * | Team | 1 <----- * | Player |
* +------+ +--------+
* </code>
* Where one team may have 0 or more players and each player belongs to only
- * one team. We may model Team-Player relationship as active record as follows.
+ * one team. We may model Team-Player <b>object</b> relationship as active record as follows.
* <code>
* class TeamRecord extends TActiveRecord
* {
@@ -44,15 +44,7 @@ Prado::using('System.Data.ActiveRecord.Relations.TActiveRecordRelation'); * }
* class PlayerRecord extends TActiveRecord
* {
- * const TABLE='player';
- * public $player_id; //primary key
- * public $team_name; //foreign key player.team_name <-> team.name
- * public $age;
- *
- * public static function finder($className=__CLASS__)
- * {
- * return parent::finder($className);
- * }
+ * // see TActiveRecordBelongsTo for detailed definition
* }
* </code>
* The <tt>$RELATIONS</tt> static property of TeamRecord defines that the
|