PHP Класс Taxonomy_Core

Автор: Justin Sternberg Text Domain: taxonomy-core Domain Path: /languages
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$arg_overrides array Optional argument overrides passed in from the constructor.
$l10n_done boolean Whether text-domain has been registered
$object_types array Objects to register this taxonomy against
$plural string Plural Taxonomy label
$singular string Singlur Taxonomy label
$taxonomies array An array of each Taxonomy_Core object registered with this class
$taxonomy string Registered Taxonomy name/slug
$taxonomy_args array All Taxonomy registration arguments

Открытые методы

Метод Описание
__construct ( mixed $taxonomy, array $arg_overrides = [], array $object_types = ['post'] ) Constructor. Builds our Taxonomy.
__toString ( ) : string Magic method that echos the Taxonomy registered name when treated like a string
get_args ( ) : array Gets the passed in arguments combined with our defaults.
l10n ( ) Load this library's text domain
register_taxonomy ( ) Actually registers our Taxonomy with the merged arguments
taxonomies ( string $taxonomy = '' ) : mixed Provides access to all Taxonomy_Core taxonomy objects registered via this class.
taxonomy ( string $key = 'taxonomy' ) : mixed Provides access to protected class properties.

Описание методов

__construct() публичный Метод

Constructor. Builds our Taxonomy.
С версии: 0.1.0
public __construct ( mixed $taxonomy, array $arg_overrides = [], array $object_types = ['post'] )
$taxonomy mixed Singular Taxonomy name, or array with Singular, Plural, and Registered
$arg_overrides array Taxonomy registration override arguments
$object_types array Post types to register this taxonomy for

__toString() публичный Метод

Magic method that echos the Taxonomy registered name when treated like a string
С версии: 0.1.0
public __toString ( ) : string
Результат string Taxonomy registered name

get_args() публичный Метод

Gets the passed in arguments combined with our defaults.
С версии: 0.1.0
public get_args ( ) : array
Результат array Taxonomy arguments array

l10n() публичный Метод

Load this library's text domain
С версии: 0.2.0
public l10n ( )

register_taxonomy() публичный Метод

Actually registers our Taxonomy with the merged arguments
С версии: 0.1.0
public register_taxonomy ( )

taxonomies() публичный статический Метод

Provides access to all Taxonomy_Core taxonomy objects registered via this class.
С версии: 0.1.0
public static taxonomies ( string $taxonomy = '' ) : mixed
$taxonomy string Specific Taxonomy_Core object to return, or 'true' to specify only names.
Результат mixed Specific Taxonomy_Core object or array of all

taxonomy() публичный Метод

Provides access to protected class properties.
С версии: 0.1.0
public taxonomy ( string $key = 'taxonomy' ) : mixed
$key string Specific taxonomy parameter to return
Результат mixed Specific taxonomy parameter or array of singular, plural and registered name

Описание свойств

$arg_overrides защищенное свойство

Optional argument overrides passed in from the constructor.
protected array $arg_overrides
Результат array

$l10n_done защищенное статическое свойство

Whether text-domain has been registered
protected static bool $l10n_done
Результат boolean

$object_types защищенное свойство

Objects to register this taxonomy against
protected array $object_types
Результат array

$plural защищенное свойство

Plural Taxonomy label
protected string $plural
Результат string

$singular защищенное свойство

Singlur Taxonomy label
protected string $singular
Результат string

$taxonomies защищенное статическое свойство

An array of each Taxonomy_Core object registered with this class
protected static array $taxonomies
Результат array

$taxonomy защищенное свойство

Registered Taxonomy name/slug
protected string $taxonomy
Результат string

$taxonomy_args защищенное свойство

All Taxonomy registration arguments
protected array $taxonomy_args
Результат array