Package org.castor.xml
Class UnmarshalListenerAdapter
java.lang.Object
org.castor.xml.UnmarshalListenerAdapter
- All Implemented Interfaces:
UnmarshalListener
This class is responsible to adapt from new (1.2) UnmarshalListener interface to calls into the
old interface.
The old interface has been marked as deprecated but will be supported for some Castor releases to come. When the deprecated interface will be removed also this adapter implementation is useless and should be removed.
The old interface has been marked as deprecated but will be supported for some Castor releases to come. When the deprecated interface will be removed also this adapter implementation is useless and should be removed.
- Version:
- $Revision$
- Author:
- Joachim Grueneis, jgrueneis AT codehaus DOT org
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
attributesProcessed
(Object target, Object parent) This method is called once the attributes have been processed.void
fieldAdded
(String fieldName, Object parent, Object child) This method is called after a child object has been added during the unmarshalling.void
initialized
(Object target, Object parent) This method is called when an object has just been initialized by theUnmarshaller
.void
setOldListener
(UnmarshalListener exolabListener) To set an 'old style' unmarshal listener to receive the callback calls.void
unmarshalled
(Object target, Object parent) This method is called after an object has been completely unmarshalled, including all of its children (if any).
-
Constructor Details
-
UnmarshalListenerAdapter
public UnmarshalListenerAdapter()
-
-
Method Details
-
setOldListener
To set an 'old style' unmarshal listener to receive the callback calls.- Parameters:
exolabListener
- the 'old style' unmarshal listener
-
attributesProcessed
Description copied from interface:UnmarshalListener
This method is called once the attributes have been processed. It indicates that the the fields of the given object corresponding to attributes in the XML document have been set.- Specified by:
attributesProcessed
in interfaceUnmarshalListener
- Parameters:
target
- the Object the object being unmarshalled.parent
- the parent of the target being unmarshalled
-
fieldAdded
Description copied from interface:UnmarshalListener
This method is called after a child object has been added during the unmarshalling. This method will be called afterinvalid reference
#unmarshalled(Object)
- Specified by:
fieldAdded
in interfaceUnmarshalListener
- Parameters:
fieldName
- The Name of the field the child is being added to.parent
- The Object being unmarshalled.child
- The Object that was just added.
-
initialized
Description copied from interface:UnmarshalListener
This method is called when an object has just been initialized by theUnmarshaller
.- Specified by:
initialized
in interfaceUnmarshalListener
- Parameters:
target
- the Object that was initialized.parent
- the parent of the target that was initialized
-
unmarshalled
Description copied from interface:UnmarshalListener
This method is called after an object has been completely unmarshalled, including all of its children (if any).- Specified by:
unmarshalled
in interfaceUnmarshalListener
- Parameters:
target
- the Object that was unmarshalled.parent
- the parent of the target that was unmarshalled
-