Overview

Namespaces

  • Contrib
    • Bundle
      • CoverallsBundle
        • Console
        • Entity
      • CoverallsV1Bundle
        • Api
        • Collector
        • Command
        • Config
        • Entity
          • Git
    • Component
      • File
      • Log
      • System
        • Git
  • Guzzle
    • Batch
      • Exception
    • Cache
    • Common
      • Exception
    • Http
      • Curl
      • Exception
      • Message
      • QueryAggregator
    • Inflection
    • Iterator
    • Log
    • Parser
      • Cookie
      • Message
      • UriTemplate
      • Url
    • Plugin
      • Async
      • Backoff
      • Cache
      • Cookie
        • CookieJar
        • Exception
      • CurlAuth
      • ErrorResponse
        • Exception
      • History
      • Log
      • Md5
      • Mock
      • Oauth
    • Service
      • Builder
      • Command
        • Factory
        • LocationVisitor
          • Request
          • Response
      • Description
      • Exception
      • Resource
    • Stream
  • PHP
  • Psr
    • Log
  • Symfony
    • Component
      • Config
        • Definition
          • Builder
          • Exception
        • Exception
        • Loader
        • Resource
        • Util
      • Console
        • Command
        • Formatter
        • Helper
        • Input
        • Output
        • Tester
      • EventDispatcher
        • Debug
      • Finder
        • Adapter
        • Comparator
        • Exception
        • Expression
        • Iterator
        • Shell
      • Stopwatch
      • Yaml
        • Exception

Classes

  • AbstractCacheAdapter
  • CacheAdapterFactory
  • ClosureCacheAdapter
  • DoctrineCacheAdapter
  • NullCacheAdapter
  • Zf1CacheAdapter
  • Zf2CacheAdapter

Interfaces

  • CacheAdapterInterface
  • Overview
  • Namespace
  • Class
  • Tree
  • Todo
 1: <?php
 2: 
 3: namespace Guzzle\Cache;
 4: 
 5: /**
 6:  * Zend Framework 1 cache adapter
 7:  *
 8:  * @link http://framework.zend.com/manual/en/zend.cache.html
 9:  */
10: class Zf1CacheAdapter extends AbstractCacheAdapter
11: {
12:     /**
13:      * @param \Zend_Cache_Backend $cache Cache object to wrap
14:      */
15:     public function __construct(\Zend_Cache_Backend $cache)
16:     {
17:         $this->cache = $cache;
18:     }
19: 
20:     /**
21:      * {@inheritdoc}
22:      */
23:     public function contains($id, array $options = null)
24:     {
25:         return $this->cache->test($id);
26:     }
27: 
28:     /**
29:      * {@inheritdoc}
30:      */
31:     public function delete($id, array $options = null)
32:     {
33:         return $this->cache->remove($id);
34:     }
35: 
36:     /**
37:      * {@inheritdoc}
38:      */
39:     public function fetch($id, array $options = null)
40:     {
41:         return $this->cache->load($id);
42:     }
43: 
44:     /**
45:      * {@inheritdoc}
46:      */
47:     public function save($id, $data, $lifeTime = false, array $options = null)
48:     {
49:         return $this->cache->save($data, $id, array(), $lifeTime);
50:     }
51: }
52: 
php-coveralls API documentation generated by ApiGen 2.8.0