Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
public < A extends XmlAdapter > A getAdapter(final Class < A > xmlAdapter)
public Node getNode(final Object node)
public void setAdapter(final XmlAdapter arg0)
public < A extends XmlAdapter > void setAdapter(final Class < A > arg0, final A arg1)

and

Code Block
*PP* *PC* public void marshal(final Object object, final XMLStreamWriter xmlStreamWriter) (dependency on Castor 1.3.3-SNAPSHOT) 
*PP* *PC* public void marshal(final Object object, final XMLEventWriter xmlEventWriter) (dependency on Castor 1.3.3-SNAPSHOT)

...

Code Block
public < A extends XmlAdapter > A getAdapter(final Class < A > arg0)
public ValidationEventHandler getEventHandler()
public Schema getSchema()
public UnmarshallerHandler getUnmarshallerHandler()
public void setAdapter(final XmlAdapter xmlAdapter)
public < A extends XmlAdapter > void setAdapter(final Class < A > type, final A xmlAdapter)
public void setEventHandler(final ValidationEventHandler validationEventHandler)
public void setSchema(final Schema schema)
public < T > JAXBElement < T > unmarshal(final Node node, final Class < T > type)

and

Code Block
*PP* *PC* public Object unmarshal(final XMLStreamReader xmlStreamReader) (dependency on Castor 1.3.3-SNAPSHOT)
*PP* *PC* public Object unmarshal(final XMLEventReader xmlEventReader) (dependency on Castor 1.3.3-SNAPSHOT)
*PP* *PC* public < T > JAXBElement < T > unmarshal(final XMLStreamReader xmlStreamReader, final Class < T > type) (dependency on Castor 1.3.3-SNAPSHOT)
*PP* *PC* public < T > JAXBElement < T > unmarshal(final XMLEventReader xmlEventReader, final Class < T > type) (dependency on Castor 1.3.3-SNAPSHOT)
*PP* *PC* public < T > JAXBElement < T > unmarshal(final Source node, final Class < T > type) (dependency on Castor 1.3.3-SNAPSHOT)

...

Code Block
public Validator createValidator() throws JAXBException
public <T> Binder<T> createBinder(final Class<T> domType)
public Binder<org.w3c.dom.Node> createBinder()
public void generateSchema(final SchemaOutputResolver schemaOutputResolver)

where PP means patch provided and PC means patch committed.

Besides that it seams that JAXBXmlNaming behaviour is incorrect for names written in pascal case for example Name is converted into lowercase name.
The JAXBXmlNaming#toXml should be revised.

...

I think a little bit of time should be spend on functional testing, and this might get quite tedious. Looking, for example, at the @XmlAttribute annotation, there's a lot of variants to test, requiring POJOs to be annotated slightly different for each test case. That would require us to write a lot of POJOs and wire them up accordingly in the test classes. Let's see whether we can agree on how to go about this (layout, package structures, ...).

The implementation

General Implementation issues

Marshaller:

Code Block

public void marshal(final Object object, final XMLStreamWriter xmlStreamWriter)
public void marshal(final Object object, final XMLEventWriter xmlEventWriter)

Unmarshaller:

Code Block

public Object unmarshal(final XMLStreamReader xmlStreamReader)
public Object unmarshal(final XMLEventReader xmlEventReader)
public < T > JAXBElement < T > unmarshal(final XMLStreamReader xmlStreamReader, final Class < T > type)
public < T > JAXBElement < T > unmarshal(final XMLEventReader xmlEventReader, final Class < T > type)
public < T > JAXBElement < T > unmarshal(final Source node, final Class < T > type)

...