Fork me on GitHub

Welcome to XMLBeam

An XML CRUD library for Java.

If you are new here, please read the introduction. Are you in a hurry? Read the the tutorials!

It's XML Data Projection

XMLBeam is a very small Java library located between your XML data and your application. You define your data accessing API by creating Java interfaces enriched with metadata. XMBeam was designed to keep your API and application code static, even when the XML structure changes. This approach works so well, that you can even use it to mimicry other APIs.

Above all XMLBeam is a handy XML tool with convenient features to create, modify, read or write XML data.

This is how it looks

Access XML data directly via XPath-annotated Java interfaces (called "Projections"):

<xml>
   <example>
      <content type="foo" >bar</content>
   </example>
</xml>
public interface Example {
 
    @XBRead("/xml/example/content")
    String getContent();
 
    @XBRead("/xml/example/content/@type")
    String getType();
 
}

Learn more.

Project status

2014-11-06

  • New release 1.4.1 with cool error handling feature: Let projection methods throw exceptions. See the release notes.

2014-10-13

2014-09-12

  • New release 1.3.0 with enhancements on Java 8 support and changes in type conversion defaults. See the release notes.

2014-05-17

  • New release 1.2.1 with new full XPath gaining update mode. See the release notes.

2014-04-28

  • New release 1.2.0 to ease handling of single quotes in XPaths. See the release notes.

2014-04-15

2014-04-14

2014-04-01

  • New release 1.1.2 with supercool automatic type conversion (see here).

2014-03-27

  • New release 1.1.1 with Java 8 support for projection behaviour.

2014-03-26

2014-03-06

  • Added section to the FAQ to explain how to use a different XPath implementation. (The same way can be be used to change the XML-Parser or DocumentBuilder.)

2014-02-21

2013-10-26

Over 6 months without a change, several productive usages without bug reports. Stable version 1.0 released in maven central repository.

2013-01-17

Snapshots are available in the sonatype snapshot repository. The I/O API has become more stable now. Preparing to have first release candidate soon.

2013-01-04

The project started in the end of 2012 and is currently still in the early publishing phase. Sources are hosted at Github, continuous integration is done by Jenkins at a private location. Snapshot and pre-release artifacts will be located at Sonatype soon. Until release of version 1.0, the XMLBeam API could keep changing. So the first deployment version to central repository will be 1.0.

Codeship Status