org.exolab.castor.mapping.loader

Class AbstractFieldDescriptor

Implemented Interfaces:
FieldDescriptor
Known Direct Subclasses:
FieldDescriptorImpl, XMLFieldDescriptorImpl

public abstract class AbstractFieldDescriptor
extends java.lang.Object
implements FieldDescriptor

Method Summary

ClassDescriptor
getClassDescriptor()
ClassDescriptor
getContainingClassDescriptor()
String
getFieldName()
Class
getFieldType()
FieldHandler
getHandler()
boolean
isIdentity()
Is the described field is part of the identity of the class it belongs to?
boolean
isImmutable()
boolean
isMultivalued()
boolean
isRequired()
boolean
isTransient()
void
setClassDescriptor(ClassDescriptor classDescriptor)
Set the ClassDescriptor for the described field.
void
setContainingClassDescriptor(ClassDescriptor parent)
void
setFieldName(String fieldName)
Set the name of the field.
void
setFieldType(Class fieldType)
Set the type of the field.
void
setHandler(FieldHandler handler)
Set the FieldHandler for the field being described by this FieldDescriptor.
void
setIdentity(boolean identity)
Set wether the described field is part of the identity of the class it belongs to.
void
setImmutable(boolean immutable)
Set the immutable flag which indicates that changes to this Field result in a new Object to be created, such as java.lang.String.
void
setMultivalued(boolean multivalued)
Set wheter the object described by this descriptor is multivalued or not.
void
setRequired(boolean required)
Set whether or not the described field is required.
void
setTransient(boolean isTransient)
Sets whether or not the describled field is 'transient'.

Method Details

getClassDescriptor

public final ClassDescriptor getClassDescriptor()
Specified by:
getClassDescriptor in interface FieldDescriptor
See Also:
{@inheritDoc}

getContainingClassDescriptor

public final ClassDescriptor getContainingClassDescriptor()
Specified by:
getContainingClassDescriptor in interface FieldDescriptor
See Also:
{@inheritDoc}

getFieldName

public final String getFieldName()
Specified by:
getFieldName in interface FieldDescriptor
See Also:
{@inheritDoc}

getFieldType

public final Class getFieldType()
Specified by:
getFieldType in interface FieldDescriptor
See Also:
{@inheritDoc}

getHandler

public final FieldHandler getHandler()
Specified by:
getHandler in interface FieldDescriptor
See Also:
{@inheritDoc}

isIdentity

public final boolean isIdentity()
Is the described field is part of the identity of the class it belongs to?
Returns:
true if field is part of the classes identity.

isImmutable

public final boolean isImmutable()
Specified by:
isImmutable in interface FieldDescriptor
See Also:
{@inheritDoc}

isMultivalued

public final boolean isMultivalued()
Specified by:
isMultivalued in interface FieldDescriptor
See Also:
{@inheritDoc}

isRequired

public final boolean isRequired()
Specified by:
isRequired in interface FieldDescriptor
See Also:
{@inheritDoc}

isTransient

public final boolean isTransient()
Specified by:
isTransient in interface FieldDescriptor
See Also:
{@inheritDoc}

setClassDescriptor

public final void setClassDescriptor(ClassDescriptor classDescriptor)
Set the ClassDescriptor for the described field.
Parameters:
classDescriptor - The ClassDescriptor for the described field.

setContainingClassDescriptor

public final void setContainingClassDescriptor(ClassDescriptor parent)
Specified by:
setContainingClassDescriptor in interface FieldDescriptor
See Also:
{@inheritDoc}

setFieldName

public final void setFieldName(String fieldName)
Set the name of the field.
Parameters:
fieldName - Field name.

setFieldType

public final void setFieldType(Class fieldType)
Set the type of the field.
Parameters:
fieldType - Field type.

setHandler

public final void setHandler(FieldHandler handler)
Set the FieldHandler for the field being described by this FieldDescriptor.
Parameters:
handler - The FieldHandler for the field being described.

setIdentity

public final void setIdentity(boolean identity)
Set wether the described field is part of the identity of the class it belongs to.
Parameters:
identity - true if field is part of the classes identity.

setImmutable

public final void setImmutable(boolean immutable)
Set the immutable flag which indicates that changes to this Field result in a new Object to be created, such as java.lang.String. It serves to identify fields which should not be constructed until all the data is available.
Parameters:
immutable - Flag which if true indicates that the field is immutable.

setMultivalued

public final void setMultivalued(boolean multivalued)
Set wheter the object described by this descriptor is multivalued or not.
Parameters:
multivalued - True if the object described by this descriptor is multivalued.

setRequired

public final void setRequired(boolean required)
Set whether or not the described field is required.
Parameters:
required - The flag indicating whether or not the described field is required.

setTransient

public final void setTransient(boolean isTransient)
Sets whether or not the describled field is 'transient'.
Parameters:
isTransient - The flag indicating if the described field is 'transient'.

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