1 <?php
2 /* --------------------------------------------------------------
3 CategorySettingsInterface.php 2015-12-14
4 Gambio GmbH
5 http://www.gambio.de
6 Copyright (c) 2015 Gambio GmbH
7 Released under the GNU General Public License (Version 2)
8 [http://www.gnu.org/licenses/gpl-2.0.html]
9 --------------------------------------------------------------
10 */
11
12
13 /**
14 * Interface CategorySettingsInterface
15 *
16 * This interface defines methods for storing and retrieving some settings regarding display and visibility mode of
17 * category related data and is used within a CategoryInterface.
18 *
19 * @category System
20 * @package Category
21 * @subpackage Interfaces
22 */
23 interface CategorySettingsInterface
24 {
25 /**
26 * Returns the current category listing template.
27 *
28 * @return string The current category listing template.
29 */
30 public function getCategoryListingTemplate();
31
32
33 /**
34 * Sets the current category listing template.
35 *
36 * @param StringType $filename Category listing template.
37 *
38 * @return CategorySettingsInterface Same instance for chained method calls.
39 */
40 public function setCategoryListingTemplate(StringType $filename);
41
42
43 /**
44 * Returns the current product listing template.
45 *
46 * @return string
47 */
48 public function getProductListingTemplate();
49
50
51 /**
52 * Sets the current product listing template.
53 *
54 * @param StringType $filename Product listing template.
55 *
56 * @return CategorySettingsInterface Same instance for chained method calls.
57 */
58 public function setProductListingTemplate(StringType $filename);
59
60
61 /**
62 * Returns the column by which the products are currently sorted.
63 *
64 * @return string
65 */
66 public function getProductSortColumn();
67
68
69 /**
70 * Sets the column by which the products are currently sorted.
71 *
72 * @param StringType $column Column by which the products should be sorted.
73 *
74 * @return CategorySettingsInterface Same instance for chained method calls.
75 */
76 public function setProductSortColumn(StringType $column);
77
78
79 /**
80 * Returns the direction which the products are currently sorted in.
81 *
82 * @return string
83 */
84 public function getProductSortDirection();
85
86
87 /**
88 * Sets the direction which the products are currently sorted in.
89 *
90 * @param StringType $direction Direction which the products should be sorted in.
91 *
92 * @return CategorySettingsInterface Same instance for chained method calls.
93 */
94 public function setProductSortDirection(StringType $direction);
95
96
97 /**
98 * Checks if category/product is part of the sitemap.
99 *
100 * @return bool
101 */
102 public function isSitemapEntry();
103
104
105 /**
106 * Sets whether the category/product is part of the sitemap.
107 *
108 * @param BoolType $status Value whether the category/product is part of the sitemap.
109 *
110 * @return CategorySettingsInterface Same instance for chained method calls.
111 */
112 public function setSitemapEntry(BoolType $status);
113
114
115 /**
116 * Returns the sitemap priority of the element.
117 *
118 * @return string
119 */
120 public function getSitemapPriority();
121
122
123 /**
124 * Sets the sitemap priority of the element.
125 *
126 * @param StringType $priority Element's sitemap priority.
127 *
128 * @return CategorySettingsInterface Same instance for chained method calls.
129 */
130 public function setSitemapPriority(StringType $priority);
131
132
133 /**
134 * Returns the change frequency of the element.
135 *
136 * @return string
137 */
138 public function getSitemapChangeFreq();
139
140
141 /**
142 * Sets the change frequency of the element.
143 *
144 * @param StringType $freq Change frequency value.
145 *
146 * @return CategorySettingsInterface Same instance for chained method calls.
147 */
148 public function setSitemapChangeFreq(StringType $freq);
149
150
151 /**
152 * Checks if attributes should be displayed or not.
153 *
154 * @return bool
155 */
156 public function showAttributes();
157
158
159 /**
160 * Sets whether the attributes should be displayed or not.
161 *
162 * @param BoolType $status Should attributes be displayed?
163 *
164 * @return CategorySettingsInterface Same instance for chained method calls.
165 */
166 public function setShowAttributes(BoolType $status);
167
168
169 /**
170 * Checks if graduated prices should be displayed or not.
171 *
172 * @return bool
173 */
174 public function showGraduatedPrices();
175
176
177 /**
178 * Sets whether graduated prices should be displayed or not.
179 *
180 * @param BoolType $status Show graduated prices?
181 *
182 * @return CategorySettingsInterface Same instance for chained method calls.
183 */
184 public function setShowGraduatedPrices(BoolType $status);
185
186
187 /**
188 * Checks if a quantity input should be displayed in product forms or not.
189 *
190 * @return bool
191 */
192 public function showQuantityInput();
193
194
195 /**
196 * Sets whether a quantity input should be displayed in product forms or not.
197 *
198 * @param BoolType $status Show quantity input?
199 *
200 * @return CategorySettingsInterface Same instance for chained method calls.
201 */
202 public function setShowQuantityInput(BoolType $status);
203
204
205 /**
206 * Checks if the stock should be displayed or not.
207 *
208 * @return bool
209 */
210 public function showStock();
211
212
213 /**
214 * Sets whether the stock should be displayed or not.
215 *
216 * @param BoolType $status Show quantity info?
217 *
218 * @return CategorySettingsInterface Same instance for chained method calls.
219 */
220 public function setShowStock(BoolType $status);
221
222
223 /**
224 * Checks if subcategories should be displayed or not.
225 *
226 * @return bool
227 */
228 public function showSubcategories();
229
230
231 /**
232 * Sets whether subcategories should be displayed or not.
233 *
234 * @param BoolType $status Show subcategories?
235 *
236 * @return CategorySettingsInterface Same instance for chained method calls.
237 */
238 public function setShowSubcategories(BoolType $status);
239
240
241 /**
242 * Checks if subcategory images should be displayed or not.
243 *
244 * @return bool
245 */
246 public function showSubcategoryImages();
247
248
249 /**
250 * Sets whether subcategory images should be displayed or not.
251 *
252 * @param BoolType $status Show subcategory images?
253 *
254 * @return CategorySettingsInterface Same instance for chained method calls.
255 */
256 public function setShowSubcategoryImages(BoolType $status);
257
258
259 /**
260 * Checks if subcategory names should be displayed or not.
261 *
262 * @return bool
263 */
264 public function showSubcategoryNames();
265
266
267 /**
268 * Sets whether subcategory names should be displayed or not.
269 *
270 * @param BoolType $status Show subcategory names?
271 *
272 * @return CategorySettingsInterface Same instance for chained method calls.
273 */
274 public function setShowSubcategoryNames(BoolType $status);
275
276
277 /**
278 * Checks if subcategory products should be displayed or not.
279 *
280 * @return bool
281 */
282 public function showSubcategoryProducts();
283
284
285 /**
286 * Sets whether subcategory products should be displayed or not.
287 *
288 * @param BoolType $status Show subcategory products?
289 *
290 * @return CategorySettingsInterface Same instance for chained method calls.
291 */
292 public function setShowSubcategoryProducts(BoolType $status);
293
294
295 /**
296 * Checks if default view mode should be tiled or not.
297 *
298 * @return bool
299 */
300 public function isDefaultViewModeTiled();
301
302
303 /**
304 * Sets whether default view mode should be tiled or not.
305 *
306 * @param BoolType $status Is tiled the default view mode?
307 *
308 * @return CategorySettingsInterface Same instance for chained method calls.
309 */
310 public function setDefaultViewModeTiled(BoolType $status);
311
312
313 /**
314 * Checks if it is a permitted customer status or not.
315 *
316 * @param IdType $customerStatusId Customer status ID.
317 *
318 * @return bool
319 */
320 public function isPermittedCustomerStatus(IdType $customerStatusId);
321
322
323 /**
324 * Sets whether a customer status is permitted or not.
325 *
326 * @param IdType $customerStatusId Customer status ID.
327 * @param BoolType $permitted Is permitted?
328 *
329 * @return CategorySettingsInterface Same instance for chained method calls.
330 */
331 public function setPermittedCustomerStatus(IdType $customerStatusId, BoolType $permitted);
332 }