BlueSpice MediaWiki REL1_27
 All Classes Namespaces Files Functions Variables Groups Pages
Onoi\HttpRequest\CachedCurlRequest Class Reference
Inheritance diagram for Onoi\HttpRequest\CachedCurlRequest:
Collaboration diagram for Onoi\HttpRequest\CachedCurlRequest:

Public Member Functions

 __construct ($handle, Cache $cache)
 
 setExpiryInSeconds ($expiry)
 
 setCachePrefix ($cachePrefix)
 
 isCached ()
 
 isFromCache ()
 
 execute ()
 
- Public Member Functions inherited from Onoi\HttpRequest\CurlRequest
 __construct ($handle)
 
 ping ()
 
 setOption ($name, $value)
 
 getOption ($name)
 
 getLastTransferInfo ($name=null)
 
 getLastError ()
 
 getLastErrorCode ()
 
 execute ()
 
 __invoke ()
 
 __destruct ()
 

Public Attributes

const CACHE_PREFIX = 'onoi:http:'
 

Additional Inherited Members

- Protected Attributes inherited from Onoi\HttpRequest\CurlRequest
 $options = array()
 

Detailed Description

Simple cache layer from the client-side to avoid repeated requests to the same target.

GNU GPL v2+

Since
1.0
Author
mwjames

Constructor & Destructor Documentation

Onoi\HttpRequest\CachedCurlRequest::__construct (   $handle,
Cache  $cache 
)
Since
1.0
Parameters
resource$handle
Cache$cache

Member Function Documentation

Onoi\HttpRequest\CachedCurlRequest::execute ( )
Since
1.0
Returns
mixed

Implements Onoi\HttpRequest\HttpRequest.

Onoi\HttpRequest\CachedCurlRequest::isCached ( )
Deprecated:
since 1.3, use CachedCurlRequest::isFromCache instead
Since
1.0
Returns
boolean
Onoi\HttpRequest\CachedCurlRequest::isFromCache ( )
Since
1.3
Returns
boolean
Onoi\HttpRequest\CachedCurlRequest::setCachePrefix (   $cachePrefix)
Deprecated:
since 1.3, use option ONOI_HTTP_REQUEST_RESPONSECACHE_PREFIX instead
Since
1.0
Parameters
string$cachePrefix
Onoi\HttpRequest\CachedCurlRequest::setExpiryInSeconds (   $expiry)
Deprecated:
since 1.3, use option ONOI_HTTP_REQUEST_RESPONSECACHE_TTL instead
Since
1.0
Parameters
integer$expiry

Member Data Documentation

const Onoi\HttpRequest\CachedCurlRequest::CACHE_PREFIX = 'onoi:http:'

Fixed constant


The documentation for this class was generated from the following file: