Automattic\WooCommerce\Caching

CacheException::__construct()publicWC 1.0

Creates a new instance of the class.

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

No Hooks.

Return

null. Nothing.

Usage

$CacheException = new CacheException();
$CacheException->__construct( $message, $thrower, $cached_id, ?array $errors, $code, $previous );
$message(string) (required)
The exception message.
$thrower(ObjectCache) (required)
The object that is throwing the exception.
$cached_id(int|string|null)
The involved cached object id, if available.
Default: null
?array $errors **
-
Default: null
$code(mixed)
An error code, if available.
$previous(\Throwable|null)
The previous exception, if available.
Default: null

Code of CacheException::__construct() WC 7.1.0

public function __construct( string $message, ObjectCache $thrower, $cached_id = null, ?array $errors = null, $code = 0, \Throwable $previous = null ) {
	$this->errors    = $errors ?? array();
	$this->thrower   = $thrower;
	$this->cached_id = $cached_id;

	parent::__construct( $message, $code, $previous );
}