OpenQuizz
Une application de gestion des contenus pédagogiques
|
Public Member Functions | |
def | will_copy (self) |
def | transform_incoming (self, son, collection) |
def | transform_outgoing (self, son, collection) |
A base son manipulator. This manipulator just saves and restores objects without changing them.
def transform_incoming | ( | self, | |
son, | |||
collection | |||
) |
Manipulate an incoming SON object. :Parameters: - `son`: the SON object to be inserted into the database - `collection`: the collection the object is being inserted into
Reimplemented in AutoReference, NamespaceInjector, ObjectIdShuffler, and ObjectIdInjector.
def transform_outgoing | ( | self, | |
son, | |||
collection | |||
) |
Manipulate an outgoing SON object. :Parameters: - `son`: the SON object being retrieved from the database - `collection`: the collection this object was stored in
Reimplemented in AutoReference.
def will_copy | ( | self | ) |
Will this SON manipulator make a copy of the incoming document? Derived classes that do need to make a copy should override this method, returning True instead of False. All non-copying manipulators will be applied first (so that the user's document will be updated appropriately), followed by copying manipulators.
Reimplemented in AutoReference, and ObjectIdShuffler.