We have our own xml/xsd description of processes (workflows) which is interpreted in SGWT application and run as workflow for user.
The goal is to allow easy modifications according to the user specification.
So, we have used ServiceTask.class this way:
Code:
private static class ProcessElementFactory {
public static ProcessElement getProcessElement(String type) {
ProcessElement processElement;
if (type.equalsIgnoreCase("scriptTask")) {
processElement = new ScriptTask();
} else if (type.equalsIgnoreCase("serviceTask")) {
processElement = new ServiceTask();
} else if (type.equalsIgnoreCase("userTask")) {
processElement = new UserTask();
} else if (type.equalsIgnoreCase("xorGateway")) {
processElement = new XORGateway();
} else {
processElement = new ProcessElement();
}
return processElement;
}
}
Sure, no problem.
Thank you,
MichalG
Leave a comment: