I am using Contivo 3.11 to do mapping between 2 XML documents. For one element I am calling a Java utility to do the conversion. I am told that the utility is fine, but I need to test the entire mapping, and I do not know where to place the utility so that I can test it.
Mapping rule:
If Source Exists
Call "my.package.MyClass.myMethod" Source to Target with java
end if
There are a few different ways that this could be done.
If you have a compiled
.class
file: Place the.class
file under<Contivo install dir>\domTransforms
. This particular directory is added to Contivo's Classpath, and hence your.class
should be picked up.If you have a
.jar
bundle: It really doesn't matter where you put the.jar
file, but I would suggest to put it under<Contivo install dir>\lib
for consistency. You will have to edit theanalyst.bat
file to manually add the.jar
to Contivo's classpath, which would look something likeset cp=%cp%;.\lib\YourJarName.jar
Word of Caution: Contivo 3.11 runs on Java 1.5, so you have to be careful for your code compatibility. Also, the method signature is of utmost importance, the signature can't be of anything other than
public String myMethod(IContivoRuntime icr, String [] args) throws TRuntimeEngineException