1 | <?php |
||
30 | class WordPoints_Hooks extends WordPoints_App { |
||
31 | |||
32 | /** |
||
33 | * The current mode of the API. |
||
34 | * |
||
35 | * @since 1.0.0 |
||
36 | * |
||
37 | * @var string |
||
38 | */ |
||
39 | protected $current_mode; |
||
40 | |||
41 | /** |
||
42 | * Register the sub apps when the app is constructed. |
||
43 | * |
||
44 | * @since 1.0.0 |
||
45 | */ |
||
46 | protected function init() { |
||
59 | |||
60 | /** |
||
61 | * Gets the current mode that the API is in. |
||
62 | * |
||
63 | * By default 'standard' mode is on, unless in network context (such as in the |
||
64 | * network admin) on multisite, when 'network' mode is the default. |
||
65 | * |
||
66 | * The current mode is used by reactors to determine which reaction type to offer |
||
67 | * access to through the $reactions property. This is allows for generic code for |
||
68 | * handling reactions to reference the $reactions property of the reactor, and |
||
69 | * what type of reactions it will get will be determined based on the current |
||
70 | * mode that is set. |
||
71 | * |
||
72 | * @since 1.0.0 |
||
73 | * |
||
74 | * @return string The slug of the current mode. |
||
75 | */ |
||
76 | public function get_current_mode() { |
||
84 | |||
85 | /** |
||
86 | * Sets the current mode of the API. |
||
87 | * |
||
88 | * This function should be used very sparingly. The default mode which is set by |
||
89 | * WordPoints should work for you in most cases. The primary reason that you |
||
90 | * would ever need to set the mode yourself is if you have created your own |
||
91 | * custom mode. Otherwise you probably shouldn't be using this function. |
||
92 | * |
||
93 | * @since 1.0.0 |
||
94 | * |
||
95 | * @param string $mode The slug of the mode to set as the current mode. |
||
96 | */ |
||
97 | public function set_current_mode( $mode ) { |
||
100 | } |
||
101 | |||
103 |