org.apache.tuscany.sca.databinding.xmlbeans
Class XMLBeansWrapperHandler

java.lang.Object
  extended by org.apache.tuscany.sca.databinding.xmlbeans.XMLBeansWrapperHandler
All Implemented Interfaces:
WrapperHandler<XmlObject>

public class XMLBeansWrapperHandler
extends java.lang.Object
implements WrapperHandler<XmlObject>


Constructor Summary
XMLBeansWrapperHandler()
           
 
Method Summary
 XmlObject create(Operation operation, boolean input)
          Create a wrapper element
 java.util.List getChildren(XmlObject wrapper, Operation operation, boolean input)
          Get a list of child elements from the wrapper
 DataType getWrapperType(Operation operation, boolean input)
          Get the data type for the wrapper
 boolean isInstance(java.lang.Object wrapper, Operation operation, boolean input)
          Check if the given data is an instance of the wrapper
 void setChildren(XmlObject wrapper, java.lang.Object[] childObjects, Operation operation, boolean input)
          Populate the wrapper element with the child objects
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XMLBeansWrapperHandler

public XMLBeansWrapperHandler()
Method Detail

create

public XmlObject create(Operation operation,
                        boolean input)
Description copied from interface: WrapperHandler
Create a wrapper element

Specified by:
create in interface WrapperHandler<XmlObject>
Parameters:
operation - The operation
input - Is it for input or output
Returns:
An object representing the wrapper element
See Also:
WrapperHandler.create(org.apache.tuscany.sca.interfacedef.Operation, boolean)

getChildren

public java.util.List getChildren(XmlObject wrapper,
                                  Operation operation,
                                  boolean input)
Description copied from interface: WrapperHandler
Get a list of child elements from the wrapper

Specified by:
getChildren in interface WrapperHandler<XmlObject>
Parameters:
wrapper - The wrapper object
operation - The operation
input - Is it for input or output
Returns:
child elements under the wrapper
See Also:
WrapperHandler.getChildren(java.lang.Object, org.apache.tuscany.sca.interfacedef.Operation, boolean)

getWrapperType

public DataType getWrapperType(Operation operation,
                               boolean input)
Description copied from interface: WrapperHandler
Get the data type for the wrapper

Specified by:
getWrapperType in interface WrapperHandler<XmlObject>
Parameters:
operation - The operation
input - Is it for input or output?
Returns:
The data type of the wrapper, null if it's not a wrapper type
See Also:
WrapperHandler.getWrapperType(org.apache.tuscany.sca.interfacedef.Operation, boolean)

isInstance

public boolean isInstance(java.lang.Object wrapper,
                          Operation operation,
                          boolean input)
Description copied from interface: WrapperHandler
Check if the given data is an instance of the wrapper

Specified by:
isInstance in interface WrapperHandler<XmlObject>
operation - The operation
input - Input or output
Returns:
See Also:
WrapperHandler.isInstance(java.lang.Object, org.apache.tuscany.sca.interfacedef.Operation, boolean)

setChildren

public void setChildren(XmlObject wrapper,
                        java.lang.Object[] childObjects,
                        Operation operation,
                        boolean input)
Description copied from interface: WrapperHandler
Populate the wrapper element with the child objects

Specified by:
setChildren in interface WrapperHandler<XmlObject>
Parameters:
wrapper - The wrapper object
childObjects - The child objects
operation - The operation
input - Is it for input or output
See Also:
WrapperHandler.setChildren(java.lang.Object, java.lang.Object[], org.apache.tuscany.sca.interfacedef.Operation, boolean)