Hi everyone,
In command line tool, the remaining command that is to be implemented is
validate.
So I read the taverna api
http://taverna.incubator.apache.org/javadoc/taverna-language/overview-summary.html
and experimented the 'validate' method.
http://taverna.incubator.apache.org/javadoc/taverna-language/org/apache/taverna/scufl2/validation/Validator.html#validate(org.apache.taverna.scufl2.api.container.WorkflowBundle)

Following is the sample code.

WorkflowBundleIO wfbio = new WorkflowBundleIO();
File f = new File("/home/menaka/conv/aaa/helloworld.wfbundle");
WorkflowBundle aw;
try {
aw = wfbio.readBundle(f, null);
CorrectnessValidator v = new CorrectnessValidator();
CorrectnessValidationListener a = new ReportCorrectnessValidationListener();
a = v.validate(aw);
System.out.println(a.toString());
} catch (ReaderException | IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}

This is the output.
ReportCorrectnessValidationListener [getNegativeValueProblems()=[],
getEmptyIterationStrategyTopNodeProblems()=[],
getMismatchConfigurableTypeProblems()=[], getNonAbsoluteURIProblems()=[],
getNullFieldProblems()=[], getOutOfScopeValueProblems()=[],
getPortMentionedTwiceProblems()=[],
getPortMissingFromIterationStrategyStackProblems()=[],
getWrongParentProblems()=[], getIncompatibleGranularDepthProblems()=[]]

Is this the validation report?


Cheers
Menaka

-- 
Menaka Madushanka Jayawardena
Faculty of Engineering, <http://www.pdn.ac.lk/eng>
University of Peradeniyaya.
LinkedIn <http://lk.linkedin.com/in/menakajayawardena>

Reply via email to