|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.ibm.di.fc.Function
com.ibm.di.fc.castorbind.CastorJavaToXML
public class CastorJavaToXML
This is the CastorJavaToXML class. This is the main class of the CastorJavaToXML function component. The CastorJavaToXML Function Component creates an XML document from a Java object or an Entry object.
| Field Summary |
|---|
| Fields inherited from class com.ibm.di.fc.Function |
|---|
logger |
| Constructor Summary | |
|---|---|
CastorJavaToXML()
|
|
| Method Summary | |
|---|---|
String |
getVersion()
Version information. |
void |
initialize(Object obj)
In the initialize method the FC initializes its parameters. |
Entry |
marshal(Entry aEntry,
String aMappingFile,
String aRootElementName,
boolean aUseAttrNames)
This method is called when the CastorJavaToXML FC is passed an Entry object. |
Object |
marshal(Object aObject,
String aMappingFile)
This method is called when the CastorJavaToXML FC is passed a Java object which is not an Entry object, the metho will serialize the object passed using Castor serialization and this will be the result XML. |
Object |
perform(Object obj)
The CastorJavaToXML Function Component can operate both with Entry objects and with custom Java objects. |
| Methods inherited from class com.ibm.di.fc.Function |
|---|
debug, getConfiguration, getContext, getDebug, getLog, getParam, getRSInterface, getUI, initialize, logmsg, querySchema, setConfiguration, setContext, setDebug, setLog, setParam, setRSInterface, terminate, updateSchema, verifyInitialized |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CastorJavaToXML()
| Method Detail |
|---|
public void initialize(Object obj)
throws Exception
initialize in interface FunctionInterfaceinitialize in class Functionobj - not used.
Exception - If the mapping file parameter is missing or the return type
is not valid.
public Object perform(Object obj)
throws Exception
obj - this is the input object passed to the FC.
Exception - If initialization is not performed or if an Exception occur
during the marshaling process.
public Entry marshal(Entry aEntry,
String aMappingFile,
String aRootElementName,
boolean aUseAttrNames)
throws Exception
aEntry - the input data as an Entry object.aMappingFile - the path to the Castor XML Mapping File that defines mapping
rules.aRootElementName - This parameter specifies the name of the root element of the
generated XML.aUseAttrNames - When set to "true" the names of the Entry Attributes are used
as XML element names, otherwise the XML elements are named as
specified in the mapping file.
Exception - If an Exception occurs during the object marshaling.
public Object marshal(Object aObject,
String aMappingFile)
throws Exception
aObject - the input data as a java.lang.Object.aMappingFile - the path to the Castor XML Mapping File that defines mapping
rules.
Exception - If an Exception occurs during the object marshaling.public String getVersion()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||