PluginProbe
WCPOS – Point of Sale (POS) plugin for WooCommerce / trunk
WCPOS – Point of Sale (POS) plugin for WooCommerce vtrunk
1.10.13 1.10.14 1.10.12 1.10.11 1.10.10 1.10.9 1.10.8 untagged-3d9b7ccddc54df87c672 1.10.7 1.10.6 1.10.5 1.10.3 1.10.4 1.10.2 1.10.1 1.10.0 1.9.17 1.9.15 1.9.16 1.9.14 1.9.13 1.9.12 1.9.11 1.9.10 1.9.9 All 158 releases
woocommerce-pos / includes / Interfaces / StoreInterface.php

StoreInterface.php in WCPOS – Point of Sale (POS) plugin for WooCommerce trunk, at includes/Interfaces/StoreInterface.php

385 lines 8.9 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Store Interface.
4 *
5 * Defines the API contract for Store classes in both free and Pro versions.
6 *
7 * @package WCPOS\WooCommercePOS
8 */
9
10 namespace WCPOS\WooCommercePOS\Interfaces;
11
12 /**
13 * Store Interface.
14 *
15 * All Store implementations must provide these methods to ensure API consistency
16 * between free and Pro versions of the plugin.
17 */
18 interface StoreInterface {
19 /**
20 * Get Store name.
21 *
22 * @param string $context What the value is for. Valid values are view and edit.
23 *
24 * @return string
25 */
26 public function get_name( $context = 'view' );
27
28 /**
29 * Get Store locale.
30 *
31 * @param string $context What the value is for. Valid values are view and edit.
32 *
33 * @return string
34 */
35 public function get_locale( $context = 'view' );
36
37
38 /**
39 * Get Store timezone.
40 *
41 * Empty string means inherit the WordPress site timezone.
42 *
43 * @param string $context What the value is for. Valid values are view and edit.
44 *
45 * @return string
46 */
47 public function get_timezone( $context = 'view' );
48
49 /**
50 * Get Store address line 1.
51 *
52 * @param string $context What the value is for. Valid values are view and edit.
53 *
54 * @return string
55 */
56 public function get_store_address( $context = 'view' );
57
58 /**
59 * Get Store address line 2.
60 *
61 * @param string $context What the value is for. Valid values are view and edit.
62 *
63 * @return string
64 */
65 public function get_store_address_2( $context = 'view' );
66
67 /**
68 * Get Store city.
69 *
70 * @param string $context What the value is for. Valid values are view and edit.
71 *
72 * @return string
73 */
74 public function get_store_city( $context = 'view' );
75
76 /**
77 * Get Store postcode.
78 *
79 * @param string $context What the value is for. Valid values are view and edit.
80 *
81 * @return string
82 */
83 public function get_store_postcode( $context = 'view' );
84
85 /**
86 * Get Store state code.
87 *
88 * @param string $context What the value is for. Valid values are view and edit.
89 *
90 * @return string
91 */
92 public function get_store_state( $context = 'view' );
93
94 /**
95 * Get Store country code.
96 *
97 * @param string $context What the value is for. Valid values are view and edit.
98 *
99 * @return string
100 */
101 public function get_store_country( $context = 'view' );
102
103 /**
104 * Get Store default customer address setting.
105 *
106 * @param string $context What the value is for. Valid values are view and edit.
107 *
108 * @return string
109 */
110 public function get_default_customer_address( $context = 'view' );
111
112 /**
113 * Get Store calculate taxes setting.
114 *
115 * @param string $context What the value is for. Valid values are view and edit.
116 *
117 * @return string
118 */
119 public function get_calc_taxes( $context = 'view' );
120
121 /**
122 * Get Store enable coupons setting.
123 *
124 * @param string $context What the value is for. Valid values are view and edit.
125 *
126 * @return string
127 */
128 public function get_enable_coupons( $context = 'view' );
129
130 /**
131 * Get Store calculate discounts sequentially setting.
132 *
133 * @param string $context What the value is for. Valid values are view and edit.
134 *
135 * @return string
136 */
137 public function get_calc_discounts_sequentially( $context = 'view' );
138
139 /**
140 * Get Store currency code.
141 *
142 * @param string $context What the value is for. Valid values are view and edit.
143 *
144 * @return string
145 */
146 public function get_currency( $context = 'view' );
147
148 /**
149 * Get Store currency position.
150 *
151 * @param string $context What the value is for. Valid values are view and edit.
152 *
153 * @return string
154 */
155 public function get_currency_position( $context = 'view' );
156
157 /**
158 * Get Store price thousand separator.
159 *
160 * @param string $context What the value is for. Valid values are view and edit.
161 *
162 * @return string
163 */
164 public function get_price_thousand_separator( $context = 'view' );
165
166 /**
167 * Get Store price decimal separator.
168 *
169 * @param string $context What the value is for. Valid values are view and edit.
170 *
171 * @return string
172 */
173 public function get_price_decimal_separator( $context = 'view' );
174
175 /**
176 * Get Store price number of decimals.
177 *
178 * @param string $context What the value is for. Valid values are view and edit.
179 *
180 * @return int
181 */
182 public function get_price_number_of_decimals( $context = 'view' );
183
184 /**
185 * Get Store prices include tax setting.
186 *
187 * @param string $context What the value is for. Valid values are view and edit.
188 *
189 * @return string
190 */
191 public function get_prices_include_tax( $context = 'view' );
192
193 /**
194 * Get Store tax based on setting.
195 *
196 * @param string $context What the value is for. Valid values are view and edit.
197 *
198 * @return string
199 */
200 public function get_tax_based_on( $context = 'view' );
201
202 /**
203 * Get Store tax address.
204 *
205 * @param string $context What the value is for. Valid values are view and edit.
206 *
207 * @return array
208 */
209 public function get_tax_address( $context = 'view' );
210
211 /**
212 * Get Store shipping tax class.
213 *
214 * @param string $context What the value is for. Valid values are view and edit.
215 *
216 * @return string
217 */
218 public function get_shipping_tax_class( $context = 'view' );
219
220 /**
221 * Get Store tax round at subtotal setting.
222 *
223 * @param string $context What the value is for. Valid values are view and edit.
224 *
225 * @return string
226 */
227 public function get_tax_round_at_subtotal( $context = 'view' );
228
229 /**
230 * Get Store tax display shop setting.
231 *
232 * @param string $context What the value is for. Valid values are view and edit.
233 *
234 * @return string
235 */
236 public function get_tax_display_shop( $context = 'view' );
237
238 /**
239 * Get Store tax display cart setting.
240 *
241 * @param string $context What the value is for. Valid values are view and edit.
242 *
243 * @return string
244 */
245 public function get_tax_display_cart( $context = 'view' );
246
247 /**
248 * Get Store price display suffix.
249 *
250 * @param string $context What the value is for. Valid values are view and edit.
251 *
252 * @return string
253 */
254 public function get_price_display_suffix( $context = 'view' );
255
256 /**
257 * Get Store tax total display setting.
258 *
259 * @param string $context What the value is for. Valid values are view and edit.
260 *
261 * @return string
262 */
263 public function get_tax_total_display( $context = 'view' );
264
265 /**
266 * Get Store default customer ID.
267 *
268 * @param string $context What the value is for. Valid values are view and edit.
269 *
270 * @return int
271 */
272 public function get_default_customer( $context = 'view' );
273
274 /**
275 * Get Store default customer is cashier setting.
276 *
277 * @param string $context What the value is for. Valid values are view and edit.
278 *
279 * @return bool
280 */
281 public function get_default_customer_is_cashier( $context = 'view' );
282
283 /**
284 * Get Store URL.
285 *
286 * @param string $context What the value is for. Valid values are view and edit.
287 *
288 * @return string
289 */
290 public function get_url( $context = 'view' );
291
292 /**
293 * Get Store phone number.
294 *
295 * @param string $context What the value is for. Valid values are view and edit.
296 *
297 * @return string
298 */
299 public function get_phone( $context = 'view' );
300
301 /**
302 * Get Store email address.
303 *
304 * @param string $context What the value is for. Valid values are view and edit.
305 *
306 * @return string
307 */
308 public function get_email( $context = 'view' );
309
310 /**
311 * Get Store opening hours.
312 *
313 * @param string $context What the value is for. Valid values are view and edit.
314 *
315 * @return array|string
316 */
317 public function get_opening_hours( $context = 'view' );
318
319 /**
320 * Get Store personal notes.
321 *
322 * @param string $context What the value is for. Valid values are view and edit.
323 *
324 * @return string
325 */
326 public function get_personal_notes( $context = 'view' );
327
328 /**
329 * Get Store policies and conditions.
330 *
331 * @param string $context What the value is for. Valid values are view and edit.
332 *
333 * @return string
334 */
335 public function get_policies_and_conditions( $context = 'view' );
336
337 /**
338 * Get Store footer imprint.
339 *
340 * @param string $context What the value is for. Valid values are view and edit.
341 *
342 * @return string
343 */
344 public function get_footer_imprint( $context = 'view' );
345
346 /**
347 * Get Store formatted address.
348 *
349 * @return string
350 */
351 public function get_formatted_address();
352
353 /**
354 * Get Store logo image source.
355 *
356 * @param string $size Image size. Default 'full'.
357 *
358 * @return array|false Array of image data, or false if no image.
359 */
360 public function get_logo_image_src( $size = 'full' );
361
362 /**
363 * Get Store tax IDs as a structured array.
364 *
365 * Each entry is array{ type:string, value:string, country?:string, label?:string }.
366 *
367 * @param string $context What the value is for. Valid values are view and edit.
368 *
369 * @return array<int,array<string,string>>
370 */
371 public function get_tax_ids( $context = 'view' );
372
373 /**
374 * Get the primary tax ID as a formatted scalar.
375 *
376 * Back-compat helper. Implementations should return the first tax_ids entry's
377 * value, or empty string when no entries exist.
378 *
379 * @param string $context What the value is for. Valid values are view and edit.
380 *
381 * @return string
382 */
383 public function get_tax_id( $context = 'view' );
384 }
385