Definition at line 11 of file AttributeLoader.php.
Elgg_AttributeLoader::__construct |
( |
|
$class, |
|
|
|
$required_type, |
|
|
array |
$initialized_attrs |
|
) |
| |
Constructor.
- Parameters
-
string | $class | class of object being loaded |
string | $required_type | entity type this is being used to populate |
array | $initialized_attrs | attributes after initializeAttributes() has been run |
- Exceptions
-
Definition at line 113 of file AttributeLoader.php.
Elgg_AttributeLoader::checkType |
( |
|
$row | ) |
|
|
protected |
Check that the type is correct.
- Parameters
-
- Returns
- void
- Exceptions
-
Definition at line 156 of file AttributeLoader.php.
Elgg_AttributeLoader::filterAddedColumns |
( |
|
$row | ) |
|
|
protected |
Filter non-attribute keys into $this->additional_select_values.
- Parameters
-
array | $row | All columns from the query |
- Returns
- array Columns acceptable for the entity's attributes
Definition at line 269 of file AttributeLoader.php.
Elgg_AttributeLoader::getAdditionalSelectValues |
( |
| ) |
|
Get values selected from the database that are not attributes.
- Returns
- array
Definition at line 168 of file AttributeLoader.php.
Elgg_AttributeLoader::getRequiredAttributes |
( |
|
$row | ) |
|
Get all required attributes for the entity, validating any that are passed in.
Returns empty array if can't be loaded (Check $failure_reason).
This function splits loading between "primary" attributes (those in {prefix}entities table) and "secondary" attributes (e.g. those in {prefix}objects_entity), but can load all at once if a combined loader is available.
- Parameters
-
mixed | $row | a row loaded from DB (array or stdClass) or a GUID |
- Returns
- array will be empty if failed to load all attributes (access control or entity doesn't exist)
- Exceptions
-
InvalidArgumentException|LogicException|IncompleteEntityException | |
Definition at line 185 of file AttributeLoader.php.
Elgg_AttributeLoader::isMissingPrimaries |
( |
|
$row | ) |
|
|
protected |
Get primary attributes missing that are missing.
- Parameters
-
- Returns
- array
Definition at line 135 of file AttributeLoader.php.
Elgg_AttributeLoader::isMissingSecondaries |
( |
|
$row | ) |
|
|
protected |
Get secondary attributes that are missing.
- Parameters
-
- Returns
- array
Definition at line 145 of file AttributeLoader.php.
Elgg_AttributeLoader::$additional_select_values = array() |
|
protected |
Elgg_AttributeLoader::$class |
|
protected |
Elgg_AttributeLoader::$full_loader = '' |
Elgg_AttributeLoader::$initialized_attributes |
|
protected |
Elgg_AttributeLoader::$integer_attr_names |
|
staticprotected |
Initial value:= array(
'guid',
'owner_guid',
'container_guid',
'site_guid',
'access_id',
'time_created',
'time_updated',
'last_action',
'prev_last_action',
'last_login',
'prev_last_login'
)
Definition at line 35 of file AttributeLoader.php.
Elgg_AttributeLoader::$null_attr_names |
|
staticprotected |
Initial value:= array(
'name',
'title',
'description',
'url',
)
Definition at line 53 of file AttributeLoader.php.
Elgg_AttributeLoader::$primary_attr_names |
|
staticprotected |
Initial value:= array(
'guid',
'type',
'subtype',
'owner_guid',
'container_guid',
'site_guid',
'access_id',
'time_created',
'time_updated',
'last_action',
'enabled',
)
Definition at line 18 of file AttributeLoader.php.
Elgg_AttributeLoader::$required_type |
|
protected |
Elgg_AttributeLoader::$requires_access_control = true |
Elgg_AttributeLoader::$secondary_attr_names = array() |
|
protected |
Elgg_AttributeLoader::$secondary_loader = '' |
The documentation for this class was generated from the following file: