--- a/ztfy/utils/request.py Tue Sep 29 22:35:14 2009 +0200
+++ b/ztfy/utils/request.py Sat Oct 10 00:19:15 2009 +0200
@@ -45,6 +45,8 @@
request = getRequest()
return request.principal
+getPrincipal = getRequestPrincipal
+
def getRequestAnnotations(request=None):
"""Get annotations from given request"""
@@ -52,6 +54,8 @@
request = getRequest()
return IAnnotations(request)
+getAnnotations = getRequestAnnotations
+
def getRequestData(key, request=None, default=None):
"""Get request data, stored into request annotations"""
@@ -61,8 +65,12 @@
except:
return default
+getData = getRequestData
+
def setRequestData(key, data, request=None):
"""Define request data, stored into request annotations"""
annotations = getRequestAnnotations(request)
annotations[key] = data
+
+setData = setRequestData