[CalendarServer-changes] [5820] CalendarServer/branches/new-store/txdav/common/icommondatastore.py
source_changes at macosforge.org
source_changes at macosforge.org
Wed Jun 30 15:38:19 PDT 2010
Revision: 5820
http://trac.macosforge.org/projects/calendarserver/changeset/5820
Author: glyph at apple.com
Date: 2010-06-30 15:38:19 -0700 (Wed, 30 Jun 2010)
Log Message:
-----------
update some verbiage, add forgotten 'commit' and 'abort' methods
Modified Paths:
--------------
CalendarServer/branches/new-store/txdav/common/icommondatastore.py
Modified: CalendarServer/branches/new-store/txdav/common/icommondatastore.py
===================================================================
--- CalendarServer/branches/new-store/txdav/common/icommondatastore.py 2010-06-30 22:37:36 UTC (rev 5819)
+++ CalendarServer/branches/new-store/txdav/common/icommondatastore.py 2010-06-30 22:38:19 UTC (rev 5820)
@@ -13,12 +13,13 @@
# See the License for the specific language governing permissions and
# limitations under the License.
##
-from zope.interface.interface import Interface
"""
Common store interfaces
"""
+from zope.interface.interface import Interface
+
__all__ = [
# Exceptions
"CommonStoreError",
@@ -113,11 +114,15 @@
"""
Data store
"""
+
def newTransaction():
"""
Create a new transaction.
+
+ @rtype: L{ICommonStoreTransaction}
"""
+
class ICommonStoreTransaction(Interface):
"""
AddressBook store transaction
@@ -125,33 +130,45 @@
def calendarHomeWithUID(uid, create=False):
"""
- Retrieve the addressbook home for the principal with the given C{uid}.
+ Retrieve the calendar home for the principal with the given C{uid}.
- If C{create} is C{True}, create the addressbook home if it doesn't already
- exist.
+ If C{create} is C{True}, create the calendar home if it doesn't
+ already exist.
- @return: an L{IAddressBookHome} or C{None} if no such addressbook
+ @return: an L{ICalendarHome} or C{None} if no such calendar
home exists.
"""
+
def addressbookHomeWithUID(uid, create=False):
"""
Retrieve the addressbook home for the principal with the given C{uid}.
- If C{create} is C{True}, create the addressbook home if it doesn't already
- exist.
+ If C{create} is C{True}, create the addressbook home if it doesn't
+ already exist.
@return: an L{IAddressBookHome} or C{None} if no such addressbook
home exists.
"""
+
def notificationsWithUID(uid):
"""
- Retrieve the notification collection for the principal with the given C{uid}.
+ Retrieve the notification collection for the principal with the given
+ C{uid}.
- @return: an L{INotificationCollection} or C{None} if no such notification
- collection exists.
+ @return: an L{INotificationCollection} or C{None} if no such
+ notification collection exists.
"""
+ def commit():
+ """
+ Persist all of the effects which have occurred in this transaction.
+ """
+
+ def abort():
+ """
+ Reverse all of the effects which have occurred in this transaction.
+ """
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20100630/84573dde/attachment-0001.html>
More information about the calendarserver-changes
mailing list