Package org.jibx.binding.def
Class LinkableBase
java.lang.Object
org.jibx.binding.def.PassThroughComponent
org.jibx.binding.def.LinkableBase
- All Implemented Interfaces:
IComponent
,ILinkable
- Direct Known Subclasses:
MappingBase
Base class for components that can be linked from multiple locations within
the binding definition structure. The implemented basic behavior is a simple
pass-through component, with the addition of recursion checking during the
linking phase.
- Author:
- Dennis M. Sosnoski
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate boolean
Flag for linkage complete.private boolean
Flag for linkage in progress.Fields inherited from class org.jibx.binding.def.PassThroughComponent
m_component
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
No argument constructor.LinkableBase
(IComponent wrap) Constructor. -
Method Summary
Methods inherited from class org.jibx.binding.def.PassThroughComponent
genAttributeMarshal, genAttributeUnmarshal, genAttrPresentTest, genContentMarshal, genContentPresentTest, genContentUnmarshal, genLoadId, genNewInstance, getType, getWrapperName, hasAttribute, hasContent, hasId, isOptional, setWrappedComponent
-
Field Details
-
m_isLinking
private boolean m_isLinkingFlag for linkage in progress. -
m_isLinked
private boolean m_isLinkedFlag for linkage complete.
-
-
Constructor Details
-
LinkableBase
protected LinkableBase()No argument constructor. This requires the component to be set later, using thePassThroughComponent.setWrappedComponent(org.jibx.binding.def.IComponent)
method. -
LinkableBase
Constructor.- Parameters:
wrap
- wrapped binding component
-
-
Method Details
-
handleRecursion
protected void handleRecursion()Handler for recursion. If recursion is found during linking this method will be called. The base class implementation does nothing, but may be overridden by subclases to implement the appropriate behavior. -
isLinked
protected boolean isLinked()Check if linkage processing for this component is complete.- Returns:
true
if complete,false
if not
-
setLinkages
Description copied from interface:ILinkable
Establish and validate linkages between binding components. This is called after the basic binding structures have been set up. All linkages between components must be resolved by this method, in order to prevent problems due to the order of definitions between components. This implies that each component must in turn call the same method for each child component. None of the other method calls defined by this interface are valid until after this call.- Specified by:
setLinkages
in interfaceILinkable
- Overrides:
setLinkages
in classPassThroughComponent
- Throws:
JiBXException
- if error in configuration
-
print
public void print(int depth) - Specified by:
print
in interfaceIComponent
- Overrides:
print
in classPassThroughComponent
-