Rendering elements can have, multiple xpath functions [1].
For Eg:
<htd:rendering type="input">
<wso2:html><![CDATA[
<table>
<tr>
<td>Customer Name</td>
<td>*htd:concat(getInput("ClaimApprovalRequest")/cust/firstname, " " , *
*getInput("ClaimApprovalRequest")/cust/lastname)*</td>
</tr>
<tr>
<td>Amount</td>
<td>*htd:getInput("ClaimApprovalRequest")/amount*</td>
</tr>
<tr>
<td>Country</td>
<td>*$country_code$*</td>
</tr>
</table>
]]></wso2:html>
</htd:rendering>
Problems when evaluating above rendering element are,
- Different xpath functions have different syntax. eg: concat ends with
")" while getInput() ends with a "node name". Finding start and end of a
xpath expression is not easy.
- It is hard to figure out use of multiple xpath functions like concat,
except, union, avg, etc.
- Performance ?.
One solution is wrap xpath with "$" symbol, similar to presentation
params.
Eg:
$*htd:getInput("ClaimApprovalRequest")/amount$*
WDYT ?
[1] -
http://docs.oasis-open.org/bpel4people/ws-humantask-1.1-spec-cs-01.html#_Toc151798575
( htd - "http://docs.oasis-open.org/ns/bpel4people/ws-humantask/200803" )
Thanks,
Hasitha.
--
Hasitha Aravinda,
Software Engineer,
WSO2 Inc.
Email: [email protected]
Mobile: +94 71 8 210 200
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev