Documentation

CacheInterface

Interface for simple caching functionality. Used to store access tokens.

Table of Contents

Methods

flush()  : void
Removes all items from the cache.
forget()  : void
Removes an item from the cache.
get()  : mixed
Gets a key from the cache.
put()  : void
Puts a key into the cache.

Methods

forget()

Removes an item from the cache.

public forget(string $key) : void
Parameters
$key : string

get()

Gets a key from the cache.

public get(string $key) : mixed
Parameters
$key : string
Return values
mixed

Return the value for this key if it exists and is not expired yet.

put()

Puts a key into the cache.

public put(string $key, mixed $value[, int $ttl = 10 ]) : void
Parameters
$key : string

The key to set.

$value : mixed

The value to set.

$ttl : int = 10

The time-to-live in seconds.


        
On this page

Search results