Home | Trees | Index | Help |
|
---|
Package Modeling :: Package interfaces :: Module RelationshipManipulation :: Class RelationshipManipulationInterface |
|
Base
--+ |KeyValueCodingInterface
--+ | RelationshipManipulationInterface
DatabaseObjectInterface
The RelationshipManipulation interface defines all methods needed to manipulates relationships defined in a Model (see Model, Entity, Relationship and ClassDescription).
Its behaviour is similar to KeyValueCoding except that it does only handle keys mapped to relationships in the receivers' class descriptions.
Implemented by: mix-in class RelationshipManipulation
Method Summary | |
---|---|
Adds object to the corresponding relationship, and adds 'self' to 'anObject' 's inverse relationship, if it exists. | |
Depending on the relationship, the method performs the foowing steps: | |
Returns the class description for the receiver. | |
Simply returns if anObject is None ('n issues a log at warning level) | |
Depending on the relationship, the method performs the following steps: | |
Inherited from KeyValueCodingInterface | |
Raises AttributeError. | |
Raises AttributeError. | |
Raises AttributeError. | |
DEPERECATED -- An alias for 'takeStoredValueForKey()' | |
DEPERECATED -- An alias for 'takeValueForKey()' | |
DEPERECATED -- An alias for 'takeValueForKey()' | |
order: _getKey(), _key(), key, _key, getKey(), key() Might be overriden to perform additional transformations before returning the object | |
order: _setKey(), _key, key, setKey() Might be overriden to perform additional transformations before returning the object | |
Invokes takeStoredValueForKey() for each key, value in the dictionary. | |
order: setKey(), _setKey(), key, _key Might be overriden to perform additional transformations before returning the object | |
| |
Invokes takeValueForKey() for each key, value in the dictionary. | |
order: getKey(), key(), _getKey(), _key(), key, _key Might be overriden to perform additional transformations before returning the object | |
Returns the list of values assigned to attributes specified in keys. |
Method Details |
---|
addObjectToBothSidesOfRelationshipWithKey(self, anObject, aKey)Adds object to the corresponding relationship, and adds 'self' to 'anObject' 's inverse relationship, if it exists. Raises TypeError if 'aKey' cannot be found among the relationships of the receivers' class description. |
addObjectToPropertyWithKey(self, anObject, aKey)Depending on the relationship, the method performs the foowing steps:
|
classDescription(self)Returns the class description for the receiver. This is the only method for which RelationshipManipulation does not define any default implementation ; it is usually implemented by objects implementing the DatabaseObject interface, such as CustomObject subclasses |
removeObjectFromBothSidesOfRelationshipWithKey(self, anObject, aKey)Simply returns if anObject is None ('n issues a log at warning level) |
removeObjectFromPropertyWithKey(self, anObject, aKey)Depending on the relationship, the method performs the following steps:
Method raise 'ValueError' if relationship 'aKey' cannot be found, or if 'anObject' is not set for that key. |
Home | Trees | Index | Help |
|
---|
Generated by Epydoc 2.1 on Sat Mar 4 13:36:25 2006 | http://epydoc.sf.net |