|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jbpm.jpdl.internal.convert.Jpdl3Converter
public class Jpdl3Converter
Trimmed down version JpdlXmlReader (jBPM3 code base), to have exactly the same parsing as in jBPM3. Note that the foremost requirement for this class is readability and extensibility. People who want to adapt the conversion logic for their own processes are advised to adapt this class.
| Field Summary | |
|---|---|
protected org.xml.sax.InputSource |
inputSource
|
protected org.dom4j.Document |
jpdl3Document
|
protected org.dom4j.Document |
jpdl4Document
|
protected java.util.Map<java.lang.String,org.dom4j.Element> |
nodeCollection
|
protected ProblemListener |
problemListener
|
protected java.util.List<Problem> |
problems
|
protected java.util.Map<java.lang.String,org.dom4j.Element> |
swimlanesCollection
|
protected java.util.Collection<java.lang.Object[]> |
unresolvedActionReferences
|
protected java.util.Collection<java.lang.Object[]> |
unresolvedTransitionDestinations
|
| Constructor Summary | |
|---|---|
Jpdl3Converter(org.xml.sax.InputSource inputSource)
Constructor using an InputSource pointing to a jpdl3 process file. |
|
Jpdl3Converter(java.io.Reader reader)
Constructor using a Reader pointing to a jpdl3 process file. |
|
Jpdl3Converter(java.net.URL url)
Constructor using an URL pointing to a jpdl3 process file. |
|
| Method Summary | |
|---|---|
void |
addError(java.lang.String description)
|
void |
addError(java.lang.String description,
java.lang.Throwable exception)
|
void |
addProblem(Problem problem)
|
void |
addUnresolvedActionReference(org.dom4j.Element actionElemen)
|
void |
addUnresolvedTransitionDestination(org.dom4j.Element nodeElement,
org.dom4j.Element jpdl4Element)
|
void |
addWarning(java.lang.String description)
|
void |
close()
|
void |
convertActions(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element,
java.lang.String eventType)
|
protected void |
convertAssignmentDelegation(org.dom4j.Element jpdl3AssignmentElement,
org.dom4j.Element jpdl4Task)
|
void |
convertEvents(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
|
protected void |
convertExceptionHandlers(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
|
void |
convertNode(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
|
void |
convertNodes(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
|
protected void |
convertNodeTimer(org.dom4j.Element timerElement,
org.dom4j.Element jpdl4Element)
|
protected void |
convertNodeTimers(org.dom4j.Element nodeElement,
org.dom4j.Element jpdl4Element)
|
org.dom4j.Element |
convertSingleAction(org.dom4j.Element jpdl3NodeElement,
org.dom4j.Element jpdl4Element)
|
protected void |
convertSwimlanes(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
|
org.dom4j.Element |
convertTask(org.dom4j.Element taskElement,
org.dom4j.Element jpdlElement)
|
void |
convertTasks(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
|
protected void |
convertTaskTimer(org.dom4j.Element timerElement,
org.dom4j.Element jpdl4Element)
|
protected void |
convertTaskTimers(org.dom4j.Element taskElement,
org.dom4j.Element jdpl4Element)
|
java.util.List<VariableAccess> |
convertVariableAccesses(org.dom4j.Element element)
|
org.dom4j.Element |
createAction(org.dom4j.Element actionElement,
org.dom4j.Element jpdl4Element)
|
void |
createMailDelegation(java.lang.String template,
java.lang.String actors,
java.lang.String to,
java.lang.String subject,
java.lang.String text)
|
org.dom4j.Document |
getJpdl4Document()
|
java.lang.String |
getProperty(java.lang.String property,
org.dom4j.Element element)
|
protected org.dom4j.Element |
parseProcessDefinitionAttributes(org.dom4j.Element root)
|
org.dom4j.Document |
readAndConvert()
Call this method to convert the jpdl3 process. |
void |
resolveActionReferences()
|
void |
resolveTransitionDestination(org.dom4j.Element transitionElement,
org.dom4j.Element jpdl4Element)
|
void |
resolveTransitionDestinations()
|
void |
resolveTransitionDestinations(java.util.List<?> transitionElements,
org.dom4j.Element jpdl4Element)
|
void |
verifySwimlaneAssignments()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected org.xml.sax.InputSource inputSource
protected org.dom4j.Document jpdl3Document
protected java.util.List<Problem> problems
protected ProblemListener problemListener
protected org.dom4j.Document jpdl4Document
protected java.util.Collection<java.lang.Object[]> unresolvedTransitionDestinations
protected java.util.Collection<java.lang.Object[]> unresolvedActionReferences
protected java.util.Map<java.lang.String,org.dom4j.Element> nodeCollection
protected java.util.Map<java.lang.String,org.dom4j.Element> swimlanesCollection
| Constructor Detail |
|---|
public Jpdl3Converter(java.net.URL url)
public Jpdl3Converter(org.xml.sax.InputSource inputSource)
public Jpdl3Converter(java.io.Reader reader)
| Method Detail |
|---|
public void close()
throws java.io.IOException
java.io.IOExceptionpublic void addProblem(Problem problem)
addProblem in interface ProblemListenerpublic void addError(java.lang.String description)
public void addError(java.lang.String description,
java.lang.Throwable exception)
public void addWarning(java.lang.String description)
public org.dom4j.Document readAndConvert()
protected org.dom4j.Element parseProcessDefinitionAttributes(org.dom4j.Element root)
protected void convertSwimlanes(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
public void convertActions(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element,
java.lang.String eventType)
public void convertNodes(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
public void convertEvents(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
public void convertTasks(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
public org.dom4j.Element convertTask(org.dom4j.Element taskElement,
org.dom4j.Element jpdlElement)
protected void convertAssignmentDelegation(org.dom4j.Element jpdl3AssignmentElement,
org.dom4j.Element jpdl4Task)
public java.util.List<VariableAccess> convertVariableAccesses(org.dom4j.Element element)
public void convertNode(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
protected void convertNodeTimers(org.dom4j.Element nodeElement,
org.dom4j.Element jpdl4Element)
protected void convertNodeTimer(org.dom4j.Element timerElement,
org.dom4j.Element jpdl4Element)
protected void convertTaskTimers(org.dom4j.Element taskElement,
org.dom4j.Element jdpl4Element)
protected void convertTaskTimer(org.dom4j.Element timerElement,
org.dom4j.Element jpdl4Element)
public org.dom4j.Element convertSingleAction(org.dom4j.Element jpdl3NodeElement,
org.dom4j.Element jpdl4Element)
public org.dom4j.Element createAction(org.dom4j.Element actionElement,
org.dom4j.Element jpdl4Element)
protected void convertExceptionHandlers(org.dom4j.Element jpdl3Element,
org.dom4j.Element jpdl4Element)
public void addUnresolvedTransitionDestination(org.dom4j.Element nodeElement,
org.dom4j.Element jpdl4Element)
public void resolveTransitionDestinations()
public void resolveTransitionDestinations(java.util.List<?> transitionElements,
org.dom4j.Element jpdl4Element)
public void resolveTransitionDestination(org.dom4j.Element transitionElement,
org.dom4j.Element jpdl4Element)
public void addUnresolvedActionReference(org.dom4j.Element actionElemen)
public void resolveActionReferences()
public void verifySwimlaneAssignments()
public void createMailDelegation(java.lang.String template,
java.lang.String actors,
java.lang.String to,
java.lang.String subject,
java.lang.String text)
public java.lang.String getProperty(java.lang.String property,
org.dom4j.Element element)
public org.dom4j.Document getJpdl4Document()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||