TaxonomyTermController::cacheGet
protected function TaxonomyTermController::cacheGet
protected TaxonomyTermController::cacheGet($ids, $conditions = array())
Gets entities from the static cache.
Parameters
$ids: If not empty, return entities that match these IDs.
$conditions: If set, return entities that match all of these conditions.
Return value
Array of entities from the entity cache.
Overrides DrupalDefaultEntityController::cacheGet
File
- modules/taxonomy/taxonomy.module, line 1269
- Enables the organization of content into categories.
Class
- TaxonomyTermController
- Controller class for taxonomy terms.
Code
protected function cacheGet($ids, $conditions = array()) { $terms = parent::cacheGet($ids, $conditions); // Name matching is case insensitive, note that with some collations // LOWER() and drupal_strtolower() may return different results. foreach ($terms as $term) { $term_values = (array) $term; if (isset($conditions['name']) && drupal_strtolower($conditions['name'] != drupal_strtolower($term_values['name']))) { unset($terms[$term->tid]); } } return $terms; }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!taxonomy!taxonomy.module/function/TaxonomyTermController::cacheGet/7.x