|
WebObjects 5.2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.webobjects.eocontrol.EOClassDescription | +--com.webobjects.eodistribution.client.EODistributedClassDescription
EODistributedClassDescription is the Java Client equivalent to EOClassDescription. It contains object-level information about this class of enterprise objects, mainly the list of attributes and relationships.
Inner classes inherited from class com.webobjects.eocontrol.EOClassDescription |
EOClassDescription.ClassDelegate |
Inner classes inherited from class com.webobjects.foundation.NSCoding |
NSCoding.Support |
Fields inherited from class com.webobjects.eocontrol.EOClassDescription |
ClassDescriptionNeededForClassNotification, ClassDescriptionNeededForEntityNameNotification, DeleteRuleCascade, DeleteRuleDeny, DeleteRuleNoAction, DeleteRuleNullify |
Constructor Summary | |
EODistributedClassDescription(Class theClass)
The constructor for EODistributedClassDescription, usually called internally. |
|
EODistributedClassDescription(String name,
Class theClass)
A constructor for EODistributedClassDescription, usually called internally. |
Method Summary | |
NSArray |
attributeKeys()
Returns an array of keys for attributes of the receiver's enterprise objects. |
EOAttribute |
attributeNamed(String key)
Returns the EOAttribute of the given name (key). |
void |
awakeObjectFromFetch(EOEnterpriseObject eo,
EOEditingContext ec)
Called every time an object is fetched in an editing context. |
void |
awakeObjectFromInsertion(EOEnterpriseObject target,
EOEditingContext ec)
Automatically creates related objects for relationships which propagate primary keys. |
EOClassDescription |
classDescriptionForDestinationKey(String detailKey)
Returns the class description for objects at the destination of the given relationship. |
Class |
classForCoder()
Returns the class that will be used by NSCoders to later re-create this object. |
EOEnterpriseObject |
createInstanceWithEditingContext(EOEditingContext ec,
EOGlobalID gid)
Creates an enterprise object of the appropriate class. |
static Object |
decodeObject(NSCoder coder)
Decodes (re-creates) an EODistributedClassDescription from the stored definitions in the coder . |
Format |
defaultFormatterForKey(String key)
Returns a default formatter for the attribute key ,
based on the value class of the attribute. |
int |
deleteRuleForRelationshipKey(String relationshipKey)
Returns the delete rule as defined in EOClassDescription, for the specified relationship. |
void |
encodeWithCoder(NSCoder coder)
Encodes (stores) the defining values of this EODistributedClassDescription object into the given coder . |
String |
entityName()
Returns the name for this class description. |
String |
inverseForRelationshipKey(String relationshipKey)
Returns the name of the relationship pointing back at the receiver from the destination of the given relationship. |
boolean |
ownsDestinationObjectsForRelationshipKey(String relationshipKey)
Returns whether or not the objects in the destination of the given relationship should be deleted if they are removed from the relationship (and not added to the corresponding relationship of another object). |
EORelationship |
relationshipNamed(String key)
Returns the EORelationship of the given name (key). |
boolean |
shouldRecordCodingReferences()
Returns whether coding references should be recorded. |
NSArray |
toManyRelationshipKeys()
Returns an array of keys for to-many relationship properties of the receiver's enterprise objects. |
NSArray |
toOneRelationshipKeys()
Returns an array of keys for to-one relationship properties of the receiver's enterprise objects. |
Object |
validateValueForKey(Object value,
String key)
Validate the value passed and return a possibly coerced value. |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public EODistributedClassDescription(Class theClass)
theClass
- the Class of the enterprise objects for this entitypublic EODistributedClassDescription(String name, Class theClass)
name
- this parameter is ignoredtheClass
- the Class of the enterprise objects for this entityMethod Detail |
public NSArray attributeKeys()
attributeKeys
in class EOClassDescription
public EOAttribute attributeNamed(String key)
key
- the name of the attributepublic void awakeObjectFromFetch(EOEnterpriseObject eo, EOEditingContext ec)
awakeObjectFromFetch
in class EOClassDescription
eo
- the object to be 'awakened'ec
- the editing context in which the object will be awakenedpublic void awakeObjectFromInsertion(EOEnterpriseObject target, EOEditingContext ec)
awakeObjectFromInsertion
in class EOClassDescription
target
- the object to be 'awakened'ec
- the editing context in which the object will be awakenedpublic EOClassDescription classDescriptionForDestinationKey(String detailKey)
classDescriptionForDestinationKey
in class EOClassDescription
detailKey
- the name of the relationship for whose destination entity one wants to find the class descriptiondetailKey
public Class classForCoder()
classForCoder
in interface NSCoding
public EOEnterpriseObject createInstanceWithEditingContext(EOEditingContext ec, EOGlobalID gid)
createInstanceWithEditingContext
in class EOClassDescription
ec
- the editing context the new object will live ingid
- the gid for the new objectpublic static Object decodeObject(NSCoder coder)
coder
.coder
- the NSCoder supplying the definitionspublic Format defaultFormatterForKey(String key)
key
,
based on the value class of the attribute.defaultFormatterForKey
in class EOClassDescription
key
- the editing context in which the object will be awakenednull
public int deleteRuleForRelationshipKey(String relationshipKey)
deleteRuleForRelationshipKey
in class EOClassDescription
relationshipKey
- The name of the relationshipnull
EOClassDescription
public void encodeWithCoder(NSCoder coder)
coder
.encodeWithCoder
in interface NSCoding
coder
- the NSCoder used to store the defining valuespublic String entityName()
entityName
in class EOClassDescription
public String inverseForRelationshipKey(String relationshipKey)
employee.inverseForRelationshipKey(eo, "department")
might return "employees"
(such that this employee would appear in employee->department->employees). Might return null
.inverseForRelationshipKey
in class EOClassDescription
the
- name of the original relationshipnull
public boolean ownsDestinationObjectsForRelationshipKey(String relationshipKey)
ownsDestinationObjectsForRelationshipKey
in class EOClassDescription
relationshipKey
- the relationship's nametrue
if the specified relationship owns the destination objects; false
otherwisepublic EORelationship relationshipNamed(String key)
key
- the name of the relationshippublic boolean shouldRecordCodingReferences()
true
.
This method is part of an internally used interface.true
if coding references should be recorded (For this class, always returns true
).public NSArray toManyRelationshipKeys()
toManyRelationshipKeys
in class EOClassDescription
public NSArray toOneRelationshipKeys()
toOneRelationshipKeys
in class EOClassDescription
public Object validateValueForKey(Object value, String key) throws NSValidation.ValidationException
validateValueForKey
in class EOClassDescription
value
- the value to be checked for being validkey
- the name of the attribute (or relationship) to which the value might leter be assigned
|
Last updated Fri Feb 21 13:15:00 PST 2003. | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |