First, I am new in Xpath. I have found plenty of samples that queries if an element exists ,using Xpath. But I could not manage to implement the sample that I want. My xml is like:
<a>
<b>
<c>xxx</c>
<d>yyy</d>
</b>
</a>
<a>
<b>
<d>zzz</d>
</b>
</a>
And I only want the "a" items with both "c" and "d" exists. So I did this:
@XPath("a/b[boolean(c) and boolean(d)]")
private A a;
COuld someone please show me the right way to do it?
Thanks
Ali