1<?xml version="1.0" encoding="ascii"?> 2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 3 "DTD/xhtml1-transitional.dtd"> 4<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> 5<head> 6 <title>googleapiclient.discovery_cache.base.Cache</title> 7 <link rel="stylesheet" href="epydoc.css" type="text/css" /> 8 <script type="text/javascript" src="epydoc.js"></script> 9</head> 10 11<body bgcolor="white" text="black" link="blue" vlink="#204080" 12 alink="#204080"> 13<!-- ==================== NAVIGATION BAR ==================== --> 14<table class="navbar" border="0" width="100%" cellpadding="0" 15 bgcolor="#a0c0ff" cellspacing="0"> 16 <tr valign="middle"> 17 <!-- Home link --> 18 <th> <a 19 href="googleapiclient-module.html">Home</a> </th> 20 21 <!-- Tree link --> 22 <th> <a 23 href="module-tree.html">Trees</a> </th> 24 25 <!-- Index link --> 26 <th> <a 27 href="identifier-index.html">Indices</a> </th> 28 29 <!-- Help link --> 30 <th> <a 31 href="help.html">Help</a> </th> 32 33 <th class="navbar" width="100%"></th> 34 </tr> 35</table> 36<table width="100%" cellpadding="0" cellspacing="0"> 37 <tr valign="top"> 38 <td width="100%"> 39 <span class="breadcrumbs"> 40 <a href="googleapiclient-module.html">Package googleapiclient</a> :: 41 <a href="googleapiclient.discovery_cache-module.html">Package discovery_cache</a> :: 42 <a href="googleapiclient.discovery_cache.base-module.html">Module base</a> :: 43 Class Cache 44 </span> 45 </td> 46 <td> 47 <table cellpadding="0" cellspacing="0"> 48 <!-- hide/show private --> 49 <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" 50 onclick="toggle_private();">hide private</a>]</span></td></tr> 51 <tr><td align="right"><span class="options" 52 >[<a href="frames.html" target="_top">frames</a 53 >] | <a href="googleapiclient.discovery_cache.base.Cache-class.html" 54 target="_top">no frames</a>]</span></td></tr> 55 </table> 56 </td> 57 </tr> 58</table> 59<!-- ==================== CLASS DESCRIPTION ==================== --> 60<h1 class="epydoc">Class Cache</h1><p class="nomargin-top"><span class="codelink"><a href="googleapiclient.discovery_cache.base-pysrc.html#Cache">source code</a></span></p> 61<center> 62<center> <map id="uml_class_diagram_for_googleap_8" name="uml_class_diagram_for_googleap_8"> 63<area shape="rect" id="node1_3" href="googleapiclient.discovery_cache.base.Cache-class.html#__metaclass__" title="googleapiclient.discovery_cache.base.Cache.__metaclass__" alt="" coords="18,29,145,49"/> 64<area shape="rect" id="node1_4" href="googleapiclient.discovery_cache.base.Cache-class.html#get" title="Gets the content from the memcache with a given key." alt="" coords="18,52,145,72"/> 65<area shape="rect" id="node1_5" href="googleapiclient.discovery_cache.base.Cache-class.html#set" title="Sets the given key and content in the cache." alt="" coords="18,72,145,92"/> 66<area shape="rect" id="node1" href="googleapiclient.discovery_cache.base.Cache-class.html" title="A base abstract cache class." alt="" coords="5,5,156,99"/> 67</map> 68 <img src="uml_class_diagram_for_googleap_8.gif" alt='' usemap="#uml_class_diagram_for_googleap_8" ismap="ismap" class="graph-without-title" /> 69</center> 70</center> 71<hr /> 72<pre class="literalblock"> 73A base abstract cache class. 74 75</pre> 76 77<!-- ==================== INSTANCE METHODS ==================== --> 78<a name="section-InstanceMethods"></a> 79<table class="summary" border="1" cellpadding="3" 80 cellspacing="0" width="100%" bgcolor="white"> 81<tr bgcolor="#70b0f0" class="table-header"> 82 <td colspan="2" class="table-header"> 83 <table border="0" cellpadding="0" cellspacing="0" width="100%"> 84 <tr valign="top"> 85 <td align="left"><span class="table-header">Instance Methods</span></td> 86 <td align="right" valign="top" 87 ><span class="options">[<a href="#section-InstanceMethods" 88 class="privatelink" onclick="toggle_private();" 89 >hide private</a>]</span></td> 90 </tr> 91 </table> 92 </td> 93</tr> 94<tr> 95 <td width="15%" align="right" valign="top" class="summary"> 96 <span class="summary-type"> </span> 97 </td><td class="summary"> 98 <table width="100%" cellpadding="0" cellspacing="0" border="0"> 99 <tr> 100 <td><span class="summary-sig"><a href="googleapiclient.discovery_cache.base.Cache-class.html#get" class="summary-sig-name">get</a>(<span class="summary-sig-arg">self</span>, 101 <span class="summary-sig-arg">url</span>)</span><br /> 102 Gets the content from the memcache with a given key.</td> 103 <td align="right" valign="top"> 104 <span class="codelink"><a href="googleapiclient.discovery_cache.base-pysrc.html#Cache.get">source code</a></span> 105 106 </td> 107 </tr> 108 </table> 109 110 </td> 111 </tr> 112<tr> 113 <td width="15%" align="right" valign="top" class="summary"> 114 <span class="summary-type"> </span> 115 </td><td class="summary"> 116 <table width="100%" cellpadding="0" cellspacing="0" border="0"> 117 <tr> 118 <td><span class="summary-sig"><a href="googleapiclient.discovery_cache.base.Cache-class.html#set" class="summary-sig-name">set</a>(<span class="summary-sig-arg">self</span>, 119 <span class="summary-sig-arg">url</span>, 120 <span class="summary-sig-arg">content</span>)</span><br /> 121 Sets the given key and content in the cache.</td> 122 <td align="right" valign="top"> 123 <span class="codelink"><a href="googleapiclient.discovery_cache.base-pysrc.html#Cache.set">source code</a></span> 124 125 </td> 126 </tr> 127 </table> 128 129 </td> 130 </tr> 131 <tr> 132 <td colspan="2" class="summary"> 133 <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>: 134 <code>__delattr__</code>, 135 <code>__format__</code>, 136 <code>__getattribute__</code>, 137 <code>__hash__</code>, 138 <code>__init__</code>, 139 <code>__new__</code>, 140 <code>__reduce__</code>, 141 <code>__reduce_ex__</code>, 142 <code>__repr__</code>, 143 <code>__setattr__</code>, 144 <code>__sizeof__</code>, 145 <code>__str__</code>, 146 <code>__subclasshook__</code> 147 </p> 148 </td> 149 </tr> 150</table> 151<!-- ==================== CLASS VARIABLES ==================== --> 152<a name="section-ClassVariables"></a> 153<table class="summary" border="1" cellpadding="3" 154 cellspacing="0" width="100%" bgcolor="white"> 155<tr bgcolor="#70b0f0" class="table-header"> 156 <td colspan="2" class="table-header"> 157 <table border="0" cellpadding="0" cellspacing="0" width="100%"> 158 <tr valign="top"> 159 <td align="left"><span class="table-header">Class Variables</span></td> 160 <td align="right" valign="top" 161 ><span class="options">[<a href="#section-ClassVariables" 162 class="privatelink" onclick="toggle_private();" 163 >hide private</a>]</span></td> 164 </tr> 165 </table> 166 </td> 167</tr> 168<tr> 169 <td width="15%" align="right" valign="top" class="summary"> 170 <span class="summary-type"> </span> 171 </td><td class="summary"> 172 <a name="__metaclass__"></a><span class="summary-name">__metaclass__</span> = <code title="abc.ABCMeta">abc.ABCMeta</code> 173 </td> 174 </tr> 175</table> 176<!-- ==================== PROPERTIES ==================== --> 177<a name="section-Properties"></a> 178<table class="summary" border="1" cellpadding="3" 179 cellspacing="0" width="100%" bgcolor="white"> 180<tr bgcolor="#70b0f0" class="table-header"> 181 <td colspan="2" class="table-header"> 182 <table border="0" cellpadding="0" cellspacing="0" width="100%"> 183 <tr valign="top"> 184 <td align="left"><span class="table-header">Properties</span></td> 185 <td align="right" valign="top" 186 ><span class="options">[<a href="#section-Properties" 187 class="privatelink" onclick="toggle_private();" 188 >hide private</a>]</span></td> 189 </tr> 190 </table> 191 </td> 192</tr> 193 <tr> 194 <td colspan="2" class="summary"> 195 <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>: 196 <code>__class__</code> 197 </p> 198 </td> 199 </tr> 200</table> 201<!-- ==================== METHOD DETAILS ==================== --> 202<a name="section-MethodDetails"></a> 203<table class="details" border="1" cellpadding="3" 204 cellspacing="0" width="100%" bgcolor="white"> 205<tr bgcolor="#70b0f0" class="table-header"> 206 <td colspan="2" class="table-header"> 207 <table border="0" cellpadding="0" cellspacing="0" width="100%"> 208 <tr valign="top"> 209 <td align="left"><span class="table-header">Method Details</span></td> 210 <td align="right" valign="top" 211 ><span class="options">[<a href="#section-MethodDetails" 212 class="privatelink" onclick="toggle_private();" 213 >hide private</a>]</span></td> 214 </tr> 215 </table> 216 </td> 217</tr> 218</table> 219<a name="get"></a> 220<div> 221<table class="details" border="1" cellpadding="3" 222 cellspacing="0" width="100%" bgcolor="white"> 223<tr><td> 224 <table width="100%" cellpadding="0" cellspacing="0" border="0"> 225 <tr valign="top"><td> 226 <h3 class="epydoc"><span class="sig"><span class="sig-name">get</span>(<span class="sig-arg">self</span>, 227 <span class="sig-arg">url</span>)</span> 228 </h3> 229 </td><td align="right" valign="top" 230 ><span class="codelink"><a href="googleapiclient.discovery_cache.base-pysrc.html#Cache.get">source code</a></span> 231 </td> 232 </tr></table> 233 234 <pre class="literalblock"> 235Gets the content from the memcache with a given key. 236 237Args: 238 url: string, the key for the cache. 239 240Returns: 241 object, the value in the cache for the given key, or None if the key is 242 not in the cache. 243 244</pre> 245 <dl class="fields"> 246 <dt>Decorators:</dt> 247 <dd><ul class="nomargin-top"> 248 <li><code>@abc.abstractmethod</code></li> 249 </ul></dd> 250 </dl> 251</td></tr></table> 252</div> 253<a name="set"></a> 254<div> 255<table class="details" border="1" cellpadding="3" 256 cellspacing="0" width="100%" bgcolor="white"> 257<tr><td> 258 <table width="100%" cellpadding="0" cellspacing="0" border="0"> 259 <tr valign="top"><td> 260 <h3 class="epydoc"><span class="sig"><span class="sig-name">set</span>(<span class="sig-arg">self</span>, 261 <span class="sig-arg">url</span>, 262 <span class="sig-arg">content</span>)</span> 263 </h3> 264 </td><td align="right" valign="top" 265 ><span class="codelink"><a href="googleapiclient.discovery_cache.base-pysrc.html#Cache.set">source code</a></span> 266 </td> 267 </tr></table> 268 269 <pre class="literalblock"> 270Sets the given key and content in the cache. 271 272Args: 273 url: string, the key for the cache. 274 content: string, the discovery document. 275 276</pre> 277 <dl class="fields"> 278 <dt>Decorators:</dt> 279 <dd><ul class="nomargin-top"> 280 <li><code>@abc.abstractmethod</code></li> 281 </ul></dd> 282 </dl> 283</td></tr></table> 284</div> 285<br /> 286<!-- ==================== NAVIGATION BAR ==================== --> 287<table class="navbar" border="0" width="100%" cellpadding="0" 288 bgcolor="#a0c0ff" cellspacing="0"> 289 <tr valign="middle"> 290 <!-- Home link --> 291 <th> <a 292 href="googleapiclient-module.html">Home</a> </th> 293 294 <!-- Tree link --> 295 <th> <a 296 href="module-tree.html">Trees</a> </th> 297 298 <!-- Index link --> 299 <th> <a 300 href="identifier-index.html">Indices</a> </th> 301 302 <!-- Help link --> 303 <th> <a 304 href="help.html">Help</a> </th> 305 306 <th class="navbar" width="100%"></th> 307 </tr> 308</table> 309<table border="0" cellpadding="0" cellspacing="0" width="100%%"> 310 <tr> 311 <td align="left" class="footer"> 312 Generated by Epydoc 3.0.1 on Fri Jun 14 15:57:27 2019 313 </td> 314 <td align="right" class="footer"> 315 <a target="mainFrame" href="http://epydoc.sourceforge.net" 316 >http://epydoc.sourceforge.net</a> 317 </td> 318 </tr> 319</table> 320 321<script type="text/javascript"> 322 <!-- 323 // Private objects are initially displayed (because if 324 // javascript is turned off then we want them to be 325 // visible); but by default, we want to hide them. So hide 326 // them unless we have a cookie that says to show them. 327 checkCookie(); 328 // --> 329</script> 330</body> 331</html> 332