|
Elgg
Version 2.3
|
Preload entities based on properties of fetched objects. More...
Public Member Functions | |
| __construct (EntityCache $entity_cache, EntityTable $entity_table) | |
| Constructor. More... | |
| preload ($objects, array $guid_properties) | |
| Preload entities based on the given objects. More... | |
Public Attributes | |
| $_callable_cache_checker | |
| $_callable_entity_loader | |
Protected Member Functions | |
| getGuidsToLoad ($objects, array $guid_properties) | |
| Get GUIDs that need to be loaded. More... | |
Preload entities based on properties of fetched objects.
@access private
Definition at line 13 of file EntityPreloader.php.
| Elgg\EntityPreloader::__construct | ( | EntityCache | $entity_cache, |
| EntityTable | $entity_table | ||
| ) |
Constructor.
| EntityCache | $entity_cache | Entity cache |
| EntityTable | $entity_table | Entity service |
Definition at line 33 of file EntityPreloader.php.
|
protected |
Get GUIDs that need to be loaded.
To simplify the user API, this function accepts non-arrays and arrays containing non-objects
| object[] | $objects | Objects from which to pluck GUIDs |
| string[] | $guid_properties | e.g. array("owner_guid") |
Definition at line 72 of file EntityPreloader.php.
| Elgg\EntityPreloader::preload | ( | $objects, | |
| array | $guid_properties | ||
| ) |
Preload entities based on the given objects.
| object[] | $objects | Objects–e.g. loaded from an Elgg query–from which we can pluck GUIDs to preload |
| string[] | $guid_properties | e.g. array("owner_guid") |
Definition at line 51 of file EntityPreloader.php.
| Elgg\EntityPreloader::$_callable_cache_checker |
Definition at line 19 of file EntityPreloader.php.
| Elgg\EntityPreloader::$_callable_entity_loader |
Definition at line 25 of file EntityPreloader.php.