| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface DOType
The DOType interface defines methods for describing the
 type of a DataObject.
 A DOType instance contains a name (String) and collection of attributes
 (DOAttribute).  A DOType can inherit from a parent DOType instance, in
 which case it contains all the attributes of its parent DOType.  Duplicate
 attribute names are not permitted.
 Note that when the type of an attribute is another DataObject (a "nested"
 DataObject) then the attribute is implicitly an Array of
 those DataObjects, even if only one will be used.
 A DOType instance can also represent a "primitive" data type.
 The supported primitive types are: String, 32 bit and 64 bit Integer,
 Float, Double and "Opaque" (bytestream).
 Future types will include Date, Time, DateTime and
 "Infinite" precision integers and floating point numbers.
 Primitive types can have no attributes.
| Method Summary | |
|---|---|
|  boolean | equals(DOType other)Returns true if otherand the receiver are structurally equal. | 
|  boolean | equals(DOType other,
       java.util.Hashtable checkedTypes)Returns true if otherand the receiver are structurally equal. | 
|  DOAttribute | getAttribute(java.lang.String name)Returns the attribute named name, or null if it is not defined. | 
|  int | getAttributeCount()Returns the number of attributes defined in the receiver. | 
|  java.lang.String[] | getAttributeNames()Returns array of names of all the attributes defined in this type. | 
|  DOAttribute[] | getAttributes()Returns all the attributes defined in the receiver. | 
|  java.lang.String | getName()Returns the type name. | 
|  long | getVersion()Returns the version of the type. | 
|  boolean | isCollection()Returns true if this DOType acts as a collection | 
|  boolean | isEnumeration()Returns true if this DOType acts as an enumeration | 
|  boolean | isPrimitive()Returns true if the receiver is a primitive type. | 
| Method Detail | 
|---|
java.lang.String getName()
boolean isPrimitive()
boolean isCollection()
boolean isEnumeration()
long getVersion()
boolean equals(DOType other)
other and the receiver are structurally equal.
 This will usually call equals(other, new Hashtable())<> to
 implement a full recursive comparison.
- 
- Parameters:
- other- the DOType to be compared
- Returns:
- true if other and receiver are Structurally equal.
 
boolean equals(DOType other,
               java.util.Hashtable checkedTypes)
other and the receiver are structurally equal.
 This method should does a recursive comparison of this
 and other.  It should not compare the types
 of attributes whose type names match one of the keys in
 checkedTypes.  In addition, it should add its own type
 name as a key to checkedTypes - before it checks any
 attributes - to signify that it does not need to be checked again.
 This is because we allow recursive
 nested types; e.g. type X containing an attribute of type X, or
 X containing Y containing X, and we need to avoid endless loops in
 type comparison operations.
 Note this method is protected so it cannot be misused outside
 the dataobjects package.
other - the DOType to be comparedcheckedTypes - a table of names of types that have already been
 checked.
int getAttributeCount()
DOAttribute[] getAttributes()
DOAttributejava.lang.String[] getAttributeNames()
DOAttribute getAttribute(java.lang.String name)
                         throws InvalidParameterException
name - attribute name.
InvalidParameterException - If name is not an attribute
 name in the type.DOAttribute| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||