|
||||||||||
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.emf.EmfSdoToXml
public class EmfSdoToXml
Function Component that using XML Schema converts Data Objects to an XML document. It also implements a discover
schema functionality through its updateSchema
method.
Field Summary |
---|
Fields inherited from class com.ibm.di.fc.Function |
---|
logger |
Constructor Summary | |
---|---|
EmfSdoToXml()
|
Method Summary | |
---|---|
static commonj.sdo.DataObject |
createRootObject(String xsdFile)
Creates and returns a Data Object corresponding to the root object of a document compliant to the XML Schema specified in the xsdFile file. |
String |
getVersion()
Returns function component's version |
void |
initialize(Object obj)
Initializes the function component. |
Object |
perform(Object obj)
Serializes Data Objects to XML document according to the XML Schema specified by the xsdFile function component parameter. |
boolean |
updateSchema(FunctionConfig config)
Implements the discovery schema functionality. |
Methods inherited from class com.ibm.di.fc.Function |
---|
debug, getConfiguration, getContext, getLog, getParam, getUI, initialize, logmsg, setConfiguration, setContext, setLog, setParam, terminate, verifyInitialized |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public EmfSdoToXml()
Method Detail |
---|
public static commonj.sdo.DataObject createRootObject(String xsdFile) throws Exception
xsdFile
file.
xsdFile
- location of a XML Schema file.
Exception
- if the specified file cannot be found or is not valid XML Schema.
if the XML Schema does not define a root element.public void initialize(Object obj) throws Exception
initialize
in interface FunctionInterface
initialize
in class Function
obj
- this object provides information to the Function Component needed on initialization
Exception
- if the xsdFile parameter is not specifiedpublic Object perform(Object obj) throws Exception
xsdFile
function component parameter. The Data Objects are
stored in the Entry Attributes of the TDI Entry passed as parameter to the function.
obj
- the object is the working TDI Entry and should be of type com.ibm.di.entry.Entry.
Exception
- if the names of the Entry Attributes do not represent valid XML elements.
if an Entry Attribute for the root element does not exist in the
entry and the XML Schema does not define a root element.public boolean updateSchema(FunctionConfig config) throws Exception
updateSchema
in interface FunctionInterface
updateSchema
in class Function
config
- contains the function configuration parameter.
Exception
- If the the xsdFile parameter is not specified.
If the the specified file extension is not .xsd
If the target file is not found
If the target file is not valid XML Schema filepublic String getVersion()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |