Class PkType
java.lang.Object
org.exolab.castor.xml.schema.annotations.jdo.PkType
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
PrimaryKey
Class PkType.
- Version:
- $Revision$ $Date$
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidMethod enumerateKey.String[]getKey()Method getKey.Returns the contents of the collection in an Array.getKey(int index) Method getKey.intMethod getKeyCount.booleanisValid()Method isValid.Method iterateKey.voidvoidmarshal(ContentHandler handler) voidbooleanMethod removeKey.removeKeyAt(int index) Method removeKeyAt.voidvoidstatic PkTypeMethod unmarshal.voidvalidate()
-
Constructor Details
-
PkType
public PkType()
-
-
Method Details
-
addKey
- Parameters:
vKey-- Throws:
IndexOutOfBoundsException- if the index given is outside the bounds of the collection
-
addKey
- Parameters:
index-vKey-- Throws:
IndexOutOfBoundsException- if the index given is outside the bounds of the collection
-
enumerateKey
Method enumerateKey.- Returns:
- an Enumeration over all possible elements of this collection
-
getKey
Method getKey.- Parameters:
index-- Returns:
- the value of the java.lang.String at the given index
- Throws:
IndexOutOfBoundsException- if the index given is outside the bounds of the collection
-
getKey
Method getKey.Returns the contents of the collection in an Array.Note: Just in case the collection contents are changing in another thread, we pass a 0-length Array of the correct type into the API call. This way we know that the Array returned is of exactly the correct length.
- Returns:
- this collection as an Array
-
getKeyCount
public int getKeyCount()Method getKeyCount.- Returns:
- the size of this collection
-
isValid
public boolean isValid()Method isValid.- Returns:
- true if this object is valid according to the schema
-
iterateKey
Method iterateKey.- Returns:
- an Iterator over all possible elements in this collection
-
marshal
- Parameters:
out-- Throws:
MarshalException- if object is null or if any SAXException is thrown during marshalingValidationException- if this object is an invalid instance according to the schema
-
marshal
public void marshal(ContentHandler handler) throws IOException, MarshalException, ValidationException - Parameters:
handler-- Throws:
IOException- if an IOException occurs during marshalingValidationException- if this object is an invalid instance according to the schemaMarshalException- if object is null or if any SAXException is thrown during marshaling
-
removeAllKey
public void removeAllKey() -
removeKey
Method removeKey.- Parameters:
vKey-- Returns:
- true if the object was removed from the collection.
-
removeKeyAt
Method removeKeyAt.- Parameters:
index-- Returns:
- the element removed from the collection
-
setKey
- Parameters:
index-vKey-- Throws:
IndexOutOfBoundsException- if the index given is outside the bounds of the collection
-
setKey
- Parameters:
vKeyArray-
-
unmarshal
Method unmarshal.- Parameters:
reader-- Returns:
- the unmarshaled org.exolab.castor.xml.schema.annotations.jdo.PkType
- Throws:
MarshalException- if object is null or if any SAXException is thrown during marshalingValidationException- if this object is an invalid instance according to the schema
-
validate
- Throws:
ValidationException- if this object is an invalid instance according to the schema
-