public class JAXBUtils
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
JAXBUtils.CONSTRUCTION_TYPE |
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
DEFAULT_NAMESPACE_REMAP |
| Constructor and Description |
|---|
JAXBUtils() |
| Modifier and Type | Method and Description |
|---|---|
static javax.xml.bind.JAXBContext |
getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages)
Deprecated.
|
static javax.xml.bind.JAXBContext |
getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages,
java.lang.ClassLoader cacheKey)
Deprecated.
|
static javax.xml.bind.JAXBContext |
getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages,
javax.xml.ws.Holder<JAXBUtils.CONSTRUCTION_TYPE> constructionType,
boolean forceArrays,
java.lang.String key,
java.lang.ClassLoader cacheKey,
java.util.Map<java.lang.String,?> properties)
Get a JAXBContext for the class
Note: The contextPackage object is used by multiple threads.
|
static javax.xml.bind.JAXBContext |
getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages,
javax.xml.ws.Holder<JAXBUtils.CONSTRUCTION_TYPE> constructionType,
java.lang.String key) |
static javax.xml.bind.JAXBContext |
getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages,
javax.xml.ws.Holder<JAXBUtils.CONSTRUCTION_TYPE> constructionType,
java.lang.String key,
java.lang.ClassLoader cacheKey,
java.util.Map<java.lang.String,?> properties)
Get a JAXBContext for the class
Note: The contextPackage object is used by multiple threads.
|
static javax.xml.bind.JAXBIntrospector |
getJAXBIntrospector(javax.xml.bind.JAXBContext context)
get JAXB Introspector
|
static javax.xml.bind.Marshaller |
getJAXBMarshaller(javax.xml.bind.JAXBContext context)
Get JAXBMarshaller
|
static javax.xml.bind.Unmarshaller |
getJAXBUnmarshaller(javax.xml.bind.JAXBContext context)
Get the unmarshaller.
|
protected static java.util.List<java.lang.String> |
pruneDirectives(java.util.TreeSet<java.lang.String> contextPackages)
The contextPackages may declare overrides.
|
static void |
releaseJAXBIntrospector(javax.xml.bind.JAXBContext context,
javax.xml.bind.JAXBIntrospector introspector)
Release JAXBIntrospector Do not call this method if an exception occurred while using the
JAXBIntrospector.
|
static void |
releaseJAXBMarshaller(javax.xml.bind.JAXBContext context,
javax.xml.bind.Marshaller marshaller)
releaseJAXBMarshalller
Do not call this method if an exception occurred while using the
Marshaller.
|
static void |
releaseJAXBUnmarshaller(javax.xml.bind.JAXBContext context,
javax.xml.bind.Unmarshaller unmarshaller)
Release Unmarshaller Do not call this method if an exception occurred while using the
Unmarshaller.
|
public static javax.xml.bind.JAXBContext getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages)
throws javax.xml.bind.JAXBException
contextPackage - Setjavax.xml.bind.JAXBExceptionpublic static javax.xml.bind.JAXBContext getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages,
java.lang.ClassLoader cacheKey)
throws javax.xml.bind.JAXBException
contextPackage - SetcacheKey - ClassLoaderjavax.xml.bind.JAXBExceptionpublic static javax.xml.bind.JAXBContext getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages,
javax.xml.ws.Holder<JAXBUtils.CONSTRUCTION_TYPE> constructionType,
java.lang.String key)
throws javax.xml.bind.JAXBException
javax.xml.bind.JAXBExceptionpublic static javax.xml.bind.JAXBContext getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages,
javax.xml.ws.Holder<JAXBUtils.CONSTRUCTION_TYPE> constructionType,
java.lang.String key,
java.lang.ClassLoader cacheKey,
java.util.Map<java.lang.String,?> properties)
throws javax.xml.bind.JAXBException
contextPackage - SetcontructionType - (output value that indicates how the context was constructed)cacheKey - ClassLoaderjavax.xml.bind.JAXBExceptionpublic static javax.xml.bind.JAXBContext getJAXBContext(java.util.TreeSet<java.lang.String> contextPackages,
javax.xml.ws.Holder<JAXBUtils.CONSTRUCTION_TYPE> constructionType,
boolean forceArrays,
java.lang.String key,
java.lang.ClassLoader cacheKey,
java.util.Map<java.lang.String,?> properties)
throws javax.xml.bind.JAXBException
contextPackage - SetcontructionType - (output value that indicates how the context was constructed)forceArrays - (forces the returned JAXBContext to include the array types)cacheKey - ClassLoaderjavax.xml.bind.JAXBExceptionprotected static java.util.List<java.lang.String> pruneDirectives(java.util.TreeSet<java.lang.String> contextPackages)
contextPackages - public static javax.xml.bind.Unmarshaller getJAXBUnmarshaller(javax.xml.bind.JAXBContext context)
throws javax.xml.bind.JAXBException
context - JAXBContextjavax.xml.bind.JAXBExceptionpublic static void releaseJAXBUnmarshaller(javax.xml.bind.JAXBContext context,
javax.xml.bind.Unmarshaller unmarshaller)
context - JAXBContextunmarshaller - Unmarshallerpublic static javax.xml.bind.Marshaller getJAXBMarshaller(javax.xml.bind.JAXBContext context)
throws javax.xml.bind.JAXBException
context - JAXBContextjavax.xml.bind.JAXBExceptionpublic static void releaseJAXBMarshaller(javax.xml.bind.JAXBContext context,
javax.xml.bind.Marshaller marshaller)
context - JAXBContextmarshaller - Marshallerpublic static javax.xml.bind.JAXBIntrospector getJAXBIntrospector(javax.xml.bind.JAXBContext context)
throws javax.xml.bind.JAXBException
context - JAXBContextjavax.xml.bind.JAXBExceptionpublic static void releaseJAXBIntrospector(javax.xml.bind.JAXBContext context,
javax.xml.bind.JAXBIntrospector introspector)
context - JAXBContextintrospector - JAXBIntrospectorCopyright © 2004-2015 The Apache Software Foundation. All Rights Reserved.