--- a/src/ztfy/utils/interfaces.py Mon Sep 24 08:49:04 2012 +0200
+++ b/src/ztfy/utils/interfaces.py Mon Sep 24 08:54:09 2012 +0200
@@ -179,11 +179,11 @@
description=_("Realm name on ZEO server"),
required=False)
- def getJSONSettings(self):
+ def getSettings(self):
"""Get ZEO connection setting as a JSON dict"""
- def update(self, values):
- """Update connection properties from given dict values"""
+ def update(self, settings):
+ """Update internal fields with given settings dict"""
def getConnection(self, wait=False):
"""Open ZEO connection with given settings"""
--- a/src/ztfy/utils/zodb.py Mon Sep 24 08:49:04 2012 +0200
+++ b/src/ztfy/utils/zodb.py Mon Sep 24 08:54:09 2012 +0200
@@ -52,15 +52,15 @@
password = FieldProperty(IZEOConnection['password'])
server_realm = FieldProperty(IZEOConnection['server_realm'])
- def getJSONSettings(self):
+ def getSettings(self):
result = {}
for name in getFieldNames(IZEOConnection):
result[name] = getattr(self, name)
return result
- def update(self, values):
+ def update(self, settings):
names = getFieldNames(IZEOConnection)
- for k, v in values.items():
+ for k, v in settings.items():
if k in names:
setattr(self, k, unicode(v) if isinstance(v, str) else v)