在我的一个过程中,我使用REST调用(在APEX中)解析远程存储的XML文件,并尝试找出包含特定术语的节点.
这是文件的简化示例结构.此示例中的搜索词是"云":
<map id="12343">
<topic id="23498">
<title>Topic title</title>
<p id="24334"> some sample text with term 'cloud' </p>
<ul id = "34334">
<li id="38743">List item without the term </li>
<li id="38438">List item with term 'Cloud'</li>
</ul>
</topic>
<topic id="23498">
<title>Title for this topic</title>
<p id="24334"> some sample text with term 'cloud' </p>
<ul id = "34334">
<li id="38743">List item without the term </li>
<li id="38438">List item without term'</li>
</ul>
</topic>
<topic id="23498">
<title>Title for this topic with term 'CLOUD' in caps</title> …Run Code Online (Sandbox Code Playgroud)