PHP Класс phpbb\language\language_file_loader

Показать файл Открыть проект

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

Свойство Тип Описание
$extension_manager Extension manager
$php_ext Extension of PHP files
$phpbb_root_path Path to phpBB's root

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

Метод Описание
__construct ( string $phpbb_root_path, string $php_ext ) Constructor
load ( string $component, string | array $locale, array &$lang ) Loads language array for the given component
load_extension ( string $extension, string $component, string | array $locale, array &$lang ) Loads language array for the given extension component
set_extension_manager ( phpbb\extension\manager $extension_manager ) Extension manager setter

Защищенные методы

Метод Описание
get_language_file_path ( string $path, string $filename, $locales ) : string This function implements language fallback logic
load_file ( string $path, string $component, array $locale, array &$lang ) Prepares language file loading
load_language_file ( string $path, array &$lang ) Loads language file

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

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

Constructor
public __construct ( string $phpbb_root_path, string $php_ext )
$phpbb_root_path string Path to phpBB's root
$php_ext string Extension of PHP files

get_language_file_path() защищенный Метод

This function implements language fallback logic
protected get_language_file_path ( string $path, string $filename, $locales ) : string
$path string Path to language directory
$filename string Filename to load language strings from
Результат string Relative path to language file

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

Loads language array for the given component
public load ( string $component, string | array $locale, array &$lang )
$component string Name of the language component
$locale string | array ISO code of the language to load, or array of ISO codes if you want to specify additional language fallback steps
$lang array Array reference containing language strings

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

Loads language array for the given extension component
public load_extension ( string $extension, string $component, string | array $locale, array &$lang )
$extension string Name of the extension
$component string Name of the language component
$locale string | array ISO code of the language to load, or array of ISO codes if you want to specify additional language fallback steps
$lang array Array reference containing language strings

load_file() защищенный Метод

Prepares language file loading
protected load_file ( string $path, string $component, array $locale, array &$lang )
$path string Path to search for file in
$component string Name of the language component
$locale array Array containing language fallback options
$lang array Array reference of language strings

load_language_file() защищенный Метод

Loads language file
protected load_language_file ( string $path, array &$lang )
$path string Path to language file to load
$lang array Reference of the array of language strings

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

Extension manager setter
public set_extension_manager ( phpbb\extension\manager $extension_manager )
$extension_manager phpbb\extension\manager Extension manager

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

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

Extension manager
protected $extension_manager

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

Extension of PHP files
protected $php_ext

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

Path to phpBB's root
protected $phpbb_root_path