net.wotonomy.access
Class EOEntity
java.lang.Object
net.wotonomy.access.EOEntity
- All Implemented Interfaces:
- EOPropertyListEncoding
public class EOEntity
- extends java.lang.Object
- implements EOPropertyListEncoding
An EOEntity is a mapping between a Java class and a database table or view.
It indicates which attributes should be fetched from the table/view, what
attributes are part of the primary key, what class the entity should map to.
- Version:
- $Revision: 894 $
- Author:
- ezamudio@nasoft.com, $Author: cgruber $
Constructor Summary |
EOEntity()
|
EOEntity(net.wotonomy.foundation.NSDictionary dict,
java.lang.Object obj)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_attributes
protected net.wotonomy.foundation.NSMutableDictionary _attributes
_relations
protected net.wotonomy.foundation.NSMutableDictionary _relations
_pkAttributes
protected net.wotonomy.foundation.NSArray _pkAttributes
_pkAttributeNames
protected net.wotonomy.foundation.NSArray _pkAttributeNames
_fetchSpecs
protected net.wotonomy.foundation.NSMutableDictionary _fetchSpecs
_lockingAttributes
protected net.wotonomy.foundation.NSMutableArray _lockingAttributes
_className
protected java.lang.String _className
_name
protected java.lang.String _name
_externalName
protected java.lang.String _externalName
_isAbstract
protected boolean _isAbstract
_isReadOnly
protected boolean _isReadOnly
_model
protected EOModel _model
_userInfo
protected net.wotonomy.foundation.NSDictionary _userInfo
_internalInfo
protected net.wotonomy.foundation.NSDictionary _internalInfo
EOEntity
public EOEntity()
EOEntity
public EOEntity(net.wotonomy.foundation.NSDictionary dict,
java.lang.Object obj)
addAttribute
public void addAttribute(EOAttribute atr)
removeAttribute
public void removeAttribute(EOAttribute atr)
addFetchSpecification
public void addFetchSpecification(EOFetchSpecification fspec,
java.lang.String name)
removeFetchSpecificationNamed
public void removeFetchSpecificationNamed(java.lang.String name)
fetchSpecificationNamed
public EOFetchSpecification fetchSpecificationNamed(java.lang.String name)
fetchSpecificationNames
public net.wotonomy.foundation.NSArray fetchSpecificationNames()
attributes
public net.wotonomy.foundation.NSArray attributes()
attributeNamed
public EOAttribute attributeNamed(java.lang.String name)
flattenedAttributes
public net.wotonomy.foundation.NSArray flattenedAttributes()
setClassName
public void setClassName(java.lang.String name)
className
public java.lang.String className()
setName
public void setName(java.lang.String name)
name
public java.lang.String name()
setExternalName
public void setExternalName(java.lang.String name)
externalName
public java.lang.String externalName()
addRelationship
public void addRelationship(EORelationship rel)
removeRelationship
public void removeRelationship(EORelationship rel)
relationships
public net.wotonomy.foundation.NSArray relationships()
- Returns the relationships from this entity to other entities.
- Returns:
- An array of the relationships of this entity.
relationshipNamed
public EORelationship relationshipNamed(java.lang.String name)
model
public EOModel model()
setPrimaryKeyAtributes
public void setPrimaryKeyAtributes(net.wotonomy.foundation.NSArray pk)
primaryKeyAttributes
public net.wotonomy.foundation.NSArray primaryKeyAttributes()
primaryKeyAttributeNames
public net.wotonomy.foundation.NSArray primaryKeyAttributeNames()
hasSimplePrimaryKey
public boolean hasSimplePrimaryKey()
isValidPrimaryKeyAttribute
public boolean isValidPrimaryKeyAttribute(EOAttribute attr)
setAttributesUsedForLocking
public void setAttributesUsedForLocking(net.wotonomy.foundation.NSArray value)
attributesUsedForLocking
public net.wotonomy.foundation.NSArray attributesUsedForLocking()
setClassProperties
public void setClassProperties(net.wotonomy.foundation.NSArray value)
classProperties
public net.wotonomy.foundation.NSArray classProperties()
classPropertyNames
public net.wotonomy.foundation.NSArray classPropertyNames()
classPropertyAttributeNames
public net.wotonomy.foundation.NSArray classPropertyAttributeNames()
classPropertyToManyRelationshipNames
public net.wotonomy.foundation.NSArray classPropertyToManyRelationshipNames()
classPropertyToOneRelationshipNames
public net.wotonomy.foundation.NSArray classPropertyToOneRelationshipNames()
setIsAbstractEntity
public void setIsAbstractEntity(boolean flag)
isAbstractEntity
public boolean isAbstractEntity()
setReadOnly
public void setReadOnly(boolean flag)
isReadOnly
public boolean isReadOnly()
setStoredProcedure
public void setStoredProcedure(EOStoredProcedure proc,
java.lang.String operation)
storedProcedureForOperation
public EOStoredProcedure storedProcedureForOperation(java.lang.String operation)
subEntities
public net.wotonomy.foundation.NSArray subEntities()
attributesToFetch
public net.wotonomy.foundation.NSArray attributesToFetch()
externalModelsReferenced
public net.wotonomy.foundation.NSArray externalModelsReferenced()
classDescriptionForInstances
public EOClassDescription classDescriptionForInstances()
globalIDForRow
public EOGlobalID globalIDForRow(java.util.Map row)
- Creates a global ID for a row. The row must have values
for all the primary key attributes.
- Parameters:
row
- A raw row for this entity.
- Returns:
- A key global ID to identify this row.
primaryKeyForGlobalID
public net.wotonomy.foundation.NSDictionary primaryKeyForGlobalID(EOGlobalID gid)
- Returns a dictionary with the primary key values contained in
the global id.
- Parameters:
gid
- A Key global ID.
- Returns:
- A dictionary with the primary key values for gid.
qualifierForPrimaryKey
public EOQualifier qualifierForPrimaryKey(java.util.Map pkey)
setUserInfo
public void setUserInfo(net.wotonomy.foundation.NSDictionary value)
userInfo
public net.wotonomy.foundation.NSDictionary userInfo()
awakeWithPropertyList
public void awakeWithPropertyList(net.wotonomy.foundation.NSDictionary plist)
- Specified by:
awakeWithPropertyList
in interface EOPropertyListEncoding
encodeIntoPropertyList
public void encodeIntoPropertyList(net.wotonomy.foundation.NSMutableDictionary dict)
- Specified by:
encodeIntoPropertyList
in interface EOPropertyListEncoding
_attributeForPath
public EOAttribute _attributeForPath(java.lang.String path)
Copyright © 2006 null. All Rights Reserved.