1 | <?php |
||
18 | class Suggest implements BuilderInterface |
||
19 | { |
||
20 | use ParametersTrait; |
||
21 | |||
22 | /** |
||
23 | * @var string |
||
24 | */ |
||
25 | private $name; |
||
26 | |||
27 | /** |
||
28 | * @var string |
||
29 | */ |
||
30 | private $type; |
||
31 | |||
32 | /** |
||
33 | * @var string |
||
34 | */ |
||
35 | private $text; |
||
36 | |||
37 | /** |
||
38 | * @var string |
||
39 | */ |
||
40 | private $field; |
||
41 | |||
42 | /** |
||
43 | * TermSuggest constructor. |
||
44 | * @param string $name |
||
45 | * @param string $type |
||
46 | * @param string $text |
||
47 | * @param string $field |
||
48 | * @param array $parameters |
||
49 | */ |
||
50 | public function __construct($name, $type, $text, $field, $parameters = []) |
||
58 | |||
59 | /** |
||
60 | * @param string $name |
||
61 | */ |
||
62 | public function setName($name) |
||
66 | |||
67 | /** |
||
68 | * Returns suggest name |
||
69 | * |
||
70 | * @return string |
||
71 | */ |
||
72 | public function getName() |
||
76 | |||
77 | /** |
||
78 | * Returns element type. |
||
79 | * |
||
80 | * @return string |
||
81 | */ |
||
82 | public function getType() |
||
86 | |||
87 | /** |
||
88 | * @param string $type |
||
89 | */ |
||
90 | public function setType($type) |
||
94 | |||
95 | /** |
||
96 | * @return string |
||
97 | */ |
||
98 | public function getText() |
||
102 | |||
103 | /** |
||
104 | * @param string $text |
||
105 | */ |
||
106 | public function setText($text) |
||
110 | |||
111 | /** |
||
112 | * @return string |
||
113 | */ |
||
114 | public function getField() |
||
118 | |||
119 | /** |
||
120 | * @param string $field |
||
121 | */ |
||
122 | public function setField($field) |
||
126 | |||
127 | /** |
||
128 | * {@inheritdoc} |
||
129 | */ |
||
130 | public function toArray() |
||
141 | } |
||
142 |