Automattic\WooCommerce\Vendor\Pelago\Emogrifier\Caching
SimpleStringCache::get
Returns the entry stored for the given key, and throws an exception if the value does not exist (which helps keep the return type simple).
Метод класса: SimpleStringCache{}
Хуков нет.
Возвращает
string. the retrieved value; may be empty
Использование
$SimpleStringCache = new SimpleStringCache(); $SimpleStringCache->get( $key ): string;
- $key(строка) (обязательный)
- the key to of the item to retrieve; must not be empty.
Код SimpleStringCache::get() SimpleStringCache::get WC 11.1.1
public function get(string $key): string
{
if (!$this->has($key)) {
throw new \BadMethodCallException('You can only call `get` with a key for an existing value.', 1625996246);
}
return $this->values[$key];
}