Automattic\WooCommerce\Internal\Admin\BlockTemplateRegistry

BlockTemplateRegistry::get_registered()publicWC 1.0

Get a single registered template.

Метод класса: BlockTemplateRegistry{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

$BlockTemplateRegistry = new BlockTemplateRegistry();
$BlockTemplateRegistry->get_registered( $id ): BlockTemplateInterface;
$id(строка) (обязательный)
ID of the template

Код BlockTemplateRegistry::get_registered() WC 8.1.1

public function get_registered( $id ): BlockTemplateInterface {
    return isset( $this->templates[ $id ] ) ? $this->templates[ $id ] : null;
}