Public Member Functions | |
abstract void | checkValidity (Object object) throws ValidityException, IllegalStateException |
abstract Object | getValue (Object object) throws IllegalStateException |
abstract Object | newInstance (Object parent) throws IllegalStateException |
abstract void | resetValue (Object object) throws IllegalStateException, IllegalArgumentException |
abstract void | setValue (Object object, Object value) throws IllegalStateException, IllegalArgumentException |
Protected Member Functions | |
abstract FieldDescriptor | getFieldDescriptor () |
abstract void | setFieldDescriptor (FieldDescriptor fieldDesc) |
An extended version of the FieldHandler interface which is used for adding additional functionality while preserving backward compatability.
abstract void org.exolab.castor.mapping.loader.FieldHandlerFriend.checkValidity | ( | Object | object | ) | throws ValidityException, IllegalStateException [pure virtual] |
Implements org.exolab.castor.mapping.FieldHandler.
Implemented in org.exolab.castor.mapping.ExtendedFieldHandler, org.exolab.castor.types.CenturyDescriptor.CenturyFieldHandler, org.exolab.castor.types.DateDescriptor.DateFieldHandler, org.exolab.castor.types.DurationDescriptor.DurationFieldHandler, org.exolab.castor.types.GDayDescriptor.GDayFieldHandler, org.exolab.castor.types.GMonthDayDescriptor.GMonthDayFieldHandler, org.exolab.castor.types.GMonthDescriptor.GMonthFieldHandler, org.exolab.castor.types.GYearDescriptor.GYearFieldHandler, org.exolab.castor.types.GYearMonthDescriptor.GYearMonthFieldHandler, org.exolab.castor.types.MonthDescriptor.MonthFieldHandler, org.exolab.castor.types.RecurringDurationDescriptor.RecurringDurationFieldHandler, org.exolab.castor.types.TimeDescriptor.TimeFieldHandler, org.exolab.castor.types.TimeDurationDescriptor.TimeDurationFieldHandler, org.exolab.castor.types.TimePeriodDescriptor.TimePeriodFieldHandler, org.exolab.castor.types.YearDescriptor.YearFieldHandler, and org.exolab.castor.xml.handlers.CollectionFieldHandler.
abstract FieldDescriptor org.exolab.castor.mapping.loader.FieldHandlerFriend.getFieldDescriptor | ( | ) | [protected, pure virtual] |
Returns the FieldDescriptor for the field that this handler is reponsibile for, or null if no FieldDescriptor has been set. This method is useful for implementations of the FieldHandler interface that wish to obtain information about the field in order to make the FieldHandler more generic and reusable, or simply for validation purposes.
Implemented in org.exolab.castor.mapping.AbstractFieldHandler, and org.exolab.castor.mapping.ExtendedFieldHandler.
abstract Object org.exolab.castor.mapping.loader.FieldHandlerFriend.getValue | ( | Object | object | ) | throws IllegalStateException [pure virtual] |
Returns the value of the field from the object.
object | The object |
IllegalStateException | The Java object has changed and is no longer supported by this handler, or the handler is not compatiable with the Java object |
Implements org.exolab.castor.mapping.FieldHandler.
Implemented in org.exolab.castor.mapping.AbstractFieldHandler, org.exolab.castor.mapping.ExtendedFieldHandler, org.exolab.castor.mapping.GeneralizedFieldHandler, org.exolab.castor.mapping.handlers.TransientFieldHandler, org.exolab.castor.mapping.loader.FieldHandlerImpl, org.exolab.castor.types.CenturyDescriptor.CenturyFieldHandler, org.exolab.castor.types.DateDescriptor.DateFieldHandler, org.exolab.castor.types.DurationDescriptor.DurationFieldHandler, org.exolab.castor.types.GDayDescriptor.GDayFieldHandler, org.exolab.castor.types.GMonthDayDescriptor.GMonthDayFieldHandler, org.exolab.castor.types.GMonthDescriptor.GMonthFieldHandler, org.exolab.castor.types.GYearDescriptor.GYearFieldHandler, org.exolab.castor.types.GYearMonthDescriptor.GYearMonthFieldHandler, org.exolab.castor.types.MonthDescriptor.MonthFieldHandler, org.exolab.castor.types.RecurringDurationDescriptor.RecurringDurationFieldHandler, org.exolab.castor.types.TimeDescriptor.TimeFieldHandler, org.exolab.castor.types.TimeDurationDescriptor.TimeDurationFieldHandler, org.exolab.castor.types.TimePeriodDescriptor.TimePeriodFieldHandler, org.exolab.castor.types.YearDescriptor.YearFieldHandler, org.exolab.castor.xml.handlers.CollectionFieldHandler, org.exolab.castor.xml.handlers.DateFieldHandler, and org.exolab.castor.xml.XMLFieldHandler.
abstract Object org.exolab.castor.mapping.loader.FieldHandlerFriend.newInstance | ( | Object | parent | ) | throws IllegalStateException [pure virtual] |
Creates a new instance of the object described by this field.
parent | The object for which the field is created |
IllegalStateException | This field is a simple type and cannot be instantiated |
Implements org.exolab.castor.mapping.FieldHandler.
Implemented in org.exolab.castor.mapping.AbstractFieldHandler, org.exolab.castor.mapping.ExtendedFieldHandler, org.exolab.castor.mapping.GeneralizedFieldHandler, org.exolab.castor.mapping.handlers.EnumFieldHandler, org.exolab.castor.mapping.handlers.TransientFieldHandler, org.exolab.castor.mapping.loader.FieldHandlerImpl, org.exolab.castor.types.CenturyDescriptor.CenturyFieldHandler, org.exolab.castor.types.DateDescriptor.DateFieldHandler, org.exolab.castor.types.DurationDescriptor.DurationFieldHandler, org.exolab.castor.types.GDayDescriptor.GDayFieldHandler, org.exolab.castor.types.GMonthDayDescriptor.GMonthDayFieldHandler, org.exolab.castor.types.GMonthDescriptor.GMonthFieldHandler, org.exolab.castor.types.GYearDescriptor.GYearFieldHandler, org.exolab.castor.types.GYearMonthDescriptor.GYearMonthFieldHandler, org.exolab.castor.types.MonthDescriptor.MonthFieldHandler, org.exolab.castor.types.RecurringDurationDescriptor.RecurringDurationFieldHandler, org.exolab.castor.types.TimeDescriptor.TimeFieldHandler, org.exolab.castor.types.TimeDurationDescriptor.TimeDurationFieldHandler, org.exolab.castor.types.TimePeriodDescriptor.TimePeriodFieldHandler, org.exolab.castor.types.YearDescriptor.YearFieldHandler, org.exolab.castor.xml.handlers.CollectionFieldHandler, org.exolab.castor.xml.handlers.DateFieldHandler, org.exolab.castor.xml.handlers.SQLTimeFieldHandler, org.exolab.castor.xml.handlers.SQLTimestampFieldHandler, org.exolab.castor.xml.handlers.ValueOfFieldHandler, and org.exolab.castor.xml.XMLFieldHandler.
abstract void org.exolab.castor.mapping.loader.FieldHandlerFriend.resetValue | ( | Object | object | ) | throws IllegalStateException, IllegalArgumentException [pure virtual] |
Sets the value of the field to a default value.
Reference fields are set to null, primitive fields are set to their default value, collection fields are emptied of all elements.
object | The object |
IllegalStateException | The Java object has changed and is no longer supported by this handler, or the handler is not compatiable with the Java object |
Implements org.exolab.castor.mapping.FieldHandler.
Implemented in org.exolab.castor.mapping.AbstractFieldHandler, org.exolab.castor.mapping.ExtendedFieldHandler, org.exolab.castor.mapping.GeneralizedFieldHandler, org.exolab.castor.mapping.handlers.TransientFieldHandler, org.exolab.castor.mapping.loader.FieldHandlerImpl, org.exolab.castor.types.CenturyDescriptor.CenturyFieldHandler, org.exolab.castor.types.DateDescriptor.DateFieldHandler, org.exolab.castor.types.DurationDescriptor.DurationFieldHandler, org.exolab.castor.types.GDayDescriptor.GDayFieldHandler, org.exolab.castor.types.GMonthDayDescriptor.GMonthDayFieldHandler, org.exolab.castor.types.GMonthDescriptor.GMonthFieldHandler, org.exolab.castor.types.GYearDescriptor.GYearFieldHandler, org.exolab.castor.types.GYearMonthDescriptor.GYearMonthFieldHandler, org.exolab.castor.types.MonthDescriptor.MonthFieldHandler, org.exolab.castor.types.RecurringDurationDescriptor.RecurringDurationFieldHandler, org.exolab.castor.types.TimeDescriptor.TimeFieldHandler, org.exolab.castor.types.TimeDurationDescriptor.TimeDurationFieldHandler, org.exolab.castor.types.TimePeriodDescriptor.TimePeriodFieldHandler, org.exolab.castor.types.YearDescriptor.YearFieldHandler, org.exolab.castor.xml.handlers.CollectionFieldHandler, org.exolab.castor.xml.handlers.DateFieldHandler, and org.exolab.castor.xml.XMLFieldHandler.
abstract void org.exolab.castor.mapping.loader.FieldHandlerFriend.setFieldDescriptor | ( | FieldDescriptor | fieldDesc | ) | [protected, pure virtual] |
Sets the FieldDescriptor that this FieldHander is responsibile for. By setting the FieldDescriptor, it allows the implementation of the FieldHandler methods to obtain information about the field itself. This allows a particular implementation to become more generic and reusable.
fieldDesc | the FieldDescriptor to set |
Implemented in org.exolab.castor.mapping.AbstractFieldHandler, and org.exolab.castor.mapping.ExtendedFieldHandler.
abstract void org.exolab.castor.mapping.loader.FieldHandlerFriend.setValue | ( | Object | object, | |
Object | value | |||
) | throws IllegalStateException, IllegalArgumentException [pure virtual] |
Sets the value of the field on the object.
object | The object | |
value | The new value |
IllegalStateException | The Java object has changed and is no longer supported by this handler, or the handler is not compatiable with the Java object IllegalArgumentException The value passed is not of a supported type |
Implements org.exolab.castor.mapping.FieldHandler.
Implemented in org.exolab.castor.mapping.AbstractFieldHandler, org.exolab.castor.mapping.ExtendedFieldHandler, org.exolab.castor.mapping.GeneralizedFieldHandler, org.exolab.castor.mapping.handlers.TransientFieldHandler, org.exolab.castor.mapping.loader.FieldHandlerImpl, org.exolab.castor.types.CenturyDescriptor.CenturyFieldHandler, org.exolab.castor.types.DateDescriptor.DateFieldHandler, org.exolab.castor.types.DurationDescriptor.DurationFieldHandler, org.exolab.castor.types.GDayDescriptor.GDayFieldHandler, org.exolab.castor.types.GMonthDayDescriptor.GMonthDayFieldHandler, org.exolab.castor.types.GMonthDescriptor.GMonthFieldHandler, org.exolab.castor.types.GYearDescriptor.GYearFieldHandler, org.exolab.castor.types.GYearMonthDescriptor.GYearMonthFieldHandler, org.exolab.castor.types.MonthDescriptor.MonthFieldHandler, org.exolab.castor.types.RecurringDurationDescriptor.RecurringDurationFieldHandler, org.exolab.castor.types.TimeDescriptor.TimeFieldHandler, org.exolab.castor.types.TimeDurationDescriptor.TimeDurationFieldHandler, org.exolab.castor.types.TimePeriodDescriptor.TimePeriodFieldHandler, org.exolab.castor.types.YearDescriptor.YearFieldHandler, org.exolab.castor.xml.handlers.CollectionFieldHandler, org.exolab.castor.xml.handlers.DateFieldHandler, and org.exolab.castor.xml.XMLFieldHandler.