I have an xml document like this:
<root>
<device>
<v1>blah</v1>
</device>
</root>
I want to parse this document, but just the
<device>
<v1>blah</v1>
</device>
part. I want to ignore the root element. How can I unmarshal this with jaxb?
Assuming that your JAXB definition knows nothing about <root>, i.e. you can't just unmarshal the whole thing and look inside the resulting Root object: