BPEL Functions
This section talks about the important and commonly used functions related to BPEL. These are:
getLinkStatus()
getVariableData()
getVariableProperty()
getLinkStatus()
This function is used to return a Boolean value to indicate the status of a link. Links with positive status are evaluated to true
, links with negative status to false
. This function can only be used in join conditions. The linkName
argument must refer to the name of an incoming link for the activity associated with the join condition.
Syntax
bpws:getLinkStatus (‘linkName’)
Example
<switch name=”BestOfferSelect” joinCondition=”bpws:getLinkStatus( ‘AmericanAirlinesCallbackToBestOfferSelect’) and bpws:getLinkStatus( ‘DeltaAirlinesCallbackToBestOfferSelect’)” > ... </switch>
getVariableData()
This function is used to extract arbitrary values from variables.
Syntax
bpws:getVariableData (‘variableName’, ‘partName’?, ‘locationPath’?)
Example
bpws:getVariableData (‘InsuranceRequest’, ‘insuredPersonData’)
bpws:getVariableData (‘InsuranceRequest’, ‘insuredPersonData’, ‘/insuredPersonData/ins:Age’)
getVariableProperty()
This function is used to extract global property values from variables.
Syntax
bpws:getVariableProperty (‘variableName’, ‘propertyName’)
Example
bpws:getVariableProperty(‘TicketApproval’, ‘Class’)