org.exolab.castor.mapping.xml

Class ClassChoice

Implemented Interfaces:
java.io.Serializable

public class ClassChoice
extends java.lang.Object
implements java.io.Serializable

Class ClassChoice.
Version:
$Revision: 7227 $ $Date$
See Also:
Serialized Form

Constructor Summary

ClassChoice()

Method Summary

void
addContainer(int index, Container vContainer)
void
addContainer(Container vContainer)
void
addFieldMapping(int index, FieldMapping vFieldMapping)
void
addFieldMapping(FieldMapping vFieldMapping)
java.util.Enumeration
enumerateContainer()
Method enumerateContainer.
java.util.Enumeration
enumerateFieldMapping()
Method enumerateFieldMapping.
Container[]
getContainer()
Method getContainer.Returns the contents of the collection in an Array.
Container
getContainer(int index)
Method getContainer.
int
getContainerCount()
Method getContainerCount.
FieldMapping[]
getFieldMapping()
Method getFieldMapping.Returns the contents of the collection in an Array.
FieldMapping
getFieldMapping(int index)
Method getFieldMapping.
int
getFieldMappingCount()
Method getFieldMappingCount.
boolean
isValid()
Method isValid.
java.util.Iterator
iterateContainer()
Method iterateContainer.
java.util.Iterator
iterateFieldMapping()
Method iterateFieldMapping.
void
marshal(java.io.Writer out)
void
marshal(org.xml.sax.ContentHandler handler)
void
removeAllContainer()
void
removeAllFieldMapping()
boolean
removeContainer(Container vContainer)
Method removeContainer.
Container
removeContainerAt(int index)
Method removeContainerAt.
boolean
removeFieldMapping(FieldMapping vFieldMapping)
Method removeFieldMapping.
FieldMapping
removeFieldMappingAt(int index)
Method removeFieldMappingAt.
void
setContainer(int index, Container vContainer)
void
setContainer(Container[] vContainerArray)
void
setFieldMapping(int index, FieldMapping vFieldMapping)
void
setFieldMapping(FieldMapping[] vFieldMappingArray)
static ClassChoice
unmarshal(java.io.Reader reader)
Method unmarshal.
void
validate()

Constructor Details

ClassChoice

public ClassChoice()

Method Details

addContainer

public void addContainer(int index,
                         Container vContainer)
            throws java.lang.IndexOutOfBoundsException
Parameters:
index -
vContainer -

addContainer

public void addContainer(Container vContainer)
            throws java.lang.IndexOutOfBoundsException
Parameters:
vContainer -

addFieldMapping

public void addFieldMapping(int index,
                            FieldMapping vFieldMapping)
            throws java.lang.IndexOutOfBoundsException
Parameters:
index -
vFieldMapping -

addFieldMapping

public void addFieldMapping(FieldMapping vFieldMapping)
            throws java.lang.IndexOutOfBoundsException
Parameters:
vFieldMapping -

enumerateContainer

public java.util.Enumeration enumerateContainer()
Method enumerateContainer.
Returns:
an Enumeration over all possible elements of this collection

enumerateFieldMapping

public java.util.Enumeration enumerateFieldMapping()
Method enumerateFieldMapping.
Returns:
an Enumeration over all possible elements of this collection

getContainer

public Container[] getContainer()
Method getContainer.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

getContainer

public Container getContainer(int index)
            throws java.lang.IndexOutOfBoundsException
Method getContainer.
Parameters:
index -
Returns:
the value of the org.exolab.castor.mapping.xml.Container at the given index

getContainerCount

public int getContainerCount()
Method getContainerCount.
Returns:
the size of this collection

getFieldMapping

public FieldMapping[] getFieldMapping()
Method getFieldMapping.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

getFieldMapping

public FieldMapping getFieldMapping(int index)
            throws java.lang.IndexOutOfBoundsException
Method getFieldMapping.
Parameters:
index -
Returns:
the value of the org.exolab.castor.mapping.xml.FieldMapping at the given index

getFieldMappingCount

public int getFieldMappingCount()
Method getFieldMappingCount.
Returns:
the size of this collection

isValid

public boolean isValid()
Method isValid.
Returns:
true if this object is valid according to the schema

iterateContainer

public java.util.Iterator iterateContainer()
Method iterateContainer.
Returns:
an Iterator over all possible elements in this collection

iterateFieldMapping

public java.util.Iterator iterateFieldMapping()
Method iterateFieldMapping.
Returns:
an Iterator over all possible elements in this collection

marshal

public void marshal(java.io.Writer out)
            throws MarshalException,
                   ValidationException
Parameters:
out -
Throws:
MarshalException - if object is null or if any SAXException is thrown during marshaling
ValidationException - if this object is an invalid instance according to the schema

marshal

public void marshal(org.xml.sax.ContentHandler handler)
            throws java.io.IOException,
                   MarshalException,
                   ValidationException
Parameters:
handler -
Throws:
ValidationException - if this object is an invalid instance according to the schema
MarshalException - if object is null or if any SAXException is thrown during marshaling

removeAllContainer

public void removeAllContainer()

removeAllFieldMapping

public void removeAllFieldMapping()

removeContainer

public boolean removeContainer(Container vContainer)
Method removeContainer.
Parameters:
vContainer -
Returns:
true if the object was removed from the collection.

removeContainerAt

public Container removeContainerAt(int index)
Method removeContainerAt.
Parameters:
index -
Returns:
the element removed from the collection

removeFieldMapping

public boolean removeFieldMapping(FieldMapping vFieldMapping)
Method removeFieldMapping.
Parameters:
vFieldMapping -
Returns:
true if the object was removed from the collection.

removeFieldMappingAt

public FieldMapping removeFieldMappingAt(int index)
Method removeFieldMappingAt.
Parameters:
index -
Returns:
the element removed from the collection

setContainer

public void setContainer(int index,
                         Container vContainer)
            throws java.lang.IndexOutOfBoundsException
Parameters:
index -
vContainer -

setContainer

public void setContainer(Container[] vContainerArray)
Parameters:
vContainerArray -

setFieldMapping

public void setFieldMapping(int index,
                            FieldMapping vFieldMapping)
            throws java.lang.IndexOutOfBoundsException
Parameters:
index -
vFieldMapping -

setFieldMapping

public void setFieldMapping(FieldMapping[] vFieldMappingArray)
Parameters:
vFieldMappingArray -

unmarshal

public static ClassChoice unmarshal(java.io.Reader reader)
            throws MarshalException,
                   ValidationException
Method unmarshal.
Parameters:
reader -
Returns:
the unmarshaled org.exolab.castor.mapping.xml.ClassChoice
Throws:
MarshalException - if object is null or if any SAXException is thrown during marshaling
ValidationException - if this object is an invalid instance according to the schema

validate

public void validate()
            throws ValidationException
Throws:
ValidationException - if this object is an invalid instance according to the schema

Intalio Inc. (C) 1999-2008. All rights reserved http://www.intalio.com