PluginProbe
Polylang / 3.7.7
Polylang v3.7.7
3.8.9 3.8.8 3.8.7 3.8.6 3.8.5 3.8.4 3.8.3 2.7 2.7.0.1 2.7.1 2.7.2 2.7.3 2.7.4 2.8 2.8.1 2.8.2 2.8.3 2.8.4 2.9 2.9.1 2.9.2 3.0 3.0.1 3.0.2 3.0.3 All 233 releases
polylang / include / Options / Primitive / Abstract_String.php

Abstract_String.php in Polylang 3.7.7, at include/Options/Primitive/Abstract_String.php

44 lines 693 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * @package Polylang
4 */
5
6 namespace WP_Syntex\Polylang\Options\Primitive;
7
8 use WP_Syntex\Polylang\Options\Abstract_Option;
9
10 defined( 'ABSPATH' ) || exit;
11
12 /**
13 * Class defining single string option.
14 *
15 * @since 3.7
16 */
17 abstract class Abstract_String extends Abstract_Option {
18 /**
19 * Returns the default value.
20 *
21 * @since 3.7
22 *
23 * @return string
24 */
25 protected function get_default() {
26 return '';
27 }
28
29 /**
30 * Returns the JSON schema part specific to this option.
31 *
32 * @since 3.7
33 *
34 * @return array Partial schema.
35 *
36 * @phpstan-return array{type: 'string'}
37 */
38 protected function get_data_structure(): array {
39 return array(
40 'type' => 'string',
41 );
42 }
43 }
44