【问题标题】:How to insert/append new node entries to an element list in WSO2 BPEL?如何将新节点条目插入/附加到 WSO2 BPEL 中的元素列表?
【发布时间】:2016-05-13 09:07:30
【问题描述】:

使用 wso2bps-3.5.1

我已搜索但未找到有关如何在 WSO2 BPS BPEL 中动态填充元素列表的任何信息。

我的用例是遍历 Invoke 活动给出的列表以生成另一个元素列表。我正在使用 Foreach 活动进行循环,在其中我在循环内创建一个局部范围变量来构建新的列表条目。但是,我不知道如何将此节点插入到新列表中。有内置函数吗?

任何示例都将不胜感激。

【问题讨论】:

    标签: wso2 bpel wso2bps


    【解决方案1】:

    我自己解决了这个问题:

        xmlns:test="http://ode/bpel/unit-test.wsdl"
        queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
        expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
    ...
    <bpel:assign validate="no" name="Assign">
            <bpel:copy>
                <bpel:from>
                    <![CDATA[ode:insert-after($closeAccountResponse.closeAccountResponsePart/xclac:accountConnections, $closeAccountResponse.closeAccountResponsePart/xclac:accountConnections/xcom:accountConnection, $record)]]>
                </bpel:from>
                <bpel:to part="closeAccountResponsePart" variable="closeAccountResponse">
                    <bpel:query><![CDATA[xclac:accountConnections]]></bpel:query>
                </bpel:to>
            </bpel:copy>
        </bpel:assign>
    

    【讨论】:

    • 我这样做了,但出现错误“找不到前缀“ode”的命名空间”。我该如何解决这个问题???
    猜你喜欢
    • 1970-01-01
    • 2013-12-03
    • 2013-03-26
    • 1970-01-01
    • 2018-02-08
    • 1970-01-01
    • 1970-01-01
    • 2013-02-08
    • 1970-01-01
    相关资源
    最近更新 更多