|
|||||||||
| Home >> All >> com >> gammastream >> [ validity overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
com.gammastream.validity
Class GSVModel

java.lang.Objectcom.gammastream.validity.GSVModel
- public final class GSVModel
- extends java.lang.Object
GSVModel used for the mapping validation rules to an entities' attributes.
The structure is very similar to Apple's EOModel.
| Field Summary | |
private NSMutableArray |
_entities
INSTANCE |
private EOModelGroup |
_eomodelGroup
|
private java.lang.String |
_eomodelName
|
private java.lang.String |
_eomodelPath
|
static java.lang.String |
MODEL_EXTENSION
The extension of the GSVModel file included in the '.eomodeld' wrapper. Currently the full name is: 'Validity.model' |
static java.lang.String |
MODEL_NAME
The name of the GSVModel file included in the '.eomodeld' wrapper. Currently the full name is: 'Validity.model' |
| Constructor Summary | |
GSVModel(java.lang.String path)
Creates a new GSVModel using the path to an '.eomodeld' file. Example of creating a GSVModel for the Movies example which ships with WebObjects.
EOModel eoModel = EOModelGroup.defaultGroup().modelNamed("Moview");
|
|
| Method Summary | |
void |
addEntity(GSVEntity newEntity)
Adds a GSVEntity object to this GSVModel. |
java.lang.Class |
classForCoder()
WOXMLCoding Impl |
void |
encodeWithWOXMLCoder(WOXMLCoder coder)
WOXMLCoding Impl |
NSArray |
entities()
Returns the NSArray of GSVEntity Objects. |
GSVEntity |
entityForObject(java.lang.Object object)
Returns the GSVEntity object associated with the provided EOEnterpriseObject. |
GSVEntity |
entityNamed(java.lang.String name)
Returns the GSVEntity object for the provided entity name. |
NSArray |
entityNames()
Returns an NSArray containing the GSVEntity names. |
EOModelGroup |
eomodelGroup()
Returns the EOModelGroup that is being used to query information from the EOModel. |
java.lang.String |
eomodelName()
Returns the EOModel Name for the associated GSVModel. |
java.lang.String |
eomodelPath()
Returns the path of the '.eomodeld' file. |
void |
init(EOModel eomodel,
EOEnterpriseObject eo)
|
void |
removeEntity(GSVEntity oldEntity)
Removes a GSVEntity object from this GSVModel. |
boolean |
saveModel()
Saves the GSVModel to inside the '.eomodeld' file wrapper. |
void |
savePath(java.lang.String s)
Internal method for saving paths |
void |
setEomodelPath(java.lang.String path)
Set the path of the EOModel file. |
boolean |
validateEOModelForPath(java.lang.String path)
Determines that there is indeed a file located at the given path. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
MODEL_NAME
public static final java.lang.String MODEL_NAME
- The name of the GSVModel file included in the '.eomodeld' wrapper.
Currently the full name is: 'Validity.model'- See Also:
- Constant Field Values
MODEL_EXTENSION
public static final java.lang.String MODEL_EXTENSION
- The extension of the GSVModel file included in the '.eomodeld' wrapper.
Currently the full name is: 'Validity.model'- See Also:
- Constant Field Values
_entities
private NSMutableArray _entities
- INSTANCE
_eomodelPath
private java.lang.String _eomodelPath
_eomodelName
private java.lang.String _eomodelName
_eomodelGroup
private EOModelGroup _eomodelGroup
| Constructor Detail |
GSVModel
public GSVModel(java.lang.String path) throws java.lang.IllegalArgumentException
- Creates a new GSVModel using the path to an '.eomodeld' file.
Example of creating a GSVModel for the Movies example which ships with WebObjects.
EOModel eoModel = EOModelGroup.defaultGroup().modelNamed("Moview");
GSVModel model = new GSVModel(eoModel.path());
| Method Detail |
validateEOModelForPath
public boolean validateEOModelForPath(java.lang.String path)
- Determines that there is indeed a file located at the given path.
saveModel
public boolean saveModel()
- Saves the GSVModel to inside the '.eomodeld' file wrapper.
eomodelGroup
public EOModelGroup eomodelGroup()
- Returns the EOModelGroup that is being used to query information from the EOModel.
eomodelName
public java.lang.String eomodelName()
- Returns the EOModel Name for the associated GSVModel.
eomodelPath
public java.lang.String eomodelPath()
- Returns the path of the '.eomodeld' file.
setEomodelPath
public void setEomodelPath(java.lang.String path)
- Set the path of the EOModel file.
entities
public NSArray entities()
- Returns the NSArray of GSVEntity Objects.
addEntity
public void addEntity(GSVEntity newEntity) throws java.lang.IllegalArgumentException
- Adds a GSVEntity object to this GSVModel. The GSVEntity must not already exsit.
If it does, IllegalArgumentException is thrown.
removeEntity
public void removeEntity(GSVEntity oldEntity)
- Removes a GSVEntity object from this GSVModel.
entityForObject
public GSVEntity entityForObject(java.lang.Object object)
- Returns the GSVEntity object associated with the provided EOEnterpriseObject.
entityNamed
public GSVEntity entityNamed(java.lang.String name)
- Returns the GSVEntity object for the provided entity name.
entityNames
public NSArray entityNames()
- Returns an NSArray containing the GSVEntity names.
savePath
public void savePath(java.lang.String s)
- Internal method for saving paths
encodeWithWOXMLCoder
public void encodeWithWOXMLCoder(WOXMLCoder coder)
- WOXMLCoding Impl
classForCoder
public java.lang.Class classForCoder()
- WOXMLCoding Impl
init
public void init(EOModel eomodel,
EOEnterpriseObject eo)
|
|||||||||
| Home >> All >> com >> gammastream >> [ validity overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
com.gammastream.validity.GSVModel