Lines Matching refs:value
70 * Fetches a value from the cache.
78 * @param mixed $default Default value to return if the key does not exist.
80 * @return array|mixed The value of the item from the cache, or $default in case of cache miss.
83 * MUST be thrown if the $key string is not a legal value.
114 * public function set(string $key, mixed $value, null|int|\DateInterval $ttl = null): bool;
118 * @param array $value The value of the item to store, must be serializable.
119 * @param null|int $ttl Optional. The TTL value of this item. If no value is sent and
120 * the driver supports TTL then the library may set a default value
126 * MUST be thrown if the $key string is not a legal value.
128 public function set_data(string $key, array $value, ?int $ttl = null): bool
135 $value['__cache_expiration_time'] = time() + $ttl;
137 return $this->cache->save($value);
153 * MUST be thrown if the $key string is not a legal value.