Class BpmnParseUtil
- java.lang.Object
-
- org.camunda.bpm.engine.impl.bpmn.parser.BpmnParseUtil
-
public final class BpmnParseUtil extends Object
Helper methods to reused for common parsing tasks.
-
-
Constructor Summary
Constructors Constructor Description BpmnParseUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Element
findCamundaExtensionElement(Element element, String extensionElementName)
Returns the camunda extension element in the camunda namespace and the given name.protected static ExpressionManager
getExpressionManager()
static Map<String,String>
parseCamundaExtensionProperties(Element element)
static void
parseCamundaInputParameters(Element inputOutputElement, IoMapping ioMapping)
Parses all input parameters of an input output element and adds them to theIoMapping
.static void
parseCamundaOutputParameters(Element inputOutputElement, IoMapping ioMapping)
Parses all output parameters of an input output element and adds them to theIoMapping
.static ExecutableScript
parseCamundaScript(Element scriptElement)
Parses a camunda script element.static IoMapping
parseInputOutput(Element element)
Returns theIoMapping
of an element.static void
parseInputParameterElement(Element inputParameterElement, IoMapping ioMapping)
Parses a input parameter and adds it to theIoMapping
.protected static ParameterValueProvider
parseNestedParamValueProvider(Element element)
static void
parseOutputParameterElement(Element outputParameterElement, IoMapping ioMapping)
Parses a output parameter and adds it to theIoMapping
.protected static ParameterValueProvider
parseParamValueProvider(Element parameterElement)
-
-
-
Method Detail
-
findCamundaExtensionElement
public static Element findCamundaExtensionElement(Element element, String extensionElementName)
Returns the camunda extension element in the camunda namespace and the given name.- Parameters:
element
- the parent element of the extension elementextensionElementName
- the name of the extension element to find- Returns:
- the extension element or null if not found
-
parseInputOutput
public static IoMapping parseInputOutput(Element element)
Returns theIoMapping
of an element.- Parameters:
element
- the element to parse- Returns:
- the input output mapping or null if non defined
- Throws:
BpmnParseException
- if a input/output parameter element is malformed
-
parseCamundaInputParameters
public static void parseCamundaInputParameters(Element inputOutputElement, IoMapping ioMapping)
Parses all input parameters of an input output element and adds them to theIoMapping
.- Parameters:
inputOutputElement
- the input output element to processioMapping
- the input output mapping to add input parameters to- Throws:
BpmnParseException
- if a input parameter element is malformed
-
parseCamundaOutputParameters
public static void parseCamundaOutputParameters(Element inputOutputElement, IoMapping ioMapping)
Parses all output parameters of an input output element and adds them to theIoMapping
.- Parameters:
inputOutputElement
- the input output element to processioMapping
- the input output mapping to add input parameters to- Throws:
BpmnParseException
- if a output parameter element is malformed
-
parseInputParameterElement
public static void parseInputParameterElement(Element inputParameterElement, IoMapping ioMapping)
Parses a input parameter and adds it to theIoMapping
.- Parameters:
inputParameterElement
- the input parameter elementioMapping
- the mapping to add the element- Throws:
BpmnParseException
- if the input parameter element is malformed
-
parseOutputParameterElement
public static void parseOutputParameterElement(Element outputParameterElement, IoMapping ioMapping)
Parses a output parameter and adds it to theIoMapping
.- Parameters:
outputParameterElement
- the output parameter elementioMapping
- the mapping to add the element- Throws:
BpmnParseException
- if the output parameter element is malformed
-
parseNestedParamValueProvider
protected static ParameterValueProvider parseNestedParamValueProvider(Element element)
- Throws:
BpmnParseException
- if the parameter is invalid
-
parseParamValueProvider
protected static ParameterValueProvider parseParamValueProvider(Element parameterElement)
- Throws:
BpmnParseException
- if the parameter is invalid
-
parseCamundaScript
public static ExecutableScript parseCamundaScript(Element scriptElement)
Parses a camunda script element.- Parameters:
scriptElement
- the script element ot parse- Returns:
- the generated executable script
- Throws:
BpmnParseException
- if the a attribute is missing or the script cannot be processed
-
parseCamundaExtensionProperties
public static Map<String,String> parseCamundaExtensionProperties(Element element)
-
getExpressionManager
protected static ExpressionManager getExpressionManager()
-
-