TermTranslationHandler

Defines the translation handler for terms. Hierarchy class \Drupal\content_translation\ContentTranslationHandler implements ContentTranslationHandlerInterface, EntityHandlerInterface uses DependencySerializationTraitclass \Drupal\taxonomy\TermTranslationHandler File core/modules/taxonomy/src/TermTranslationHandler.php, line 12 Namespace Drupal\taxonomy Members Name Modifiers Type Description ContentTranslationHandler::$currentUser protected property The current user.

TermStorageSchema::getSharedTableFieldSchema

protected TermStorageSchema::getSharedTableFieldSchema(FieldStorageDefinitionInterface $storage_definition, $table_name, array $column_mapping) Gets the schema for a single field definition. Entity types may override this method in order to optimize the generated schema for given field. While all optimizations that apply to a single field have to be added here, all cross-field optimizations should be via SqlContentEntityStorageSchema::getEntitySchema() instead; e.g., an index spanning multiple

TermStorageSchema

Defines the term schema handler. Hierarchy class \Drupal\Core\Entity\Sql\SqlContentEntityStorageSchema implements DynamicallyFieldableEntityStorageSchemaInterface uses DependencySerializationTraitclass \Drupal\taxonomy\TermStorageSchema File core/modules/taxonomy/src/TermStorageSchema.php, line 12 Namespace Drupal\taxonomy Members Name Modifiers Type Description DependencySerializationTrait::$_serviceIds protected property An array of service IDs keyed by property name

TermStorageSchema::getEntitySchema

protected TermStorageSchema::getEntitySchema(ContentEntityTypeInterface $entity_type, $reset = FALSE) Gets the entity schema for the specified entity type. Entity types may override this method in order to optimize the generated schema of the entity tables. However, only cross-field optimizations should be added here; e.g., an index spanning multiple fields. Optimizations that apply to a single field have to be added via SqlContentEntityStorageSchema::getSharedTableFieldSchema() instead. Parame

TermStorageInterface::loadTree

public TermStorageInterface::loadTree($vid, $parent = 0, $max_depth = NULL, $load_entities = FALSE) Finds all terms in a given vocabulary ID. Parameters string $vid: Vocabulary ID to retrieve terms for. int $parent: The term ID under which to generate the tree. If 0, generate the tree for the entire vocabulary. int $max_depth: The number of levels of the tree to return. Leave NULL to return all levels. bool $load_entities: If TRUE, a full entity load will occur on the term objects. Otherwise t

TermStorageInterface::updateTermHierarchy

public TermStorageInterface::updateTermHierarchy(EntityInterface $term) Updates terms hierarchy information with the hierarchy trail of it. Parameters \Drupal\Core\Entity\EntityInterface $term: Term entity that needs to be added to term hierarchy information. File core/modules/taxonomy/src/TermStorageInterface.php, line 27 Class TermStorageInterface Defines an interface for taxonomy_term entity storage classes. Namespace Drupal\taxonomy Code public function updateTermHierarchy(EntityI

TermStorageInterface::resetWeights

public TermStorageInterface::resetWeights($vid) Reset the weights for a given vocabulary ID. Parameters string $vid: Vocabulary ID to retrieve terms for. File core/modules/taxonomy/src/TermStorageInterface.php, line 103 Class TermStorageInterface Defines an interface for taxonomy_term entity storage classes. Namespace Drupal\taxonomy Code public function resetWeights($vid);

TermStorageInterface::loadParents

public TermStorageInterface::loadParents($tid) Finds all parents of a given term ID. Parameters int $tid: Term ID to retrieve parents for. Return value \Drupal\taxonomy\TermInterface[] An array of term objects which are the parents of the term $tid. File core/modules/taxonomy/src/TermStorageInterface.php, line 38 Class TermStorageInterface Defines an interface for taxonomy_term entity storage classes. Namespace Drupal\taxonomy Code public function loadParents($tid);

TermStorageInterface::nodeCount

public TermStorageInterface::nodeCount($vid) Count the number of nodes in a given vocabulary ID. Parameters string $vid: Vocabulary ID to retrieve terms for. Return value int A count of the nodes in a given vocabulary ID. File core/modules/taxonomy/src/TermStorageInterface.php, line 95 Class TermStorageInterface Defines an interface for taxonomy_term entity storage classes. Namespace Drupal\taxonomy Code public function nodeCount($vid);

TermStorageInterface::getNodeTerms

public TermStorageInterface::getNodeTerms(array $nids, array $vocabs = array(), $langcode = NULL) Returns all terms used to tag some given nodes. Parameters array $nids: Node IDs to retrieve terms for. array $vocabs: (optional) A vocabularies array to restrict the term search. Defaults to empty array. string $langcode: (optional) A language code to restrict the term search. Defaults to NULL. Return value array An array of nids and the term entities they were tagged with. File core/modules/tax