*/
public ComponentQuery addMigrationPath(String sourceMimetype, String targetMimetype) {
if ((sourceMimetype != null && !sourceMimetype.isEmpty())
|| (targetMimetype != null && !targetMimetype.isEmpty())) {
Node node = NodeFactory.createAnon();
ElementGroup group = new ElementGroup();
group.addTriplePattern(new Triple(wfNode, NodeFactory.createURI(ONTOLOGY_IRI + "migrates"), node));
group.addTriplePattern(new Triple(node, NodeFactory.createURI(TYPE_IRI), NodeFactory
.createURI(ONTOLOGY_IRI + "MigrationPath")));
if (sourceMimetype != null && !sourceMimetype.isEmpty()) {
group.addTriplePattern(new Triple(node, NodeFactory.createURI(ONTOLOGY_IRI + "sourceMimetype"),
NodeFactory.createLiteral(sourceMimetype)));
}
if (targetMimetype != null && !targetMimetype.isEmpty()) {
group.addTriplePattern(new Triple(node, NodeFactory.createURI(ONTOLOGY_IRI + "targetMimetype"),
NodeFactory.createLiteral(targetMimetype)));
}
query.addElement(group);
}
return this;