Package org.apache.xmlbeans

Provides classes for XML Beans schema, infoset, xpath, and xquery handling.

The XML Beans API is designed to work with the XML Beans schema compiler. The schema compiler produces XML Bean classes that extend and interact with the basic XML Bean classes and interfaces in this package. It is also possible to use XML Beans without the schema compiler to manipulate and validate XML in a late-bound way (with no types, or with runtime-loaded types only).

This package contains:

  1. All the built-in XML Bean classes such as XmlObject, XmlAnySimpleType, and XmlInt (one for each of the 46 built-in XML Schema types).
  2. Support for full XML infoset, XPath, and XQuery (via XmlCursor, XmlObject.selectPath(java.lang.String) and related methods).
  3. Support for computation using XML Schema data types (via datatype classes such as GDuration).
  4. Support for working with XML Schema type metadata itself (via SchemaType, SchemaTypeSystem, and related classes).

The place to begin when working with the XML Beans API is the following fundamental classes:

  1. XmlObject is the base class for all XML Beans.
  2. org.apache.xmlbeans.XmlObject.Factory is used to load and create XML Bean instances. Each XML Bean class has its own nested factory class.
  3. XmlCursor is an efficient treewalking API for the full XML infoset.
  4. SchemaType is the type metadata interface for XML Schema types
  5. XmlBeans provides a collection of utility functions.