ActiveRecord_Association_HasManyImplements the has_many association
Located in /activerecord/lib/ActiveRecord/Association/HasMany.php (line 9)
ActiveRecord_Association | --ActiveRecord_Association_HasMany
ActiveRecord_Association_HasMany
__construct
(ActiveRecord_Base $record, ActiveRecord_Proxy $proxy, string $name, array $options)
ActiveRecord_Base
build_associate
(ActiveRecord_Base $record, ActiveRecord_Proxy $proxy, array $attributes)
ActiveRecord_Base
create_associate
(ActiveRecord_Base $record, ActiveRecord_Proxy $proxy, array $attributes)
ActiveRecord_Association_Collection
get_associates
(ActiveRecord_Base $record, ActiveRecord_Proxy $proxy, [boolean $force_reload = false])
void
set_associates
(ActiveRecord_Base $record, ActiveRecord_Proxy $proxy, array $values, [boolean $skipKeyUpdates = false])
static mixed
$creation_options
= array('class_name'=>1, 'foreign_key'=>1, 'primary_key'=>1, 'order'=>1) (line 14)
List of valid options for creation
mixed
$order
(line 17)
mixed
$primary_key
(line 16)
Inherited from ActiveRecord_Association
ActiveRecord_Association::$class_name
ActiveRecord_Association::$foreign_key
ActiveRecord_Association::$name
Constructor __construct (line 27)
Constructor
add_associate (line 177)
Add an associated object to this object's collection. This method handles database updates and foreign keys. It does not directly affect the contents of an association collection object.
after_create (line 285)
Check the associates to make sure they have been saved
after_save (line 299)
Check the associates to make sure they have been saved
build_associate (line 318)
Build a new associated object from an associative array of attributes and assign it to the object. This method handles database updates and foreign keys. It does not directly affect the contents of an association collection object.
count_associates (line 99)
Called by the collection object to count the associated objects without loading them.
create_associate (line 341)
Create and save a new associated object from an associative array of attributes and assign it to the object. This method handles database updates and foreign keys. It does not directly affect the contents of an association collection object.
do_include (line 359)
Implements the 'include' behavior for a find operation
find_all (line 224)
Similar to ActiveRecord_Base::find_all(), but limited to items within this collection.
get_associates (line 66)
Accessor method for the associated objects
get_associate_ids (line 254)
Accessor method for the associated object ids
load_associates (line 81)
Called by the collection object to load the actual associated objects.
primary_key (line 56)
Return the primary key name for this association
remove_associate (line 200)
Remove an associated object from this object's collection. This method handles database updates and foreign keys. It does not directly affect the contents of an association collection object.
set_associates (line 117)
Mutator method for the entire collection of associated objects
set_associate_ids (line 269)
Mutator method for the entire collection of associated objects by ids
Inherited From ActiveRecord_Association
ActiveRecord_Association::class_name()
ActiveRecord_Association::do_include()
ActiveRecord_Association::foreign_key()
ActiveRecord_Association::name()
Documentation generated on Wed, 25 Apr 2012 09:46:43 -0700 by phpDocumentor 1.4.3