Package Modeling :: Module SnapshotsHandling :: Class SnapshotsTable
[show private | hide private]
[frames | no frames]

Type SnapshotsTable

object --+
         |
        SnapshotsTable

Known Subclasses:
SnapshotsTable, SnapshotsTable

__TBD
Method Summary
  __init__(self)
Initializer.
  __unimplemented__(self)
Raises Unimplemented...
  decrementSnapshotCountForGlobalID(self, aGlobalID)
  disableSnapshotRefCounting(self)
Disables the snapshot refcounting.
  forgetAllSnapshots(self)
Clears every snapshots currently referenced
  forgetSnapshotForGlobalID(self, aGlobalID)
Deletes all references to snapshots for 'aGlobalID'
  forgetSnapshotForGlobalIDs(self, globalIDs)
Deletes all references to snapshots registered for the GlobalIDs in 'globalIDs'
  globalIDs(self)
Returns the list of all 'GlobalIDs' referenced in the snapshots
  incrementSnapshotCountForGlobalID(self, aGlobalID)
See also: decrementSnapshotCountForGlobalID()
  isSnapshotRefCountingEnabled(self)
Tells whether snapshot refCounting is enabled.
  recordSnapshotForGlobalID(self, snapshot, aGlobalID)
  recordSnapshotForSourceGlobalID(self, gids, aGlobalID, aName)
Sets the toMany snapshot for the supplied GlobalID.
  recordSnapshots(self, snapshots)
  recordToManySnapshots(self, snapshots)
Records the snapshots for a toMany relationship.
  setTimestampToNow(self)
  snapshotCountForGlobalID(self, aGlobalID)
decrementSnapshotCountForGlobalID()
  snapshotForGlobalID(self, aGlobalID, timestamp)
  snapshotForSourceGlobalID(self, aGlobalID, aName, timestamp)
  snapshots(self)
  timestampForGlobalID(self, aGlobalID)
  timestampForSourceGlobalID(self, aGlobalID, aName)
  toManySnapshots(self)
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name
  __getattribute__(...)
x.__getattribute__('name') <==> x.name
  __hash__(x)
x.__hash__() <==> hash(x)
  __new__(T, S, ...)
T.__new__(S, ...) -> a new object with type S, a subtype of T
  __reduce__(...)
helper for pickle
  __reduce_ex__(...)
helper for pickle
  __repr__(x)
x.__repr__() <==> repr(x)
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value
  __str__(x)
x.__str__() <==> str(x)

Method Details

__init__(self)
(Constructor)

Initializer. Note that the timestamp is initialized to the value 'time.time()'.
Overrides:
__builtin__.object.__init__

__unimplemented__(self)

Raises Unimplemented...

disableSnapshotRefCounting(self)

Disables the snapshot refcounting. Note that once it has been disabled, the snapshot refcounting cannot be re-enabled.

Please refer to documentation for 'isSnapshotRefCountingEnabled()' for a full discussion what subclasses may do.

forgetAllSnapshots(self)

Clears every snapshots currently referenced

See also: forgetSnapshotForGlobalID(), forgetSnapshotForGlobalIDs()

forgetSnapshotForGlobalID(self, aGlobalID)

Deletes all references to snapshots for 'aGlobalID'

See also: forgetSnapshotForGlobalID(), forgetAllSnapshots()

forgetSnapshotForGlobalIDs(self, globalIDs)

Deletes all references to snapshots registered for the GlobalIDs in 'globalIDs'

Parameter:

'globalIDs' -- a sequence of 'GlobalID'

Raises KeyError if one GlobalID in 'globalIDs' is not registered.

See also: forgetSnapshotForGlobalID(), forgetAllSnapshots()

globalIDs(self)

Returns the list of all 'GlobalIDs' referenced in the snapshots

incrementSnapshotCountForGlobalID(self, aGlobalID)

See also: decrementSnapshotCountForGlobalID()

isSnapshotRefCountingEnabled(self)

Tells whether snapshot refCounting is enabled. Note that once it has been disabled, the snapshot refcounting cannot be re-enabled.

If you need to bind this to some external functionality or trigger of your own, simply subclass 'SnapshotsTable' and override this method, and possibly disableSnapshotRefCounting() as well. An example of such an usage can be found in class 'Database' (cf. 'Database.SnapshotsTable').

See also: disableSnapshotRefCounting(),
decrementSnapshotCountForGlobalID(), incrementSnapshotCountForGlobalID()

recordSnapshotForSourceGlobalID(self, gids, aGlobalID, aName)

Sets the toMany snapshot for the supplied GlobalID.

Note that 'aGlobalID' should already be known to the SnapshotsTable, or ValueError is raised

recordToManySnapshots(self, snapshots)

Records the snapshots for a toMany relationship.

Parameter:

snapshots -- a dictionary with GlobalIDs as keys and dictionary as
values, the latter dictionary having relationships' names as keys and a list of GlobalIDs as values.

snapshotCountForGlobalID(self, aGlobalID)

See also: incrementSnapshotCountForGlobalID,
decrementSnapshotCountForGlobalID()

Generated by Epydoc 2.1 on Sat Mar 4 13:36:24 2006 http://epydoc.sf.net