b0y-101 Mini Shell


Current Path : E:/www3/chiangrai/wp-content/plugins/polylang/include/Options/Primitive/
File Upload :
Current File : E:/www3/chiangrai/wp-content/plugins/polylang/include/Options/Primitive/Abstract_String.php

<?php
/**
 * @package Polylang
 */

namespace WP_Syntex\Polylang\Options\Primitive;

use WP_Syntex\Polylang\Options\Abstract_Option;

defined( 'ABSPATH' ) || exit;

/**
 * Class defining single string option.
 *
 * @since 3.7
 */
abstract class Abstract_String extends Abstract_Option {
	/**
	 * Returns the default value.
	 *
	 * @since 3.7
	 *
	 * @return string
	 */
	protected function get_default() {
		return '';
	}

	/**
	 * Returns the JSON schema part specific to this option.
	 *
	 * @since 3.7
	 *
	 * @return array Partial schema.
	 *
	 * @phpstan-return array{type: 'string'}
	 */
	protected function get_data_structure(): array {
		return array(
			'type' => 'string',
		);
	}
}

Copyright © 2019 by b0y-101