Chris@0
|
1 <?php
|
Chris@0
|
2
|
Chris@0
|
3 namespace Drupal\taxonomy;
|
Chris@0
|
4
|
Chris@0
|
5 use Drupal\Core\Entity\ContentEntityInterface;
|
Chris@0
|
6 use Drupal\Core\Entity\EntityChangedInterface;
|
Chris@17
|
7 use Drupal\Core\Entity\EntityPublishedInterface;
|
Chris@0
|
8
|
Chris@0
|
9 /**
|
Chris@0
|
10 * Provides an interface defining a taxonomy term entity.
|
Chris@0
|
11 */
|
Chris@17
|
12 interface TermInterface extends ContentEntityInterface, EntityChangedInterface, EntityPublishedInterface {
|
Chris@0
|
13
|
Chris@0
|
14 /**
|
Chris@0
|
15 * Gets the term's description.
|
Chris@0
|
16 *
|
Chris@0
|
17 * @return string
|
Chris@0
|
18 * The term description.
|
Chris@0
|
19 */
|
Chris@0
|
20 public function getDescription();
|
Chris@0
|
21
|
Chris@0
|
22 /**
|
Chris@0
|
23 * Sets the term's description.
|
Chris@0
|
24 *
|
Chris@0
|
25 * @param string $description
|
Chris@0
|
26 * The term's description.
|
Chris@0
|
27 *
|
Chris@0
|
28 * @return $this
|
Chris@0
|
29 */
|
Chris@0
|
30 public function setDescription($description);
|
Chris@0
|
31
|
Chris@0
|
32 /**
|
Chris@0
|
33 * Gets the text format name for the term's description.
|
Chris@0
|
34 *
|
Chris@0
|
35 * @return string
|
Chris@0
|
36 * The text format name.
|
Chris@0
|
37 */
|
Chris@0
|
38 public function getFormat();
|
Chris@0
|
39
|
Chris@0
|
40 /**
|
Chris@0
|
41 * Sets the text format name for the term's description.
|
Chris@0
|
42 *
|
Chris@0
|
43 * @param string $format
|
Chris@0
|
44 * The term's description text format.
|
Chris@0
|
45 *
|
Chris@0
|
46 * @return $this
|
Chris@0
|
47 */
|
Chris@0
|
48 public function setFormat($format);
|
Chris@0
|
49
|
Chris@0
|
50 /**
|
Chris@0
|
51 * Gets the name of the term.
|
Chris@0
|
52 *
|
Chris@0
|
53 * @return string
|
Chris@0
|
54 * The name of the term.
|
Chris@0
|
55 */
|
Chris@0
|
56 public function getName();
|
Chris@0
|
57
|
Chris@0
|
58 /**
|
Chris@0
|
59 * Sets the name of the term.
|
Chris@0
|
60 *
|
Chris@16
|
61 * @param string $name
|
Chris@0
|
62 * The term's name.
|
Chris@0
|
63 *
|
Chris@0
|
64 * @return $this
|
Chris@0
|
65 */
|
Chris@0
|
66 public function setName($name);
|
Chris@0
|
67
|
Chris@0
|
68 /**
|
Chris@0
|
69 * Gets the weight of this term.
|
Chris@0
|
70 *
|
Chris@0
|
71 * @return int
|
Chris@0
|
72 * The weight of the term.
|
Chris@0
|
73 */
|
Chris@0
|
74 public function getWeight();
|
Chris@0
|
75
|
Chris@0
|
76 /**
|
Chris@0
|
77 * Gets the weight of this term.
|
Chris@0
|
78 *
|
Chris@0
|
79 * @param int $weight
|
Chris@0
|
80 * The term's weight.
|
Chris@0
|
81 *
|
Chris@0
|
82 * @return $this
|
Chris@0
|
83 */
|
Chris@0
|
84 public function setWeight($weight);
|
Chris@0
|
85
|
Chris@0
|
86 /**
|
Chris@0
|
87 * Get the taxonomy vocabulary id this term belongs to.
|
Chris@0
|
88 *
|
Chris@0
|
89 * @return string
|
Chris@0
|
90 * The id of the vocabulary.
|
Chris@0
|
91 *
|
Chris@0
|
92 * @deprecated Scheduled for removal before Drupal 9.0.0. Use
|
Chris@0
|
93 * TermInterface::bundle() instead.
|
Chris@0
|
94 */
|
Chris@0
|
95 public function getVocabularyId();
|
Chris@0
|
96
|
Chris@0
|
97 }
|