#Jx the JAXB JSON-XML Binding Model and XJC Plugin#
###What is it?###
Jx is an annotation framework that's inspired by JXON.
Jx cuts out a lot of JXON's concerns by relying on the well established transformations and bindings that exist in JAXB.
###Cool... so what's it do?###
Jx allows you to annotate an XML schema document using JAXB binding customizations. These annotations are used to help direct the processing and generation of JSON structural renderings derived from the XSD in a predictable, type-safe manner.
Jx makes it trivial to support XML and JSON with ONE schema contract (the XSD). Jx will automatically map both XML and JSON representations of the schema to the underlying Java JAXB classes.
##The Features##
###Code Features###
-
Streaming JAXB to JSON generator
-
Streaming JSON to JAXB mapper
-
Mapping framework that understands JAXB annotations
-
Extensible binding strategy framework
###Jx XJC XSD Annotation Framework###
TODO
###Jx XSD Annotations###
-
<jx:bind strategy="[jx-strategy-name]" />
Binds a JSON binding annotation to the XSD type or Element. The strategy selects the desired behavior from registered binding strategies. Any number of attributes may follow the strategy attribute and be treated as strategy arguments.
##The Project Structure##
This project has three maven POM files specified in it.
###net.jps:jx (/pom.xml)###
This is the parent POM file that controls things like dependency versions and common project information bits and pieces.
###net.jps:jx-xjc (/jx-xjc/pom.xml)###
This is the XJC plugin portion of JX that allows users to use JX and XJC to generate runtime persistent code anntations to better communicate binding intent.
###net.jps:jx-xjc-test (/jx-xjc-test/pom.xml)###
This is a project dedicated to help test the generation rules outlined in the XJC plugin.
##The Examples##
###The XML###
A Jx annotated example schema taken from the Repose project
###The Javas###
An example of how to write out JSON content from a JAXB object graph
An example of how to bind JSON content to a JAXB object graph
##That Legal Thing...##
This software library is realease to you under the Apache License, Version 2.0. See LICENSE for more information.