aboutsummaryrefslogtreecommitdiffstats
path: root/mako
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2012-01-19 00:51:11 -0500
committerMike Bayer <mike_mp@zzzcomputing.com>2012-01-19 00:51:11 -0500
commit3e6981c9754c6813450c55e1c511a84c9bb6766d (patch)
tree91db0e8ce0a3a111e293b5a93e3c01af9a1891b9 /mako
parent4d4e1404d08f0946c1986bfc34523099766418ad (diff)
downloadexternal_python_mako-3e6981c9754c6813450c55e1c511a84c9bb6766d.tar.gz
external_python_mako-3e6981c9754c6813450c55e1c511a84c9bb6766d.tar.bz2
external_python_mako-3e6981c9754c6813450c55e1c511a84c9bb6766d.zip
rename 'put' to 'set'
Diffstat (limited to 'mako')
-rw-r--r--mako/cache.py13
1 files changed, 10 insertions, 3 deletions
diff --git a/mako/cache.py b/mako/cache.py
index 2985e69..fe34073 100644
--- a/mako/cache.py
+++ b/mako/cache.py
@@ -81,7 +81,7 @@ class Cache(object):
creation_function,
**self._get_cache_kw(kw))
- def put(self, key, value, **kw):
+ def set(self, key, value, **kw):
"""Place a value in the cache.
:param key: the value's key.
@@ -90,7 +90,14 @@ class Cache(object):
"""
- self.impl.put(key, value, **self._get_cache_kw(kw))
+ self.impl.set(key, value, **self._get_cache_kw(kw))
+
+ put = set
+ """A synonym for :meth:`.Cache.set`.
+
+ This is here for backwards compatibility.
+
+ """
def get(self, key, **kw):
"""Retrieve a value from the cache.
@@ -178,7 +185,7 @@ class CacheImpl(object):
"""
raise NotImplementedError()
- def put(self, key, value, **kw):
+ def set(self, key, value, **kw):
"""Place a value in the cache.
:param key: the value's key.