001: // THIS SOFTWARE IS PROVIDED BY SOFTARIS PTY.LTD. AND OTHER METABOSS
002: // CONTRIBUTORS ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING,
003: // BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
004: // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SOFTARIS PTY.LTD.
005: // OR OTHER METABOSS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
006: // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
007: // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
008: // OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
009: // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
010: // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
011: // EVEN IF SOFTARIS PTY.LTD. OR OTHER METABOSS CONTRIBUTORS ARE ADVISED OF THE
012: // POSSIBILITY OF SUCH DAMAGE.
013: //
014: // Copyright 2000-2005 © Softaris Pty.Ltd. All Rights Reserved.
015: package com.metaboss.sdlctools.domains.enterprisemodel;
016:
017: import com.metaboss.enterprise.bo.BOException;
018: import com.oldboss.framework.bo.BOObject;
019:
020: public interface BOEntity extends BOObject {
021: /** Retrieves the domain which owns this entity.*/
022: public BODomain getDomain() throws BOException;
023:
024: /** Retrieves unique reference */
025: public String getRef() throws BOException;
026:
027: /** Retrieves entity name. Usually last part of the reference.
028: * name is only unique within type, within domain */
029: public String getName() throws BOException;
030:
031: /** Retrieves description */
032: public String getDescription() throws BOException;
033:
034: /** Changes description */
035: public void setDescription(String pDescription) throws BOException;
036:
037: /** Retrieves plural entity name. It is used anywhere there is a need to refer to collection of entities of this type */
038: public String getPluralName() throws BOException;
039:
040: /** Changes plural entity name. It is used anywhere there is a need to refer to collection of entities of this type */
041: public void setPluralName(String pPluralName) throws BOException;
042:
043: /** Retrieves entity stereotype */
044: public com.metaboss.sdlctools.types.enterprisemodel.EntityStereotype getStereotype()
045: throws BOException;
046:
047: /** Changes entity stereotype */
048: public void setStereotype(
049: com.metaboss.sdlctools.types.enterprisemodel.EntityStereotype pStereotype)
050: throws BOException;
051:
052: /** Returns the value of abstract flag. Abstract means that the entity instance can never be
053: * created. It can only be used for specialisation */
054: public boolean isAbstract() throws BOException;
055:
056: /** Changes the value of abstract flag. */
057: public void setIsAbstract(boolean pIsAbstract) throws BOException;
058:
059: /** Returns the value of final flag. Final means that the entity can never be extendded.
060: * It itself, however, can be a subtype of some other entity */
061: public boolean isFinal() throws BOException;
062:
063: /** Changes the value of final flag. */
064: public void setIsFinal(boolean pIsFinal) throws BOException;
065:
066: /** Returns the entity, which is a supertype to this entity or null if
067: * this entity does not have a supertype (does not extend anything) */
068: public BOEntity getSupertype() throws BOException;
069:
070: /** Changes the value of supertype
071: * @param pSupertype - entity to use as a supertype to this entity or null if
072: * caller wants to clear supertype */
073: public void setSupertype(BOEntity pSupertype) throws BOException;
074:
075: /** Returns the list of entities, for which this entity is direct supertype.
076: * This list may be empty if this entity does not have any subtypes */
077: public BOEntitySubtypeList getSubtypes() throws BOException;
078:
079: /** Retrieves list of elements comprising primary key.*/
080: public BOEntityPrimaryKeyElementList getPrimaryKeyElements()
081: throws BOException;
082:
083: /** Retrieves list of attributes within an entity */
084: public BOEntityAttributeList getAttributes() throws BOException;
085:
086: /** Retrieves list of relationships within an entity */
087: public BOEntityAssociationRoleList getAssociationRoles()
088: throws BOException;
089:
090: /** Retrieves datatype used for instance id */
091: public BODatatype getInstanceIdDatatype() throws BOException;
092:
093: /** Retrieves datatype used for version id.
094: * @return the datatype or null if entity's stereotype makes it not updateable */
095: public BODatatype getVersionIdDatatype() throws BOException;
096:
097: /** Retrieves datatype used for entity state.
098: * @return the datatype or null if entity's state machine is undefined ( Entity.getStates().size() == 0) */
099: public BODatatype getStateDatatype() throws BOException;
100:
101: /** Retrieves datatype used for ordering instruction
102: * @return the datatype or null if entity does not have anything to use in ordering */
103: public BODatatype getOrderingInstructionDatatype()
104: throws BOException;
105:
106: /** Retrieves datatype used to carry entity collection size */
107: public BODatatype getCollectionSizeDatatype() throws BOException;
108:
109: /** Retrieves datatype used for carry offset into the entity collection */
110: public BODatatype getCollectionOffsetDatatype() throws BOException;
111:
112: /** Retrieves datatype used for carry entity subset size */
113: public BODatatype getSubsetSizeDatatype() throws BOException;
114:
115: /** Retrieves datatype used for carry result of contains() operation on collection of entities */
116: public BODatatype getCollectionContainsFlagDatatype()
117: throws BOException;
118:
119: /** Retrieves datatype used for carry result of isEmpty() operation on collection of entities */
120: public BODatatype getCollectionEmptyFlagDatatype()
121: throws BOException;
122:
123: /** Retrieves list of selectors within an entity */
124: public BOEntitySelectorList getSelectors() throws BOException;
125:
126: /** Retrieves list of constraints within an entity */
127: public BOEntityConstraintList getConstraints() throws BOException;
128:
129: /** Retrieves list of states defined for the entity */
130: public BOEntityStateList getStates() throws BOException;
131: }
|