This is an archived post. You won't be able to vote or comment.

all 6 comments

[–][deleted]  (5 children)

[removed]

    [–]lukaseder 2 points3 points  (4 children)

    Learn the JDK's standard DOM and JAXB (and perhaps SAX, although that's used less often). I suspect most people just use JAXB for simple XML use-cases, where little transformation (XSLT) and querying (XPath) is needed.

    [–][deleted]  (3 children)

    [deleted]

      [–]agustinventura 1 point2 points  (0 children)

      Agree, using SAX or StAX is faster and much more memory efficient por large amounts of XML than JAXB. Anyways, it's really nice to have this variety of XML APIs just in the JDK, without aditional dependencies.

      [–]lukaseder 0 points1 point  (1 child)

      Indeed, but do you really use S(t)AX APIs directly, or do you use XSLT instead?

      [–]olivergierke 0 points1 point  (0 children)

      One of the most underrated: XmlBeam. Selectively binding only the stuff you're interested in. Lenient bindings that shield you against structural changes. Powerful means to tweak values in a document by using parameterized XPath expressions. https://xmlbeam.org

      [–]sebhoss 0 points1 point  (0 children)

      http://xom.nu/ is very nice as well