# -*- coding: iso-8859-1 -*-
#-----------------------------------------------------------------------------
# Modeling Framework: an Object-Relational Bridge for python
#
# Copyright (c) 2001-2004 Sbastien Bigaret <sbigaret@users.sourceforge.net>
# All rights reserved.
#
# This file is part of the Modeling Framework.
#
# This code is distributed under a "3-clause BSD"-style license;
# see the LICENSE file for details.
#-----------------------------------------------------------------------------
"""
ObjectStore
See interfaces.ObjectStore for details
CVS information: $Id: ObjectStore.py 932 2004-07-20 06:21:57Z sbigaret $
"""
__version__='$Revision: 932 $'[11:-2]
from interfaces.ObjectStoreInterface import ObjectStoreInterface
## Modules constants
DeletedKey = 'DELETED'
InsertedKey = 'INSERTED'
InvalidatedKey = 'INVALIDATED'
UpdatedKey = 'UPDATED'
## Notification strings
InvalidatedAllObjectsInStoreNotification='InvalidatedAllObjectsInStoreNotification'
ObjectsChangedInStoreNotification='ObjectsChangedInStoreNotification'
## ObjectStore
class ObjectStore:
__implements__ = (ObjectStoreInterface,)
def arrayFaultWithSourceGlobalID(self, aGlobalID, aRelationshipName,
anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def editingContextDidForgetObjectWithGlobalID(self, aContext, aGlobalID):
"See interfaces.ObjectStore for details"
__abstract__()
def faultForGlobalID(self, aGlobalID, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def faultForRawRow(self, aRow, anEntityName, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def handlesObject(self, anObject):
"""
An alias for ownsObject(). Subclasses should not need to override it, they
rather implement ownsObject()
"""
return self.ownsObject(anObject)
def initializeObject(self, anObject, aGlobalID, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def invalidateAllObjects(self):
"See interfaces.ObjectStore for details"
__abstract__()
def invalidateObjectsWithGlobalIDs(self, globalIDs):
"See interfaces.ObjectStore for details"
__abstract__()
def isObjectLockedWithGlobalID(self, aGlobalID, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def lockObjectWithGlobalID(self, aGlobalID, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def objectsForSourceGlobalID(self, aGlobalID, aRelationshipName, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def objectsCountWithFetchSpecification(self, aFetchSpecification, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def objectsWithFetchSpecification(self, aFetchSpecification, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def ownsObject(self, anObject):
"""
"""
__abstract__()
def refaultObject(self, anObject, aGlobalID, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def rootObjectStore(self):
"See interfaces.ObjectStore for details"
__abstract__()
def savesChangesInEditingContext(self, anEditingContext):
"See interfaces.ObjectStore for details"
__abstract__()
def __abstract__():
raise 'AbstractMethod', 'Left intentionally unimplemented in this class'
|