3 namespace Drupal\taxonomy;
5 use Drupal\Core\Entity\ContentEntityInterface;
6 use Drupal\Core\Entity\EntityChangedInterface;
7 use Drupal\Core\Entity\EntityPublishedInterface;
10 * Provides an interface defining a taxonomy term entity.
12 interface TermInterface extends ContentEntityInterface, EntityChangedInterface, EntityPublishedInterface {
15 * Gets the term's description.
18 * The term description.
20 public function getDescription();
23 * Sets the term's description.
25 * @param string $description
26 * The term's description.
30 public function setDescription($description);
33 * Gets the text format name for the term's description.
36 * The text format name.
38 public function getFormat();
41 * Sets the text format name for the term's description.
43 * @param string $format
44 * The term's description text format.
48 public function setFormat($format);
51 * Gets the name of the term.
54 * The name of the term.
56 public function getName();
59 * Sets the name of the term.
66 public function setName($name);
69 * Gets the weight of this term.
72 * The weight of the term.
74 public function getWeight();
77 * Gets the weight of this term.
84 public function setWeight($weight);
87 * Get the taxonomy vocabulary id this term belongs to.
90 * The id of the vocabulary.
92 * @deprecated Scheduled for removal before Drupal 9.0.0. Use
93 * TermInterface::bundle() instead.
95 public function getVocabularyId();