Package org.apache.synapse.config.xml
Class ValueFactory
- java.lang.Object
-
- org.apache.synapse.config.xml.ValueFactory
-
-
Constructor Summary
Constructors Constructor Description ValueFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SynapseJsonPath
createSynJsonPath(String key)
Create synapse jsonpath expressionSynapseXPath
createSynXpath(org.apache.axiom.om.OMElement elem, String key)
Create synapse xpath expression {} type user input is used to create real xpath expressionValue
createTextValue(org.apache.axiom.om.OMElement elem)
Create a key instanceValue
createValue(String name, org.apache.axiom.om.OMElement elem)
Create a key instanceboolean
isDynamicKey(String keyValue)
Validate the given key to identify whether it is static or dynamic key If the key is in the {} format then it is dynamic key(XPath) Otherwise just a static key
-
-
-
Method Detail
-
createValue
public Value createValue(String name, org.apache.axiom.om.OMElement elem)
Create a key instance- Parameters:
elem
- OMElement- Returns:
- Key
-
createTextValue
public Value createTextValue(org.apache.axiom.om.OMElement elem)
Create a key instance- Parameters:
elem
- OMElement- Returns:
- Key
-
isDynamicKey
public boolean isDynamicKey(String keyValue)
Validate the given key to identify whether it is static or dynamic key If the key is in the {} format then it is dynamic key(XPath) Otherwise just a static key- Parameters:
keyValue
- string to validate as a key- Returns:
- isDynamicKey representing key type
-
createSynXpath
public SynapseXPath createSynXpath(org.apache.axiom.om.OMElement elem, String key)
Create synapse xpath expression {} type user input is used to create real xpath expression- Parameters:
elem
- the elementkey
- xpath expression with {}- Returns:
- SynapseXpath
-
createSynJsonPath
public SynapseJsonPath createSynJsonPath(String key)
Create synapse jsonpath expression- Parameters:
key
- jsonpath expression eg: json-eval($.info)- Returns:
- SynapseJsonPath
-
-