fho fho - 8 months ago 28
Java Question

Prior knowledge on attributes?

I am currently looking to integrate

in to our project (as a replacement of a Stax based system).

Our xml files are mostly structured like this:

<entry1 timestamp="0"/>
<entry2 timestamp="1"/>
<entry1 timestamp="2"/>
<entry2 timestamp="3"/>

Is there a way to get
to recognize that the timestamps are strictly ordered and to abort a xpath query like
/header/*[@timestamp < 2]


not that i'm aware of. But you could select the last node:

/header/*[@timestamp = 2]

and then use selectPrecedingNode()