|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Represents the common interfaces of an element for a UDM database. A UDM element is a container that references its data through fields. A UDM element is created from a particular UDM list and is associated with that list for the life of the element. The element takes on the field characteristics of the list that is it created or retrieved from; that is, the list dictates what fields that this element contains.
UDM elements can have its data imported and exported using standard byte based formats. Each implementing class defines what formats can be imported and exported for that element.
Field Summary | |
static int |
DATE
DATE Data type ID indicating data is a Date. |
static int |
INT
INT Data type ID indicating data is an Integer. |
static int |
STRING
STRING Data type ID indicating data is a String. |
static int |
TYPED_STRING
TYPED_STRING Data type ID indicating data is a String with a further qualifying integer type. |
Method Summary | |
void |
commit()
This method commits that data to the underlying data storage for the list. |
long |
getDate(int fieldID)
Get a Date field from the Element. |
int |
getFieldDataType(int fieldID)
Returns an int representing the data type of the data associated with the given field ID. |
java.lang.String |
getFieldLabel(int fieldID)
Returns a String label associated with the given field ID. |
int[] |
getFields()
Returns all field IDs in the element that have data stored for them. |
int |
getInt(int fieldID)
Get an integer field from the Element. |
java.lang.String |
getString(int fieldID)
Get a String field from the Element. |
java.lang.String |
getTypedString(int fieldID,
int typeID)
Get a String field with a specific type in the element. |
UDMList |
getUDMList()
Returns the UDMList associated with this element. |
boolean |
isModified()
This method returns a boolean indicating whether any of this element's fields have been modified since the element was retrieved or last committed. |
void |
setDate(int fieldID,
long value)
Set a Date field in the Element. |
void |
setInt(int fieldID,
int value)
Set an integer field in the Element. |
void |
setString(int fieldID,
java.lang.String value)
Set a String field in the Element. |
void |
setTypedString(int fieldID,
int typeID,
java.lang.String value)
Set a String field with a specific type ID in the element. |
Field Detail |
public static final int DATE
public static final int INT
public static final int STRING
public static final int TYPED_STRING
Method Detail |
public UDMList getUDMList()
public void commit() throws UDMException
UDMException
- if the commit encounters an error and cannot complete.
java.lang.SecurityException
- if the application has not been granted write access to the UDM list.public boolean isModified()
public int getFieldDataType(int fieldID) throws UDMException
fieldID
- The ID of the field for which the data type is being queried.
java.lang.IllegalArgumentException
- if the field ID is not valid for the derived class.
UDMException
- if the field ID is not supported in the implementing instance of the class.public java.lang.String getFieldLabel(int fieldID) throws UDMException
java.lang.IllegalArgumentException
- if the field ID is not valid for the implementing class.
UDMException
- if the field ID is not supported in the implementing instance of the class.public int[] getFields()
public long getDate(int fieldID) throws UDMException
fieldID
- The field ID to get.
java.lang.IllegalArgumentException
- if the field ID is not valid for the derived class.
UDMException
- if the field ID is not supported in the implementing instance of the class.public void setDate(int fieldID, long value) throws UDMException
fieldID
- The field ID to set.value
- The value to set the field to. Setting a field to 0 has the effect of clearing it.
java.lang.IllegalArgumentException
- if the field ID is not valid for the derived class or if the
value is outside the range of supported by the native database.
UDMException
- if the field ID is not supported in the implementing instance of the class.public int getInt(int fieldID) throws UDMException
fieldID
- The field ID to get.
java.lang.IllegalArgumentException
- if the field ID is not valid for the derived class.
UDMException
- if the field ID is not supported in the implementing instance of the class.public void setInt(int fieldID, int value) throws UDMException
fieldID
- The field ID to set.value
- The value to set the field to.
java.lang.IllegalArgumentException
- if the field ID is not valid for the derived class or if the
value is outside the range of supported by the native database.
UDMException
- if the field ID is not supported in the implementing instance of the class.public java.lang.String getString(int fieldID) throws UDMException
fieldID
- The field ID to get.
java.lang.IllegalArgumentException
- if the field ID is not valid for the derived class.
UDMException
- if the field ID is not supported in the implementing instance of the class.public void setString(int fieldID, java.lang.String value) throws UDMException
fieldID
- The field ID to set.value
- The value to set the field to. Setting a field to null has the effect of clearing it.
java.lang.IllegalArgumentException
- if the field ID is not valid for the derived class or if the
value is outside the range of supported by the native database.
UDMException
- if the field ID is not supported in the implementing instance of the class.public java.lang.String getTypedString(int fieldID, int typeID) throws UDMException
fieldID
- The field ID to get.typeID
- The specific type for the field to retrieve.
java.lang.IllegalArgumentException
- if the field ID or type ID is not valid for the derived class.
UDMException
- if the field ID is not supported in the implementing instance of the class.public void setTypedString(int fieldID, int typeID, java.lang.String value) throws UDMException
fieldID
- The field ID to set.typeID
- The type ID for the field.value
- The value to set the field to. Setting a field to null has the effect of clearing it.
java.lang.IllegalArgumentException
- if the field ID or type ID is not valid for the derived class or if the
value is outside the range of supported by the native database.
UDMException
- if the field ID is not supported in the implementing instance of the class.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |