public function Vocabulary::setHierarchy in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/taxonomy/src/Entity/Vocabulary.php \Drupal\taxonomy\Entity\Vocabulary::setHierarchy()
Sets the vocabulary hierarchy.
Parameters
integer $hierarchy: The hierarchy type of vocabulary. Possible values:
- TAXONOMY_HIERARCHY_DISABLED: No parents.
- TAXONOMY_HIERARCHY_SINGLE: Single parent.
- TAXONOMY_HIERARCHY_MULTIPLE: Multiple parents.
Return value
$this
Overrides VocabularyInterface::setHierarchy
File
- core/
modules/ taxonomy/ src/ Entity/ Vocabulary.php, line 106 - Contains \Drupal\taxonomy\Entity\Vocabulary.
Class
- Vocabulary
- Defines the taxonomy vocabulary entity.
Namespace
Drupal\taxonomy\EntityCode
public function setHierarchy($hierarchy) {
$this->hierarchy = $hierarchy;
return $this;
}