Interface Github\HttpClient\Cache\CacheInterface

Implemented byGithub\HttpClient\Cache\FilesystemCache, Github\HttpClient\Cache\GaufretteCache

Caches github api responses.

Method Details

get() public abstract method

public abstract Guzzle\Http\Message\Response get ( $id )
$id string

The id of the cached resource

return Guzzle\Http\Message\Response

The cached response object

throws InvalidArgumentException

If cache data don't exists

getETag() public abstract method

public abstract null|string getETag ( $id )
$id string

The id of the cached resource

return null|string

The ETag value

getModifiedSince() public abstract method

public abstract null|int getModifiedSince ( $id )
$id string

The id of the cached resource

return null|int

The modified since timestamp

has() public abstract method

public abstract bool has ( $id )
$id string

The id of the cached resource

return bool

If present

set() public abstract method

public abstract void set ( $id, Guzzle\Http\Message\Response $response )
$id string

The id of the cached resource

$response Guzzle\Http\Message\Response

The response to cache

throws InvalidArgumentException

If cache data cannot be saved