The Java Tutorials have been written for JDK 8. Examples and practices described in this page don't take advantage of improvements introduced in later releases.
For more information about StAX, see:
W3C Recommendation Extensible Markup Language (XML) 1.0
JAXB specification on jcp.org: JSR-222 Java Architecture for XML Binding (JAXB)
W3C Recommendation Document Object Model
W3C Recommendation Namespaces in XML
For some useful articles about working with StAX, see:
Jeff Ryan, Does StAX Belong in Your XML Toolbox?
Elliott Rusty Harold, An Introduction to StAX