javax.xml.bind.util

Class JAXBResult


public class JAXBResult
extends SAXResult

Utility class that allows to catch the result of a stylesheet transformation in a JAXB object.
Author:
JSR-31
Since:
JAXB1.0

Constructor Summary

JAXBResult(JAXBContext pContext)
Creates a new instance of JAXBResult.
JAXBResult(Unmarshaller pUnmarshaller)
Creates a new instance of JAXBResult.

Method Summary

Object
getResult()
Returns the result of a previous transformation.

Constructor Details

JAXBResult

public JAXBResult(JAXBContext pContext)
            throws JAXBException
Creates a new instance of JAXBResult. The instance will use the specified JAXBContext to create an Unmarshaller.

JAXBResult

public JAXBResult(Unmarshaller pUnmarshaller)
            throws JAXBException
Creates a new instance of JAXBResult. The instance will use the given Unmarshaller to create a org.xml.sax.ContentHandler.

In most cases you will use the constructor taking a JAXBContext as input. This additional constructor is required, if you want to configure the Unmarshaller.

Parameters:
pUnmarshaller - The Unmarshaller that may be queried for an UnmarshallerHandler.

Method Details

getResult

public Object getResult()
            throws JAXBException
Returns the result of a previous transformation.