org.exolab.castor.mapping
Interface FieldDescriptor
- JDOFieldDescriptor, XMLFieldDescriptor
- AbstractFieldDescriptor, FieldDescriptorImpl, JDOFieldDescriptorImpl, XMLContainerElementFieldDescriptor, XMLFieldDescriptorImpl
public interface FieldDescriptor
Describes the properties of a field. Implementations will extend this inteface to
provide additional properties.
$Revision: 6216 $ $Date: 2005-12-06 14:55:28 -0700 (Tue, 06 Dec 2005) $
getClassDescriptor
public ClassDescriptor getClassDescriptor()
Returns the class descriptor related to the field type. If the field type is a
class for which a descriptor exists, this descriptor is returned. If the field
type is a class for which no mapping is provided, null is returned.
- The class descriptor of the field type, or null.
getContainingClassDescriptor
public ClassDescriptor getContainingClassDescriptor()
Get the class descriptor which contains this field.
- The class descriptor which contains this field.
getFieldName
public String getFieldName()
Returns the name of the field. The field must have a name, even if set through
accessor methods.
getFieldType
public Class getFieldType()
Returns the Java type of the field.
getHandler
public FieldHandler getHandler()
Returns the handler of the field. In order to persist or marshal a field
descriptor will be associated with a handler.
isImmutable
public boolean isImmutable()
Returns true if the field type is immutable.
- True if the field type is immutable.
isMultivalued
public boolean isMultivalued()
Returns true if the field is multivalued (a collection).
- True if the field is multivalued.
isRequired
public boolean isRequired()
Returns true if the field type is required.
- True if the field type is required.
isTransient
public boolean isTransient()
Returns true if the field is transient. Transient fields are never persisted or
marshalled.
setContainingClassDescriptor
public void setContainingClassDescriptor(ClassDescriptor parent)
Set the class descriptor which contains this field.
parent
- The class descriptor which contains this field.
Intalio Inc. (C) 1999-2006. All rights reserved http://www.intalio.com