You are viewing a plain text version of this content. The canonical link for it is here.
Posted to zeta-commits@incubator.apache.org by je...@apache.org on 2011/04/06 10:44:47 UTC
[zeta-commits] svn commit: r1089394 [7/21] - in /incubator/zetacomponents/website:
content/community/ htdocs/community/ htdocs/documentation/trunk/Cache/
htdocs/documentation/trunk/Cache/phpdoc/
Modified: incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheManager.html
URL: http://svn.apache.org/viewvc/incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheManager.html?rev=1089394&r1=1089393&r2=1089394&view=diff
==============================================================================
--- incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheManager.html (original)
+++ incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheManager.html Wed Apr 6 10:44:44 2011
@@ -9,16 +9,16 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="description" content="Apache Zeta Components - reusable set of high quality PHP components to fasten your development." />
- <meta name="keywords" content="PHP, apache, components, framework, quality" />
- <meta name="author" content="dotxp" />
+ <meta name="keywords" content="" />
+ <meta name="author" content="jerome" />
<meta name="language" content="en" />
- <meta name="date" content="Wed, 04 Aug 2010 13:07:17 +0200" />
+ <meta name="date" content="Wed, 06 Apr 2011 12:38:17 +0200" />
<meta name="robots" content="all" />
<link rel="schema.DC" href="http://purl.org/dc/elements/1.1/" />
<meta name="DC.title" content="ezcCacheManager.html" />
- <meta name="DC.creator" content="dotxp" />
- <meta name="DC.date" content="Wed, 04 Aug 2010 13:07:17 +0200" />
+ <meta name="DC.creator" content="jerome" />
+ <meta name="DC.date" content="Wed, 06 Apr 2011 12:38:17 +0200" />
<meta name="DC.rights" content="Copyright" />
<link rel="meta" href="/zetacomponents/documentation/trunk/Cache/phpdoc/ezcCacheManager.rdf" />
@@ -68,10 +68,7 @@
<div class="content">
<ul class="tabs">
- <li >
- <a href="/zetacomponents/documentation/trunk/Cache/tutorial.html" title="Tutorial">Tutorial</a>
- </li>
-<li class="requested">
+ <li class="requested">
<a href="/zetacomponents/documentation/trunk/Cache/phpdoc/classtrees.html" title="API">API</a>
</li>
@@ -86,99 +83,175 @@
<a name="sec-description"></a>
<h3>Class ezcCacheManager</h3>
-<p>This is the main class of the Cache package. It gives you a handy interface to create and manage multiple caches at once. It enables you to configure all caches you need in your application in a central place and access them on demand in any place in your application.</p><div><p>The use of ezcCacheManager is not required, but recommended. If you only need a few (or maybe just 1) cache instance, you can use and instantiate a <a href="ezcCacheStorage.html">ezcCacheStorage</a> class directly.</p><p>Usage example for ezcCacheManager: </p><ol><li><div class="src-line"> <span class="src-comm">// Some pre-work, needed by the example</span></div></li>
-<li><div class="src-line"> <span class="src-var">$basePath </span>= <a href="http://www.php.net/dirname">dirname</a><span class="src-sym">( </span>__FILE__ <span class="src-sym">)</span>.<span class="src-str">'/cache'</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> <span class="src-key">function </span><span class="src-id">getUniqueId</span><span class="src-sym">(</span><span class="src-sym">)</span></div></li>
-<li><div class="src-line"> <span class="src-sym">{</span></div></li>
-<li><div class="src-line">     <span class="src-key">return </span><span class="src-str">'This is a unique ID'</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> <span class="src-sym">}</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Central creation and configuration of the caches</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// The ezcCacheManager just stores the configuration right now and</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// performs sanity checks. The ezcCacheStorage instances</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// will be created on demand, when you use them for the first time</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Configuration options for a cache (see ezcCacheStorage)</span></div></li>
-<li><div class="src-line"> <span class="src-var">$options </span>= <span class="src-key">array</span><span class="src-sym">(</span></div></li>
-<li><div class="src-line">     <span class="src-str">'ttl'   </span>=> <span class="src-num">60</span>*<span class="src-num">60</span>*<span class="src-num">24</span>*<span class="src-num">2</span><span class="src-sym">,     </span><span class="src-comm">// Default would be 1 day, here 2 days</span></div></li>
-<li><div class="src-line"> <span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Create a cache named "content", that resides in /var/cache/content</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// The cache instance will use the ezcCacheStorageFileArray class</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// to store the cache data. The time-to-live for cache items is set as</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// defined above.</span></div></li>
-<li><div class="src-line"> <span class="src-id"><a href="ezcCacheManager.html">ezcCacheManager</a></span><span class="src-sym">::</span><a href="ezcCacheManager.html#methodcreateCache">createCache</a><span class="src-sym">( </span><span class="src-str">'content'</span><span class="src-sym">, </span><span class="src-var">$basePath</span>.<span class="src-str">'/content'</span><span class="src-sym">, </span><span class="src-str">'ezcCacheStorageFileArray'</span><span class="src-sym">, </span><span class="src-var">$options </span><span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Create another cache, called "template" in /var/cache/templates.</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// This cache will use the ezcCacheStorageFilePlain class to store</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// cache data. It has the same TTL as the cache defined above.</span></div></li>
-<li><div class="src-line"> <span class="src-id"><a href="ezcCacheManager.html">ezcCacheManager</a></span><span class="src-sym">::</span><a href="ezcCacheManager.html#methodcreateCache">createCache</a><span class="src-sym">( </span><span class="src-str">'template'</span><span class="src-sym">, </span><span class="src-var">$basePath</span>.<span class="src-str">'/templates'</span><span class="src-sym">, </span><span class="src-str">'ezcCacheStorageFilePlain'</span><span class="src-sym">, </span><span class="src-var">$options </span><span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Somewhere in the application you can access the caches</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Get the instance of the cache called "content"</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// Now the instance of ezcCacheStorageFileArray is created and</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// returned to be used. Next time you access this cache, the created</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// instance will be reused.</span></div></li>
-<li><div class="src-line"> <span class="src-var">$cache </span>= <span class="src-id"><a href="ezcCacheManager.html">ezcCacheManager</a></span><span class="src-sym">::</span><a href="ezcCacheManager.html#methodgetCache">getCache</a><span class="src-sym">( </span><span class="src-str">'content' </span><span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Instead of using the createCache()/getCache() mechanism you can also</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// create cache on-demand with delayed initialization. You can find</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// information on how to use that in the tutorial.</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Specify any number of attributes to identify the cache item you want</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// to store. This attributes can be used later to perform operations</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// on a set of cache items, that share a common attribute.</span></div></li>
-<li><div class="src-line"> <span class="src-var">$attributes </span>= <span class="src-key">array</span><span class="src-sym">( </span><span class="src-str">'node' </span>=> <span class="src-num">2</span><span class="src-sym">, </span><span class="src-str">'area' </span>=> <span class="src-str">'admin'</span><span class="src-sym">, </span><span class="src-str">'lang' </span>=> <span class="src-str">'en-GB' </span><span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// This function is not part of the Cache package. You have to define</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// unique IDs for your cache items yourself.</span></div></li>
-<li><div class="src-line"> <span class="src-var">$id </span>= <span class="src-id">getUniqueId</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Initialize the data variable you want to restore</span></div></li>
-<li><div class="src-line"> <span class="src-var">$data </span>= <span class="src-str">''</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Check if data is available in the cache. The restore method returns</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// the cached data, if available, or bool false.</span></div></li>
-<li><div class="src-line"> <span class="src-key">if </span><span class="src-sym">( ( </span><span class="src-var">$data </span>= <span class="src-var">$cache</span><span class="src-sym">-></span><span class="src-id">restore</span><span class="src-sym">( </span><span class="src-var">$id</span><span class="src-sym">, </span><span class="src-var">$attributes </span><span class="src-sym">) ) </span>=== <span class="src-id">false </span><span class="src-sym">)</span></div></li>
-<li><div class="src-line"> <span class="src-sym">{</span></div></li>
-<li><div class="src-line">     <span class="src-comm">// The cache item we tried to restore does not exist, so we have to</span></div></li>
-<li><div class="src-line">     <span class="src-comm">// generate the data.</span></div></li>
-<li><div class="src-line">     <span class="src-var">$data </span>= <span class="src-key">array</span><span class="src-sym">( </span><span class="src-str">'This is some data'</span><span class="src-sym">, </span><span class="src-str">'and some more data.' </span><span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line">     <span class="src-comm">// For testing we echo something here...</span></div></li>
-<li><div class="src-line">     echo <span class="src-str">"No cache data found. Generated some.\n"</span>.<a href="http://www.php.net/var_export">var_export</a><span class="src-sym">( </span><span class="src-var">$data</span><span class="src-sym">, </span><span class="src-id">true </span><span class="src-sym">)</span>.<span class="src-str">"\n"</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line">     <span class="src-comm">// Now we store the data in the cache. It will be available through</span></div></li>
-<li><div class="src-line">     <span class="src-comm">// restore, next time the code is reached</span></div></li>
-<li><div class="src-line">     <span class="src-var">$cache</span><span class="src-sym">-></span><span class="src-id">store</span><span class="src-sym">( </span><span class="src-var">$id</span><span class="src-sym">, </span><span class="src-var">$data</span><span class="src-sym">, </span><span class="src-var">$attributes </span><span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> <span class="src-sym">}</span></div></li>
-<li><div class="src-line"> <span class="src-key">else</span></div></li>
-<li><div class="src-line"> <span class="src-sym">{</span></div></li>
-<li><div class="src-line">     <span class="src-comm">// We found cache data. Let's echo the information.</span></div></li>
-<li><div class="src-line">     echo <span class="src-str">"Cache data found.\n"</span>.<a href="http://www.php.net/var_export">var_export</a><span class="src-sym">( </span><span class="src-var">$data</span><span class="src-sym">, </span><span class="src-id">true </span><span class="src-sym">)</span>.<span class="src-str">"\n"</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> <span class="src-sym">}</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// In some other place you can access the second defined cache.</span></div></li>
-<li><div class="src-line"> <span class="src-var">$cache </span>= <span class="src-id"><a href="ezcCacheManager.html">ezcCacheManager</a></span><span class="src-sym">::</span><a href="ezcCacheManager.html#methodgetCache">getCache</a><span class="src-sym">( </span><span class="src-str">'template' </span><span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-<li><div class="src-line"> </div></li>
-<li><div class="src-line"> <span class="src-comm">// Here we are removing cache items. We do not specify an ID (which would</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// have meant to delete 1 specific cache item), but only an array of</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// attributes. This will result in all cache items to be deleted, that</span></div></li>
-<li><div class="src-line"> <span class="src-comm">// have this attribute assigned.</span></div></li>
-<li><div class="src-line"> <span class="src-var">$cache</span><span class="src-sym">-></span><span class="src-id">delete</span><span class="src-sym">( </span><span class="src-id">null</span><span class="src-sym">, </span><span class="src-key">array</span><span class="src-sym">( </span><span class="src-str">'node' </span>=> <span class="src-num">5 </span><span class="src-sym">) )</span><span class="src-sym">;</span></div></li>
-</ol></div>
+<p>This is the main class of the Cache package. It gives you a handy interface to create and manage multiple caches at once. It enables you to configure all caches you need in your application in a central place and access them on demand in any place in your application.</p>
+<div>
+<p>The use of ezcCacheManager is not required, but recommended. If you only need a few (or maybe just 1) cache instance, you can use and instantiate a <a href="../Cache/ezcCacheStorage.html">ezcCacheStorage</a> class directly.</p>
+<p>Usage example for ezcCacheManager: </p>
+<ol>
+<li><div class="src-line"> <span class="src-comm">// Some pre-work, needed by the example</span>
+</div></li>
+<li><div class="src-line"> <span class="src-var">$basePath </span>= <a href="http://www.php.net/dirname">dirname</a><span class="src-sym">( </span>__FILE__ <span class="src-sym">)</span>.<span class="src-str">'/cache'</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> <span class="src-key">function </span><span class="src-id">getUniqueId</span><span class="src-sym">(</span><span class="src-sym">)</span>
+</div></li>
+<li><div class="src-line"> <span class="src-sym">{</span>
+</div></li>
+<li><div class="src-line">     <span class="src-key">return </span><span class="src-str">'This is a unique ID'</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> <span class="src-sym">}</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Central creation and configuration of the caches</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// The ezcCacheManager just stores the configuration right now and</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// performs sanity checks. The ezcCacheStorage instances</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// will be created on demand, when you use them for the first time</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Configuration options for a cache (see ezcCacheStorage)</span>
+</div></li>
+<li><div class="src-line"> <span class="src-var">$options </span>= <span class="src-key">array</span><span class="src-sym">(</span>
+</div></li>
+<li><div class="src-line">     <span class="src-str">'ttl'   </span>=> <span class="src-num">60</span>*<span class="src-num">60</span>*<span class="src-num">24</span>*<span class="src-num">2</span><span class="src-sym">,     </span><span class="src-comm">// Default would be 1 day, here 2 days</span>
+</div></li>
+<li><div class="src-line"> <span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Create a cache named "content", that resides in /var/cache/content</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// The cache instance will use the ezcCacheStorageFileArray class</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// to store the cache data. The time-to-live for cache items is set as</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// defined above.</span>
+</div></li>
+<li><div class="src-line"> <span class="src-id"><a href="../Cache/ezcCacheManager.html">ezcCacheManager</a></span><span class="src-sym">::</span><a href="../Cache/ezcCacheManager.html#methodcreateCache">createCache</a><span class="src-sym">( </span><span class="src-str">'content'</span><span class="src-sym">, </span><span class="src-var">$basePath</span>.<span class="src-str">'/content'</span><span class="src-sym">, </span><span class="src-str">'ezcCacheStorageFileArray'</span><span class="src-sym">, </span><span class="src-var">$options </span><span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Create another cache, called "template" in /var/cache/templates.</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// This cache will use the ezcCacheStorageFilePlain class to store</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// cache data. It has the same TTL as the cache defined above.</span>
+</div></li>
+<li><div class="src-line"> <span class="src-id"><a href="../Cache/ezcCacheManager.html">ezcCacheManager</a></span><span class="src-sym">::</span><a href="../Cache/ezcCacheManager.html#methodcreateCache">createCache</a><span class="src-sym">( </span><span class="src-str">'template'</span><span class="src-sym">, </span><span class="src-var">$basePath</span>.<span class="src-str">'/templates'</span><span class="src-sym">, </span><span class="src-str">'ezcCacheStorageFilePlain'</span><span class="src-sym">, </span><span class="src-var">$options </span><span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Somewhere in the application you can access the caches</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Get the instance of the cache called "content"</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// Now the instance of ezcCacheStorageFileArray is created and</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// returned to be used. Next time you access this cache, the created</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// instance will be reused.</span>
+</div></li>
+<li><div class="src-line"> <span class="src-var">$cache </span>= <span class="src-id"><a href="../Cache/ezcCacheManager.html">ezcCacheManager</a></span><span class="src-sym">::</span><a href="../Cache/ezcCacheManager.html#methodgetCache">getCache</a><span class="src-sym">( </span><span class="src-str">'content' </span><span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Instead of using the createCache()/getCache() mechanism you can also</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// create cache on-demand with delayed initialization. You can find</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// information on how to use that in the tutorial.</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Specify any number of attributes to identify the cache item you want</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// to store. This attributes can be used later to perform operations</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// on a set of cache items, that share a common attribute.</span>
+</div></li>
+<li><div class="src-line"> <span class="src-var">$attributes </span>= <span class="src-key">array</span><span class="src-sym">( </span><span class="src-str">'node' </span>=> <span class="src-num">2</span><span class="src-sym">, </span><span class="src-str">'area' </span>=> <span class="src-str">'admin'</span><span class="src-sym">, </span><span class="src-str">'lang' </span>=> <span class="src-str">'en-GB' </span><span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// This function is not part of the Cache package. You have to define</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// unique IDs for your cache items yourself.</span>
+</div></li>
+<li><div class="src-line"> <span class="src-var">$id </span>= <span class="src-id">getUniqueId</span><span class="src-sym">(</span><span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Initialize the data variable you want to restore</span>
+</div></li>
+<li><div class="src-line"> <span class="src-var">$data </span>= <span class="src-str">''</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Check if data is available in the cache. The restore method returns</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// the cached data, if available, or bool false.</span>
+</div></li>
+<li><div class="src-line"> <span class="src-key">if </span><span class="src-sym">( ( </span><span class="src-var">$data </span>= <span class="src-var">$cache</span><span class="src-sym">-></span><span class="src-id">restore</span><span class="src-sym">( </span><span class="src-var">$id</span><span class="src-sym">, </span><span class="src-var">$attributes </span><span class="src-sym">) ) </span>=== <span class="src-id">false </span><span class="src-sym">)</span>
+</div></li>
+<li><div class="src-line"> <span class="src-sym">{</span>
+</div></li>
+<li><div class="src-line">     <span class="src-comm">// The cache item we tried to restore does not exist, so we have to</span>
+</div></li>
+<li><div class="src-line">     <span class="src-comm">// generate the data.</span>
+</div></li>
+<li><div class="src-line">     <span class="src-var">$data </span>= <span class="src-key">array</span><span class="src-sym">( </span><span class="src-str">'This is some data'</span><span class="src-sym">, </span><span class="src-str">'and some more data.' </span><span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line">     <span class="src-comm">// For testing we echo something here...</span>
+</div></li>
+<li><div class="src-line">     echo <span class="src-str">"No cache data found. Generated some.\n"</span>.<a href="http://www.php.net/var_export">var_export</a><span class="src-sym">( </span><span class="src-var">$data</span><span class="src-sym">, </span><span class="src-id">true </span><span class="src-sym">)</span>.<span class="src-str">"\n"</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line">     <span class="src-comm">// Now we store the data in the cache. It will be available through</span>
+</div></li>
+<li><div class="src-line">     <span class="src-comm">// restore, next time the code is reached</span>
+</div></li>
+<li><div class="src-line">     <span class="src-var">$cache</span><span class="src-sym">-></span><span class="src-id">store</span><span class="src-sym">( </span><span class="src-var">$id</span><span class="src-sym">, </span><span class="src-var">$data</span><span class="src-sym">, </span><span class="src-var">$attributes </span><span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> <span class="src-sym">}</span>
+</div></li>
+<li><div class="src-line"> <span class="src-key">else</span>
+</div></li>
+<li><div class="src-line"> <span class="src-sym">{</span>
+</div></li>
+<li><div class="src-line">     <span class="src-comm">// We found cache data. Let's echo the information.</span>
+</div></li>
+<li><div class="src-line">     echo <span class="src-str">"Cache data found.\n"</span>.<a href="http://www.php.net/var_export">var_export</a><span class="src-sym">( </span><span class="src-var">$data</span><span class="src-sym">, </span><span class="src-id">true </span><span class="src-sym">)</span>.<span class="src-str">"\n"</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> <span class="src-sym">}</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// In some other place you can access the second defined cache.</span>
+</div></li>
+<li><div class="src-line"> <span class="src-var">$cache </span>= <span class="src-id"><a href="../Cache/ezcCacheManager.html">ezcCacheManager</a></span><span class="src-sym">::</span><a href="../Cache/ezcCacheManager.html#methodgetCache">getCache</a><span class="src-sym">( </span><span class="src-str">'template' </span><span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+<li><div class="src-line"> </div></li>
+<li><div class="src-line"> <span class="src-comm">// Here we are removing cache items. We do not specify an ID (which would</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// have meant to delete 1 specific cache item), but only an array of</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// attributes. This will result in all cache items to be deleted, that</span>
+</div></li>
+<li><div class="src-line"> <span class="src-comm">// have this attribute assigned.</span>
+</div></li>
+<li><div class="src-line"> <span class="src-var">$cache</span><span class="src-sym">-></span><span class="src-id">delete</span><span class="src-sym">( </span><span class="src-id">null</span><span class="src-sym">, </span><span class="src-key">array</span><span class="src-sym">( </span><span class="src-str">'node' </span>=> <span class="src-num">5 </span><span class="src-sym">) )</span><span class="src-sym">;</span>
+</div></li>
+</ol>
+</div>
<p>Source for this file: <a href="http://fisheye6.atlassian.com/browse/zetacomponents/trunk/Cache/src/manager.php?r=HEAD">/Cache/src/manager.php</a></p>
- <table><tr><td>
+ <table><tr>
+<td>
<strong>Version:</strong>  
</td>
<td>//autogentag//</td>
- </tr></table><a name="sec-method-summary"></a>
+ </tr></table>
+<a name="sec-method-summary"></a>
<h3>Method Summary</h3>
- <table class="summary"><tr><td class="right">
+ <table class="summary">
+<tr>
+<td class="right">
<em>public</em> static
<em>void</em> </td>
<td>
@@ -191,9 +264,11 @@
= array()] )
</code>
<br><div style="margin-left: 20px">Creates a new cache in the manager.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> static
- <em><a href="ezcCacheStorage.html">ezcCacheStorage</a></em> </td>
+ <em><a href="../Cache/ezcCacheStorage.html">ezcCacheStorage</a></em> </td>
<td>
<code>
<a href="#getCache"><b>getCache</b></a>(
@@ -201,7 +276,9 @@
)
</code>
<br><div style="margin-left: 20px">Returns the ezcCacheStorage object with the given ID.</div> </td>
- </tr></table><a name="sec-methods"></a>
+ </tr>
+</table>
+<a name="sec-methods"></a>
<h3>Methods</h3>
<a name="method_detail"></a>
<a name="methodcreateCache" id="createCache"><!-- --></a>
@@ -222,99 +299,162 @@
= array()] )
</div>
- <p>Creates a new cache in the manager.</p><div><p>This method is used to create a new cache inside the manager. Each cache has a unique ID to access it during the application runtime. Each location may only be used by 1 cache.</p><p>The $storageClass parameter must be a subclass of <a href="ezcCacheStorage.html">ezcCacheStorage</a> and tells the manager which object will be used for the cache.</p><p>The $location parameter depends on the kind of <a href="ezcCacheStorage.html">ezcCacheStorage</a> used for the cache you create. Usually this is a directory on your file system, but may also be e.g. a data source name, if you cache in a database or similar. For memory-based storage (<a href="ezcCacheStorageApcPlain.html">ezcCacheStorageApcPlain</a> or <a href="ezcCacheStorageMemcachePlain.html">ezcCacheStorageMemcachePlain</a>) it is null, but for memory/file hybrid storage (<a href="ezcCacheStorageFileApcArray.html">ezcCacheStorageFileApcArray</a>) it should be a
n existing writeable path.</p><p>The $options array consists of several standard attributes and can additionally contain options defined by the <a href="ezcCacheStorage.html">ezcCacheStorage</a> class. Standard options are:</p><p></p><ol><li><div class="src-line"> <span class="src-key">array</span><span class="src-sym">(</span></div></li>
-<li><div class="src-line">      <span class="src-str">'ttl'   </span>=> <span class="src-num">60</span>*<span class="src-num">60</span>*<span class="src-num">24</span><span class="src-sym">,    </span><span class="src-comm">// Time-to-life, default: 1 day</span></div></li>
-<li><div class="src-line"> <span class="src-sym">)</span><span class="src-sym">;</span></div></li>
-</ol></div>
+ <p>Creates a new cache in the manager.</p>
+<div>
+<p>This method is used to create a new cache inside the manager. Each cache has a unique ID to access it during the application runtime. Each location may only be used by 1 cache.</p>
+<p>The $storageClass parameter must be a subclass of <a href="../Cache/ezcCacheStorage.html">ezcCacheStorage</a> and tells the manager which object will be used for the cache.</p>
+<p>The $location parameter depends on the kind of <a href="../Cache/ezcCacheStorage.html">ezcCacheStorage</a> used for the cache you create. Usually this is a directory on your file system, but may also be e.g. a data source name, if you cache in a database or similar. For memory-based storage (<a href="../Cache/ezcCacheStorageApcPlain.html">ezcCacheStorageApcPlain</a> or <a href="../Cache/ezcCacheStorageMemcachePlain.html">ezcCacheStorageMemcachePlain</a>) it is null, but for memory/file hybrid storage (<a href="../Cache/ezcCacheStorageFileApcArray.html">ezcCacheStorageFileApcArray</a>) it should be an existing writeable path.</p>
+<p>The $options array consists of several standard attributes and can additionally contain options defined by the <a href="../Cache/ezcCacheStorage.html">ezcCacheStorage</a> class. Standard options are:</p>
+<p></p>
+<ol>
+<li><div class="src-line"> <span class="src-key">array</span><span class="src-sym">(</span>
+</div></li>
+<li><div class="src-line">      <span class="src-str">'ttl'   </span>=> <span class="src-num">60</span>*<span class="src-num">60</span>*<span class="src-num">24</span><span class="src-sym">,    </span><span class="src-comm">// Time-to-life, default: 1 day</span>
+</div></li>
+<li><div class="src-line"> <span class="src-sym">)</span><span class="src-sym">;</span>
+</div></li>
+</ol>
+</div>
<h5>Parameters:</h5>
- <table class="detail"><thead><tr><th>Name</th>
+ <table class="detail">
+<thead><tr>
+<th>Name</th>
<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code>$id</code></td>
+ </tr></thead>
+<tbody>
+<tr>
+<td><code>$id</code></td>
<td><em>string</em></td>
<td>
ID of the cache to create.
</td>
- </tr><tr><td><code>$location</code></td>
+ </tr>
+<tr>
+<td><code>$location</code></td>
<td><em>string</em></td>
<td>
Location to create the cache in. Null for memory-based storage and an existing writeable path for file or memory/file storage.
</td>
- </tr><tr><td><code>$storageClass</code></td>
+ </tr>
+<tr>
+<td><code>$storageClass</code></td>
<td><em>string</em></td>
<td>
- Subclass of <a href="ezcCacheStorage.html">ezcCacheStorage</a>.
+ Subclass of <a href="../Cache/ezcCacheStorage.html">ezcCacheStorage</a>.
</td>
- </tr><tr><td><code>$options</code></td>
+ </tr>
+<tr>
+<td><code>$options</code></td>
<td><em>array(string=>string)</em></td>
<td>
Options for the cache.
</td>
- </tr></tbody></table><h5>Exceptions:</h5>
- <table class="detail"><thead><tr><th>Type</th>
+ </tr>
+</tbody>
+</table>
+<h5>Exceptions:</h5>
+ <table class="detail">
+<thead><tr>
+<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseFileNotFoundException.html">ezcBaseFileNotFoundException</a></code></td>
- <td>
- If the given location does not exist or is not a directory (thrown by sanity checks performed when storing the configuration of a cache to ensure the latter calls to <a href="ezcCacheManager.html#methodgetCache">ezcCacheManager::getCache()</a> do not fail).
- </td>
- </tr><tr><td><code><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseFilePermissionException.html">ezcBaseFilePermissionException</a></code></td>
- <td>
- If the given location is not read/writeable (thrown by sanity checks performed when storing the configuration of a cache to ensure the latter calls to <a href="ezcCacheManager.html#methodgetCache">ezcCacheManager::getCache()</a> do not fail).
- </td>
- </tr><tr><td><code><a href="ezcCacheInvalidStorageClassException.html">ezcCacheInvalidStorageClassException</a></code></td>
+ </tr></thead>
+<tbody>
+<tr>
+<td><code><a href="../Base/ezcBaseFileNotFoundException.html">ezcBaseFileNotFoundException</a></code></td>
+ <td>
+ If the given location does not exist or is not a directory (thrown by sanity checks performed when storing the configuration of a cache to ensure the latter calls to <a href="../Cache/ezcCacheManager.html#methodgetCache">ezcCacheManager::getCache()</a> do not fail).
+ </td>
+ </tr>
+<tr>
+<td><code><a href="../Base/ezcBaseFilePermissionException.html">ezcBaseFilePermissionException</a></code></td>
+ <td>
+ If the given location is not read/writeable (thrown by sanity checks performed when storing the configuration of a cache to ensure the latter calls to <a href="../Cache/ezcCacheManager.html#methodgetCache">ezcCacheManager::getCache()</a> do not fail).
+ </td>
+ </tr>
+<tr>
+<td><code><a href="../Cache/ezcCacheInvalidStorageClassException.html">ezcCacheInvalidStorageClassException</a></code></td>
<td>
If the given storage class does not exist or is no subclass of ezcCacheStorage.
</td>
- </tr><tr><td><code><a href="ezcCacheUsedLocationException.html">ezcCacheUsedLocationException</a></code></td>
+ </tr>
+<tr>
+<td><code><a href="../Cache/ezcCacheUsedLocationException.html">ezcCacheUsedLocationException</a></code></td>
<td>
If the given location is already in use by another cache.
</td>
- </tr></tbody></table><a name="methodgetCache" id="getCache"><!-- --></a>
+ </tr>
+</tbody>
+</table>
+<a name="methodgetCache" id="getCache"><!-- --></a>
<h4>getCache</h4>
<div class="method-signature">
- static <a href="ezcCacheStorage.html">ezcCacheStorage</a>
+ static <a href="../Cache/ezcCacheStorage.html">ezcCacheStorage</a>
getCache(
string
$id
)
</div>
- <p>Returns the ezcCacheStorage object with the given ID.</p><div><p>The cache ID has to be defined before using the <a href="ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a> method. If no instance of this cache does exist yet, it's created on the fly. If one exists, it will be reused.</p></div>
+ <p>Returns the ezcCacheStorage object with the given ID.</p>
+<div><p>The cache ID has to be defined before using the <a href="../Cache/ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a> method. If no instance of this cache does exist yet, it's created on the fly. If one exists, it will be reused.</p></div>
<h5>Parameters:</h5>
- <table class="detail"><thead><tr><th>Name</th>
+ <table class="detail">
+<thead><tr>
+<th>Name</th>
<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code>$id</code></td>
+ </tr></thead>
+<tbody><tr>
+<td><code>$id</code></td>
<td><em>string</em></td>
<td>
The ID of the cache to return.
</td>
- </tr></tbody></table><h5>Exceptions:</h5>
- <table class="detail"><thead><tr><th>Type</th>
+ </tr></tbody>
+</table>
+<h5>Exceptions:</h5>
+ <table class="detail">
+<thead><tr>
+<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code><a href="ezcCacheInvalidIdException.html">ezcCacheInvalidIdException</a></code></td>
- <td>
- If the ID of a cache you try to access does not exist. To access a cache using this method, it first hast to be created using <a href="ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a>.
- </td>
- </tr><tr><td><code><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBasePropertyNotFoundException.html">ezcBasePropertyNotFoundException</a></code></td>
+ </tr></thead>
+<tbody>
+<tr>
+<td><code><a href="../Cache/ezcCacheInvalidIdException.html">ezcCacheInvalidIdException</a></code></td>
+ <td>
+ If the ID of a cache you try to access does not exist. To access a cache using this method, it first hast to be created using <a href="../Cache/ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a>.
+ </td>
+ </tr>
+<tr>
+<td><code><a href="../Base/ezcBasePropertyNotFoundException.html">ezcBasePropertyNotFoundException</a></code></td>
<td>
If you tried to set a non-existent option value. The accepted options depend on the ezcCacheStorage implementation and may vary.
</td>
- </tr><tr><td><code><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseFileNotFoundException.html">ezcBaseFileNotFoundException</a></code></td>
+ </tr>
+<tr>
+<td><code><a href="../Base/ezcBaseFileNotFoundException.html">ezcBaseFileNotFoundException</a></code></td>
<td>
- If the storage location does not exist. This should usually not happen, since <a href="ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a> already performs sanity checks for the cache location. In case this exception is thrown, your cache location has been corrupted after the cache was configured.
+ If the storage location does not exist. This should usually not happen, since <a href="../Cache/ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a> already performs sanity checks for the cache location. In case this exception is thrown, your cache location has been corrupted after the cache was configured.
</td>
- </tr><tr><td><code><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseFileNotFoundException.html">ezcBaseFileNotFoundException</a></code></td>
+ </tr>
+<tr>
+<td><code><a href="../Base/ezcBaseFileNotFoundException.html">ezcBaseFileNotFoundException</a></code></td>
<td>
- If the storage location is not a directory. This should usually not happen, since <a href="ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a> already performs sanity checks for the cache location. In case this exception is thrown, your cache location has been corrupted after the cache was configured.
+ If the storage location is not a directory. This should usually not happen, since <a href="../Cache/ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a> already performs sanity checks for the cache location. In case this exception is thrown, your cache location has been corrupted after the cache was configured.
</td>
- </tr><tr><td><code><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseFilePermissionException.html">ezcBaseFilePermissionException</a></code></td>
+ </tr>
+<tr>
+<td><code><a href="../Base/ezcBaseFilePermissionException.html">ezcBaseFilePermissionException</a></code></td>
<td>
- If the storage location is not writeable. This should usually not happen, since <a href="ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a> already performs sanity checks for the cache location. In case this exception is thrown, your cache location has been corrupted after the cache was configured.
+ If the storage location is not writeable. This should usually not happen, since <a href="../Cache/ezcCacheManager.html#methodcreateCache">ezcCacheManager::createCache()</a> already performs sanity checks for the cache location. In case this exception is thrown, your cache location has been corrupted after the cache was configured.
</td>
- </tr></tbody></table><div class="credit">
+ </tr>
+</tbody>
+</table>
+<div class="credit">
Documentation generated by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</div>
Modified: incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheBackend.html
URL: http://svn.apache.org/viewvc/incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheBackend.html?rev=1089394&r1=1089393&r2=1089394&view=diff
==============================================================================
--- incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheBackend.html (original)
+++ incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheBackend.html Wed Apr 6 10:44:44 2011
@@ -9,16 +9,16 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="description" content="Apache Zeta Components - reusable set of high quality PHP components to fasten your development." />
- <meta name="keywords" content="PHP, apache, components, framework, quality" />
- <meta name="author" content="dotxp" />
+ <meta name="keywords" content="" />
+ <meta name="author" content="jerome" />
<meta name="language" content="en" />
- <meta name="date" content="Wed, 04 Aug 2010 13:07:17 +0200" />
+ <meta name="date" content="Wed, 06 Apr 2011 12:38:18 +0200" />
<meta name="robots" content="all" />
<link rel="schema.DC" href="http://purl.org/dc/elements/1.1/" />
<meta name="DC.title" content="ezcCacheMemcacheBackend.html" />
- <meta name="DC.creator" content="dotxp" />
- <meta name="DC.date" content="Wed, 04 Aug 2010 13:07:17 +0200" />
+ <meta name="DC.creator" content="jerome" />
+ <meta name="DC.date" content="Wed, 06 Apr 2011 12:38:18 +0200" />
<meta name="DC.rights" content="Copyright" />
<link rel="meta" href="/zetacomponents/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheBackend.rdf" />
@@ -68,10 +68,7 @@
<div class="content">
<ul class="tabs">
- <li >
- <a href="/zetacomponents/documentation/trunk/Cache/tutorial.html" title="Tutorial">Tutorial</a>
- </li>
-<li class="requested">
+ <li class="requested">
<a href="/zetacomponents/documentation/trunk/Cache/phpdoc/classtrees.html" title="API">API</a>
</li>
@@ -91,18 +88,22 @@
-<pre><a href="ezcCacheMemoryBackend.html">ezcCacheMemoryBackend</a>
+<pre><a href="../Cache/ezcCacheMemoryBackend.html">ezcCacheMemoryBackend</a>
|
--ezcCacheMemcacheBackend</pre>
- <table><tr><td>
+ <table><tr>
+<td>
<strong>Version:</strong>  
</td>
<td>//autogentag//</td>
- </tr></table><a name="sec-const-summary"></a>
+ </tr></table>
+<a name="sec-const-summary"></a>
<h3>Constants</h3>
- <table class="summary"><tr><td class="right">
+ <table class="summary">
+<tr>
+<td class="right">
<a name="const-COMPRESS_THRESHOLD" id=""></a>
<code>
<a href="#const-COMPRESS_THRESHOLD" title="details" class="const-name-summary">COMPRESS_THRESHOLD</a>
@@ -111,7 +112,9 @@
</td>
<td>
The compress threshold. <p>Nearly 1MB (48,576B less).</p> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<a name="const-MAX_KEY_LENGTH" id=""></a>
<code>
<a href="#const-MAX_KEY_LENGTH" title="details" class="const-name-summary">MAX_KEY_LENGTH</a>
@@ -120,9 +123,13 @@
</td>
<td>
Maximum length of a cache key for Memcached. </td>
- </tr></table><a name="sec-var-summary"></a>
+ </tr>
+</table>
+<a name="sec-var-summary"></a>
<h3>Member Variables</h3>
- <table class="summary"><tr><td class="right">
+ <table class="summary">
+<tr>
+<td class="right">
<em>protected</em> static
<em>array(string=>int)</em> </td>
<td>
@@ -130,7 +137,9 @@
$connectionCounter
</code>
<br><div style="margin-left: 20px">Keeps track of the number of backends using the same connection.</div> <br><div style="margin-left: 20px"><p>This is to avoid that the dtor of a backend accedentally closes a connection that is still in used by another backend.</p></div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>protected</em> static
<em>array(string=>Memcache)</em> </td>
<td>
@@ -138,30 +147,40 @@
$connections
</code>
<br><div style="margin-left: 20px">Stores the connections to Memcached.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>protected</em> <em>string</em> </td>
<td>
<code>
$connectionIdentifier
</code>
<br><div style="margin-left: 20px">Stores the connection identifier.</div> <br><div style="margin-left: 20px"><p>This is generated in the ctor and used in the dtor.</p></div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>protected</em> <em>resource</em> </td>
<td>
<code>
$memcache
</code>
<br><div style="margin-left: 20px">Holds an instance to a Memcache object.</div> </td>
- </tr><tr><td class="right">
- <em>protected</em> <em><a href="ezcCacheStorageMemcacheOptions.html">ezcCacheStorageMemcacheOptions</a></em> </td>
+ </tr>
+<tr>
+<td class="right">
+ <em>protected</em> <em><a href="../Cache/ezcCacheStorageMemcacheOptions.html">ezcCacheStorageMemcacheOptions</a></em> </td>
<td>
<code>
$options
</code>
<br><div style="margin-left: 20px">Holds the options for this class.</div> </td>
- </tr></table><a name="sec-method-summary"></a>
+ </tr>
+</table>
+<a name="sec-method-summary"></a>
<h3>Method Summary</h3>
- <table class="summary"><tr><td class="right">
+ <table class="summary">
+<tr>
+<td class="right">
<em>public</em> <em>ezcCacheMemcacheBackend</em> </td>
<td>
<code>
@@ -170,7 +189,9 @@
= array()] )
</code>
<br><div style="margin-left: 20px">Constructs a new ezcCacheMemcacheBackend object.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> <em>void</em> </td>
<td>
<code>
@@ -178,7 +199,9 @@
)
</code>
<br><div style="margin-left: 20px">Destructor for the Memcache backend.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> <em>void</em> </td>
<td>
<code>
@@ -189,7 +212,9 @@
)
</code>
<br><div style="margin-left: 20px">Acquires a lock on the given $key.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> <em>bool</em> </td>
<td>
<code>
@@ -199,7 +224,9 @@
= 0] )
</code>
<br><div style="margin-left: 20px">Deletes the data from the cache associated with key $key. Returns true or false depending on the success of the operation.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> <em>mixed</em> </td>
<td>
<code>
@@ -208,7 +235,9 @@
)
</code>
<br><div style="margin-left: 20px">Returns the data from the cache associated with key $key.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> <em>void</em> </td>
<td>
<code>
@@ -217,7 +246,9 @@
)
</code>
<br><div style="margin-left: 20px">Releases a lock on the given $key.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> <em>void</em> </td>
<td>
<code>
@@ -225,7 +256,9 @@
)
</code>
<br><div style="margin-left: 20px">Resets the complete backend.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> <em>bool</em> </td>
<td>
<code>
@@ -236,26 +269,40 @@
= 0] )
</code>
<br><div style="margin-left: 20px">Adds the $var data to the cache under the key $key. Returns true or false depending on the success of the operation.</div> </td>
- </tr></table><h3>Inherited Methods</h3>
- <table class="summary"><thead><tr><th colspan="2">
- From <span class="classname"><a href="ezcCacheMemoryBackend.html">ezcCacheMemoryBackend</a></span>
+ </tr>
+</table>
+<h3>Inherited Methods</h3>
+ <table class="summary">
+<thead><tr>
+<th colspan="2">
+ From <span class="classname"><a href="../Cache/ezcCacheMemoryBackend.html">ezcCacheMemoryBackend</a></span>
</th>
- </tr></thead><tbody><tr><td class="right">
+ </tr></thead>
+<tbody>
+<tr>
+<td class="right">
<em>public</em> abstract <em>bool</em> </td>
<td>
- <code><b><a href="ezcCacheMemoryBackend.html#methoddelete">ezcCacheMemoryBackend::delete()</a></b></code>
+ <code><b><a href="../Cache/ezcCacheMemoryBackend.html#methoddelete">ezcCacheMemoryBackend::delete()</a></b></code>
<br><div style="margin-left: 20px">Deletes the data associated with key $key.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> abstract <em>mixed</em> </td>
<td>
- <code><b><a href="ezcCacheMemoryBackend.html#methodfetch">ezcCacheMemoryBackend::fetch()</a></b></code>
+ <code><b><a href="../Cache/ezcCacheMemoryBackend.html#methodfetch">ezcCacheMemoryBackend::fetch()</a></b></code>
<br><div style="margin-left: 20px">Fetches the data associated with key $key.</div> </td>
- </tr><tr><td class="right">
+ </tr>
+<tr>
+<td class="right">
<em>public</em> abstract <em>bool</em> </td>
<td>
- <code><b><a href="ezcCacheMemoryBackend.html#methodstore">ezcCacheMemoryBackend::store()</a></b></code>
+ <code><b><a href="../Cache/ezcCacheMemoryBackend.html#methodstore">ezcCacheMemoryBackend::store()</a></b></code>
<br><div style="margin-left: 20px">Stores the data $var under the key $key.</div> </td>
- </tr></tbody></table><a name="sec-methods"></a>
+ </tr>
+</tbody>
+</table>
+<a name="sec-methods"></a>
<h3>Methods</h3>
<a name="method_detail"></a>
@@ -271,27 +318,44 @@
= array()] )
</div>
- <p>Constructs a new ezcCacheMemcacheBackend object.</p><div><p>For options for this backend see <a href="ezcCacheStorageMemcacheOptions.html">ezcCacheStorageMemcacheOptions</a>.</p></div>
+ <p>Constructs a new ezcCacheMemcacheBackend object.</p>
+<div><p>For options for this backend see <a href="../Cache/ezcCacheStorageMemcacheOptions.html">ezcCacheStorageMemcacheOptions</a>.</p></div>
<h5>Parameters:</h5>
- <table class="detail"><thead><tr><th>Name</th>
+ <table class="detail">
+<thead><tr>
+<th>Name</th>
<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code>$options</code></td>
+ </tr></thead>
+<tbody><tr>
+<td><code>$options</code></td>
<td><em>array(string=>mixed)</em></td>
<td>
</td>
- </tr></tbody></table><h5>Exceptions:</h5>
- <table class="detail"><thead><tr><th>Type</th>
+ </tr></tbody>
+</table>
+<h5>Exceptions:</h5>
+ <table class="detail">
+<thead><tr>
+<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code><a href="ezcCacheMemcacheException.html">ezcCacheMemcacheException</a></code></td>
+ </tr></thead>
+<tbody>
+<tr>
+<td><code><a href="../Cache/ezcCacheMemcacheException.html">ezcCacheMemcacheException</a></code></td>
<td>
If the connection to the Memcache host did not succeed.
</td>
- </tr><tr><td><code><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseExtensionNotFoundException.html">ezcBaseExtensionNotFoundException</a></code></td>
+ </tr>
+<tr>
+<td><code><a href="../Base/ezcBaseExtensionNotFoundException.html">ezcBaseExtensionNotFoundException</a></code></td>
<td>
If the PHP memcache and zlib extensions are not installed.
</td>
- </tr></tbody></table><a name="method__destruct" id="__destruct"><!-- --></a>
+ </tr>
+</tbody>
+</table>
+<a name="method__destruct" id="__destruct"><!-- --></a>
<h4>__destruct</h4>
@@ -326,24 +390,36 @@
<p>Acquires a lock on the given $key.</p>
<h5>Parameters:</h5>
- <table class="detail"><thead><tr><th>Name</th>
+ <table class="detail">
+<thead><tr>
+<th>Name</th>
<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code>$key</code></td>
+ </tr></thead>
+<tbody>
+<tr>
+<td><code>$key</code></td>
<td><em>string</em></td>
<td>
</td>
- </tr><tr><td><code>$waitTime</code></td>
+ </tr>
+<tr>
+<td><code>$waitTime</code></td>
<td><em>int</em></td>
<td>
usleep()
</td>
- </tr><tr><td><code>$maxTime</code></td>
+ </tr>
+<tr>
+<td><code>$maxTime</code></td>
<td><em>int</em></td>
<td>
seconds
</td>
- </tr></tbody></table><a name="methoddelete" id="delete"><!-- --></a>
+ </tr>
+</tbody>
+</table>
+<a name="methoddelete" id="delete"><!-- --></a>
<h4>delete</h4>
@@ -357,27 +433,44 @@
= 0] )
</div>
- <p>Deletes the data from the cache associated with key $key. Returns true or false depending on the success of the operation.</p><div><p>The value $timeout specifies the timeout period in seconds for the delete command.</p></div>
+ <p>Deletes the data from the cache associated with key $key. Returns true or false depending on the success of the operation.</p>
+<div><p>The value $timeout specifies the timeout period in seconds for the delete command.</p></div>
<h5>Parameters:</h5>
- <table class="detail"><thead><tr><th>Name</th>
+ <table class="detail">
+<thead><tr>
+<th>Name</th>
<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code>$key</code></td>
+ </tr></thead>
+<tbody>
+<tr>
+<td><code>$key</code></td>
<td><em>string</em></td>
<td>
</td>
- </tr><tr><td><code>$timeout</code></td>
+ </tr>
+<tr>
+<td><code>$timeout</code></td>
<td><em>int</em></td>
<td>
</td>
- </tr></tbody></table><h5>Redefinition of:</h5>
- <table class="detail"><thead><tr><th>Method</th>
+ </tr>
+</tbody>
+</table>
+<h5>Redefinition of:</h5>
+ <table class="detail">
+<thead><tr>
+<th>Method</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code><a href="ezcCacheMemoryBackend.html#methoddelete">ezcCacheMemoryBackend::delete()</a></code></td>
+ </tr></thead>
+<tbody><tr>
+<td><code><a href="../Cache/ezcCacheMemoryBackend.html#methoddelete">ezcCacheMemoryBackend::delete()</a></code></td>
<td>
Deletes the data associated with key $key.
</td>
- </tr></tbody></table><a name="methodfetch" id="fetch"><!-- --></a>
+ </tr></tbody>
+</table>
+<a name="methodfetch" id="fetch"><!-- --></a>
<h4>fetch</h4>
@@ -391,21 +484,33 @@
<p>Returns the data from the cache associated with key $key.</p>
<h5>Parameters:</h5>
- <table class="detail"><thead><tr><th>Name</th>
+ <table class="detail">
+<thead><tr>
+<th>Name</th>
<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code>$key</code></td>
+ </tr></thead>
+<tbody><tr>
+<td><code>$key</code></td>
<td><em>mixed</em></td>
<td>
</td>
- </tr></tbody></table><h5>Redefinition of:</h5>
- <table class="detail"><thead><tr><th>Method</th>
+ </tr></tbody>
+</table>
+<h5>Redefinition of:</h5>
+ <table class="detail">
+<thead><tr>
+<th>Method</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code><a href="ezcCacheMemoryBackend.html#methodfetch">ezcCacheMemoryBackend::fetch()</a></code></td>
+ </tr></thead>
+<tbody><tr>
+<td><code><a href="../Cache/ezcCacheMemoryBackend.html#methodfetch">ezcCacheMemoryBackend::fetch()</a></code></td>
<td>
Fetches the data associated with key $key.
</td>
- </tr></tbody></table><a name="methodreleaseLock" id="releaseLock"><!-- --></a>
+ </tr></tbody>
+</table>
+<a name="methodreleaseLock" id="releaseLock"><!-- --></a>
<h4>releaseLock</h4>
@@ -419,14 +524,20 @@
<p>Releases a lock on the given $key.</p>
<h5>Parameters:</h5>
- <table class="detail"><thead><tr><th>Name</th>
+ <table class="detail">
+<thead><tr>
+<th>Name</th>
<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code>$key</code></td>
+ </tr></thead>
+<tbody><tr>
+<td><code>$key</code></td>
<td><em>string</em></td>
<td>
</td>
- </tr></tbody></table><a name="methodreset" id="reset"><!-- --></a>
+ </tr></tbody>
+</table>
+<a name="methodreset" id="reset"><!-- --></a>
<h4>reset</h4>
@@ -436,7 +547,8 @@
)
</div>
- <p>Resets the complete backend.</p><div><p>Marked private to not expose more of this interface to the user, since this will be removed in future versions.</p></div>
+ <p>Resets the complete backend.</p>
+<div><p>Marked private to not expose more of this interface to the user, since this will be removed in future versions.</p></div>
@@ -461,29 +573,47 @@
<p>Adds the $var data to the cache under the key $key. Returns true or false depending on the success of the operation.</p>
<h5>Parameters:</h5>
- <table class="detail"><thead><tr><th>Name</th>
+ <table class="detail">
+<thead><tr>
+<th>Name</th>
<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code>$key</code></td>
+ </tr></thead>
+<tbody>
+<tr>
+<td><code>$key</code></td>
<td><em>string</em></td>
<td>
</td>
- </tr><tr><td><code>$var</code></td>
+ </tr>
+<tr>
+<td><code>$var</code></td>
<td><em>mixed</em></td>
<td>
</td>
- </tr><tr><td><code>$expire</code></td>
+ </tr>
+<tr>
+<td><code>$expire</code></td>
<td><em>int</em></td>
<td>
</td>
- </tr></tbody></table><h5>Redefinition of:</h5>
- <table class="detail"><thead><tr><th>Method</th>
+ </tr>
+</tbody>
+</table>
+<h5>Redefinition of:</h5>
+ <table class="detail">
+<thead><tr>
+<th>Method</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code><a href="ezcCacheMemoryBackend.html#methodstore">ezcCacheMemoryBackend::store()</a></code></td>
+ </tr></thead>
+<tbody><tr>
+<td><code><a href="../Cache/ezcCacheMemoryBackend.html#methodstore">ezcCacheMemoryBackend::store()</a></code></td>
<td>
Stores the data $var under the key $key.
</td>
- </tr></tbody></table><div class="credit">
+ </tr></tbody>
+</table>
+<div class="credit">
Documentation generated by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</div>
Modified: incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheException.html
URL: http://svn.apache.org/viewvc/incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheException.html?rev=1089394&r1=1089393&r2=1089394&view=diff
==============================================================================
--- incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheException.html (original)
+++ incubator/zetacomponents/website/htdocs/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheException.html Wed Apr 6 10:44:44 2011
@@ -9,16 +9,16 @@
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="description" content="Apache Zeta Components - reusable set of high quality PHP components to fasten your development." />
- <meta name="keywords" content="PHP, apache, components, framework, quality" />
- <meta name="author" content="dotxp" />
+ <meta name="keywords" content="" />
+ <meta name="author" content="jerome" />
<meta name="language" content="en" />
- <meta name="date" content="Wed, 04 Aug 2010 13:07:17 +0200" />
+ <meta name="date" content="Wed, 06 Apr 2011 12:38:18 +0200" />
<meta name="robots" content="all" />
<link rel="schema.DC" href="http://purl.org/dc/elements/1.1/" />
<meta name="DC.title" content="ezcCacheMemcacheException.html" />
- <meta name="DC.creator" content="dotxp" />
- <meta name="DC.date" content="Wed, 04 Aug 2010 13:07:17 +0200" />
+ <meta name="DC.creator" content="jerome" />
+ <meta name="DC.date" content="Wed, 06 Apr 2011 12:38:18 +0200" />
<meta name="DC.rights" content="Copyright" />
<link rel="meta" href="/zetacomponents/documentation/trunk/Cache/phpdoc/ezcCacheMemcacheException.rdf" />
@@ -68,10 +68,7 @@
<div class="content">
<ul class="tabs">
- <li >
- <a href="/zetacomponents/documentation/trunk/Cache/tutorial.html" title="Tutorial">Tutorial</a>
- </li>
-<li class="requested">
+ <li class="requested">
<a href="/zetacomponents/documentation/trunk/Cache/phpdoc/classtrees.html" title="API">API</a>
</li>
@@ -93,28 +90,37 @@
<pre>Exception
|
- --<a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseException.html">ezcBaseException</a>
+ --<a href="../Base/ezcBaseException.html">ezcBaseException</a>
|
--ezcCacheMemcacheException</pre>
- <table><tr><td>
+ <table><tr>
+<td>
<strong>Version:</strong>  
</td>
<td>//autogen//</td>
- </tr></table><h3>Inherited Member Variables</h3>
- <table class="summary"><thead><tr><th colspan="2">
- From <span class="classname"><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseException.html">ezcBaseException</a></span>
+ </tr></table>
+<h3>Inherited Member Variables</h3>
+ <table class="summary">
+<thead><tr>
+<th colspan="2">
+ From <span class="classname"><a href="../Base/ezcBaseException.html">ezcBaseException</a></span>
</th>
- </tr></thead><tbody><tr><td class="right">
+ </tr></thead>
+<tbody><tr>
+<td class="right">
<em>public</em> </td>
<td>
- <code><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseException.html#var%24originalMessage">ezcBaseException::$originalMessage</a></code>
+ <code><a href="../Base/ezcBaseException.html#var%24originalMessage">ezcBaseException::$originalMessage</a></code>
</td>
- </tr></tbody></table><a name="sec-method-summary"></a>
+ </tr></tbody>
+</table>
+<a name="sec-method-summary"></a>
<h3>Method Summary</h3>
- <table class="summary"><tr><td class="right">
+ <table class="summary"><tr>
+<td class="right">
<em>public</em> <em>ezcCacheMemcacheException</em> </td>
<td>
<code>
@@ -123,16 +129,23 @@
)
</code>
<br><div style="margin-left: 20px">Creates a new ezcCacheMemcacheException.</div> </td>
- </tr></table><h3>Inherited Methods</h3>
- <table class="summary"><thead><tr><th colspan="2">
- From <span class="classname"><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseException.html">ezcBaseException</a></span>
+ </tr></table>
+<h3>Inherited Methods</h3>
+ <table class="summary">
+<thead><tr>
+<th colspan="2">
+ From <span class="classname"><a href="../Base/ezcBaseException.html">ezcBaseException</a></span>
</th>
- </tr></thead><tbody><tr><td class="right">
+ </tr></thead>
+<tbody><tr>
+<td class="right">
<em>public</em> <em>ezcBaseException</em> </td>
<td>
- <code><b><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseException.html#method__construct">ezcBaseException::__construct()</a></b></code>
+ <code><b><a href="../Base/ezcBaseException.html#method__construct">ezcBaseException::__construct()</a></b></code>
<br><div style="margin-left: 20px">Constructs a new ezcBaseException with $message</div> </td>
- </tr></tbody></table><a name="sec-methods"></a>
+ </tr></tbody>
+</table>
+<a name="sec-methods"></a>
<h3>Methods</h3>
<a name="method_detail"></a>
@@ -150,22 +163,34 @@
<p>Creates a new ezcCacheMemcacheException.</p>
<h5>Parameters:</h5>
- <table class="detail"><thead><tr><th>Name</th>
+ <table class="detail">
+<thead><tr>
+<th>Name</th>
<th>Type</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code>$message</code></td>
+ </tr></thead>
+<tbody><tr>
+<td><code>$message</code></td>
<td><em>mixed</em></td>
<td>
The message to throw
</td>
- </tr></tbody></table><h5>Redefinition of:</h5>
- <table class="detail"><thead><tr><th>Method</th>
+ </tr></tbody>
+</table>
+<h5>Redefinition of:</h5>
+ <table class="detail">
+<thead><tr>
+<th>Method</th>
<th class="desc">Description</th>
- </tr></thead><tbody><tr><td><code><a href="/zetacomponents/documentation/trunk/Base/phpdoc/ezcBaseException.html#method__construct">ezcBaseException::__construct()</a></code></td>
+ </tr></thead>
+<tbody><tr>
+<td><code><a href="../Base/ezcBaseException.html#method__construct">ezcBaseException::__construct()</a></code></td>
<td>
Constructs a new ezcBaseException with $message
</td>
- </tr></tbody></table><div class="credit">
+ </tr></tbody>
+</table>
+<div class="credit">
Documentation generated by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</div>