PluginProbe
WowAddons – Product Addons and Product Options With Custom Fields / trunk
WowAddons – Product Addons and Product Options With Custom Fields vtrunk
1.7.2 1.7.1 1.7.0 1.6.21 1.6.20 1.6.19 1.6.18 1.6.17 1.6.16 1.6.15 1.6.14 1.6.13 1.6.12 1.6.11 1.6.10 1.6.9 1.6.8 1.6.7 1.6.6 1.5.10 1.5.11 1.5.2 1.5.3 1.5.4 1.5.5 All 57 releases
product-addons / includes / blocks / interfaces / class-block-interface.php

class-block-interface.php in WowAddons – Product Addons and Product Options With Custom Fields trunk, at includes/blocks/interfaces/class-block-interface.php

60 lines 861 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Block Interface
4 *
5 * @package PRAD
6 * @since 1.0.0
7 */
8
9 namespace PRAD\Includes\Blocks\Interfaces;
10
11 defined( 'ABSPATH' ) || exit;
12
13 /**
14 * Block Interface - All blocks must implement this
15 */
16 interface Block_Interface {
17
18 /**
19 * Render the block HTML
20 *
21 * @return string
22 */
23 public function render(): string;
24
25 /**
26 * Get the block type identifier
27 *
28 * @return string
29 */
30 public function get_type(): string;
31
32 /**
33 * Validate block data and state
34 *
35 * @return bool
36 */
37 public function validate(): bool;
38
39 /**
40 * Get the price value for this block
41 *
42 * @return float
43 */
44 public function get_price(): float;
45
46 /**
47 * Get block configuration data
48 *
49 * @return array
50 */
51 public function get_config(): array;
52
53 /**
54 * Check if block should be displayed
55 *
56 * @return bool
57 */
58 public function should_display(): bool;
59 }
60