1 | <?php |
||
6 | class Jetpack_Site extends Abstract_Jetpack_Site { |
||
7 | |||
8 | protected function get_mock_option( $name ) { |
||
9 | return get_option( 'jetpack_'.$name ); |
||
10 | } |
||
11 | |||
12 | protected function get_constant( $name ) { |
||
13 | if ( defined( $name) ) { |
||
14 | return constant( $name ); |
||
15 | } |
||
16 | return null; |
||
17 | } |
||
18 | |||
19 | protected function current_theme_supports( $feature_name ) { |
||
20 | return current_theme_supports( $feature_name ); |
||
21 | } |
||
22 | |||
23 | protected function get_theme_support( $feature_name ) { |
||
24 | return get_theme_support( $feature_name ); |
||
25 | } |
||
26 | |||
27 | protected function get_updates() { |
||
30 | |||
31 | function get_id() { |
||
32 | return $this->platform->token->blog_id; |
||
|
|||
33 | } |
||
34 | |||
35 | function has_videopress() { |
||
44 | |||
45 | function upgraded_filetypes_enabled() { |
||
48 | |||
49 | function is_mapped_domain() { |
||
52 | |||
53 | function is_redirect() { |
||
56 | |||
57 | function is_following() { |
||
60 | |||
61 | function has_wordads() { |
||
65 | |||
66 | function get_frame_nonce() { |
||
69 | |||
70 | function allowed_file_types() { |
||
84 | |||
85 | function is_private() { |
||
88 | |||
89 | function get_plan() { |
||
92 | |||
93 | function get_subscribers_count() { |
||
96 | |||
97 | function get_capabilities() { |
||
100 | |||
101 | function get_locale() { |
||
104 | |||
105 | function get_icon() { |
||
115 | |||
116 | function is_jetpack() { |
||
119 | |||
120 | protected function get_jetpack_version() { |
||
123 | |||
124 | function get_ak_vp_bundle_enabled() {} |
||
125 | |||
126 | } |
||
127 |
In PHP it is possible to write to properties without declaring them. For example, the following is perfectly valid PHP code:
Generally, it is a good practice to explictly declare properties to avoid accidental typos and provide IDE auto-completion: