/var/www/vhosts/ihelp.ro/httpdocs/vendor/cakephp/cakephp/src/I18n
NameSizeModeActions
Exception/-0755rm
Formatter/-0755rm
Middleware/-0755rm
Parser/-0755rm
ChainMessagesLoader.php23220644editdlrm
composer.json12810644editdlrm
Date.php74610644editdlrm
DateFormatTrait.php177740644editdlrm
FormatterInterface.php12760644editdlrm
FormatterLocator.php28640644editdlrm
FrozenDate.php72890644editdlrm
FrozenTime.php100630644editdlrm
functions.php88550644editdlrm
I18n.php96210644editdlrm
I18nDateTimeInterface.php97090644editdlrm
LICENSE.txt12040644editdlrm
MessagesFileLoader.php55550644editdlrm
Number.php180140644editdlrm
Package.php39720644editdlrm
PackageLocator.php34880644editdlrm
PluralRules.php58900644editdlrm
README.md28790644editdlrm
RelativeTimeFormatter.php152960644editdlrm
Time.php125870644editdlrm
Translator.php60140644editdlrm
TranslatorRegistry.php101990644editdlrm
Edit: /var/www/vhosts/ihelp.ro/httpdocs/vendor/cakephp/cakephp/src/I18n/FormatterLocator.php (2864B)
> */ protected $registry = []; /** * Tracks whether a registry entry has been converted from a * FQCN to a formatter object. * * @var array */ protected $converted = []; /** * Constructor. * * @param array> $registry An array of key-value pairs where the key is the * formatter name the value is a FQCN for the formatter. */ public function __construct(array $registry = []) { foreach ($registry as $name => $spec) { $this->set($name, $spec); } } /** * Sets a formatter into the registry by name. * * @param string $name The formatter name. * @param class-string<\Cake\I18n\FormatterInterface> $className A FQCN for a formatter. * @return void */ public function set(string $name, string $className): void { $this->registry[$name] = $className; $this->converted[$name] = false; } /** * Gets a formatter from the registry by name. * * @param string $name The formatter to retrieve. * @return \Cake\I18n\FormatterInterface A formatter object. * @throws \Cake\I18n\Exception\I18nException */ public function get(string $name): FormatterInterface { if (!isset($this->registry[$name])) { throw new I18nException("Formatter named `{$name}` has not been registered"); } if (!$this->converted[$name]) { /** @var class-string<\Cake\I18n\FormatterInterface> $formatter */ $formatter = $this->registry[$name]; $this->registry[$name] = new $formatter(); $this->converted[$name] = true; } /** @var \Cake\I18n\FormatterInterface */ return $this->registry[$name]; } }