Class FieldType
- java.lang.Object
-
- org.exolab.castor.builder.binding.xml.FieldType
-
- All Implemented Interfaces:
java.io.Serializable
public class FieldType extends java.lang.Object implements java.io.SerializableThis type represents the binding for class member. It allows the definition of its name and java type as well as an implementation of FieldHandler to help the Marshalling framework in handling that member. Defining a validator is also possible. The names given for the validator and the fieldHandler must be fully qualified- Version:
- $Revision$ $Date$
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description FieldType()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddeleteWrapper()FieldTypeCollectionTypegetCollection()Returns the value of field 'collection'.java.lang.StringgetHandler()Returns the value of field 'handler'.java.lang.StringgetJavaType()Returns the value of field 'javaType'.java.lang.StringgetName()Returns the value of field 'name'.java.lang.StringgetValidator()Returns the value of field 'validator'.FieldTypeVisibilityTypegetVisibility()Returns the value of field 'visibility'.booleangetWrapper()Returns the value of field 'wrapper'.booleanhasWrapper()Method hasWrapper.booleanisValid()Method isValid.booleanisWrapper()Returns the value of field 'wrapper'.voidmarshal(java.io.Writer out)voidmarshal(org.xml.sax.ContentHandler handler)voidsetCollection(FieldTypeCollectionType collection)Sets the value of field 'collection'.voidsetHandler(java.lang.String handler)Sets the value of field 'handler'.voidsetJavaType(java.lang.String javaType)Sets the value of field 'javaType'.voidsetName(java.lang.String name)Sets the value of field 'name'.voidsetValidator(java.lang.String validator)Sets the value of field 'validator'.voidsetVisibility(FieldTypeVisibilityType visibility)Sets the value of field 'visibility'.voidsetWrapper(boolean wrapper)Sets the value of field 'wrapper'.static FieldTypeunmarshalFieldType(java.io.Reader reader)Method unmarshalFieldType.voidvalidate()
-
-
-
Method Detail
-
deleteWrapper
public void deleteWrapper()
-
getCollection
public FieldTypeCollectionType getCollection()
Returns the value of field 'collection'.- Returns:
- the value of field 'Collection'.
-
getHandler
public java.lang.String getHandler()
Returns the value of field 'handler'.- Returns:
- the value of field 'Handler'.
-
getJavaType
public java.lang.String getJavaType()
Returns the value of field 'javaType'.- Returns:
- the value of field 'JavaType'.
-
getName
public java.lang.String getName()
Returns the value of field 'name'.- Returns:
- the value of field 'Name'.
-
getValidator
public java.lang.String getValidator()
Returns the value of field 'validator'.- Returns:
- the value of field 'Validator'.
-
getVisibility
public FieldTypeVisibilityType getVisibility()
Returns the value of field 'visibility'.- Returns:
- the value of field 'Visibility'.
-
getWrapper
public boolean getWrapper()
Returns the value of field 'wrapper'.- Returns:
- the value of field 'Wrapper'.
-
hasWrapper
public boolean hasWrapper()
Method hasWrapper.- Returns:
- true if at least one Wrapper has been added
-
isValid
public boolean isValid()
Method isValid.- Returns:
- true if this object is valid according to the schema
-
isWrapper
public boolean isWrapper()
Returns the value of field 'wrapper'.- Returns:
- the value of field 'Wrapper'.
-
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 marshalingValidationException- 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:
java.io.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
-
setCollection
public void setCollection(FieldTypeCollectionType collection)
Sets the value of field 'collection'.- Parameters:
collection- the value of field 'collection'.
-
setHandler
public void setHandler(java.lang.String handler)
Sets the value of field 'handler'.- Parameters:
handler- the value of field 'handler'.
-
setJavaType
public void setJavaType(java.lang.String javaType)
Sets the value of field 'javaType'.- Parameters:
javaType- the value of field 'javaType'.
-
setName
public void setName(java.lang.String name)
Sets the value of field 'name'.- Parameters:
name- the value of field 'name'.
-
setValidator
public void setValidator(java.lang.String validator)
Sets the value of field 'validator'.- Parameters:
validator- the value of field 'validator'.
-
setVisibility
public void setVisibility(FieldTypeVisibilityType visibility)
Sets the value of field 'visibility'.- Parameters:
visibility- the value of field 'visibility'.
-
setWrapper
public void setWrapper(boolean wrapper)
Sets the value of field 'wrapper'.- Parameters:
wrapper- the value of field 'wrapper'.
-
unmarshalFieldType
public static FieldType unmarshalFieldType(java.io.Reader reader) throws MarshalException, ValidationException
Method unmarshalFieldType.- Parameters:
reader-- Returns:
- the unmarshaled org.exolab.castor.builder.binding.xml.FieldType
- 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
public void validate() throws ValidationException- Throws:
ValidationException- if this object is an invalid instance according to the schema
-
-