blob: 8b9fac4c98a9cd4cca567917682331970b993379 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<title>JAXBContext</title>
<link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="JAXBContext";
}
}
catch(err) {
}
//-->
var methods = {"i0":10,"i1":10,"i2":10,"i3":6,"i4":6,"i5":38,"i6":10,"i7":9,"i8":9,"i9":9,"i10":9,"i11":9};
var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"],8:["t4","Concrete Methods"],32:["t6","Deprecated Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../index-all.html">Index</a></li>
<li><a href="../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../jakarta/xml/bind/JAXB.html" title="class in jakarta.xml.bind"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../jakarta/xml/bind/JAXBContextFactory.html" title="interface in jakarta.xml.bind"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../index.html?jakarta/xml/bind/JAXBContext.html" target="_top">Frames</a></li>
<li><a href="JAXBContext.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field.summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field.detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">jakarta.xml.bind</div>
<h2 title="Class JAXBContext" class="title">Class JAXBContext</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li>java.lang.Object</li>
<li>
<ul class="inheritance">
<li>jakarta.xml.bind.JAXBContext</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<hr>
<br>
<pre>public abstract class <span class="typeNameLabel">JAXBContext</span>
extends java.lang.Object</pre>
<div class="block">The <code>JAXBContext</code> class provides the client's entry point to the
JAXB API. It provides an abstraction for managing the XML/Java binding
information necessary to implement the JAXB binding framework operations:
unmarshal, marshal and validate.
<p>A client application normally obtains new instances of this class using
one of these two styles for newInstance methods, although there are other
specialized forms of the method available:
<ul>
<li><a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.String-java.lang.ClassLoader-"><code>JAXBContext.newInstance( "com.acme.foo:com.acme.bar" )</code></a> <br>
The JAXBContext instance is initialized from a list of colon
separated Java package names. Each java package contains
JAXB mapped classes, schema-derived classes and/or user annotated
classes. Additionally, the java package may contain JAXB package annotations
that must be processed. (see JLS, Section 7.4.1 "Named Packages").
</li>
<li><a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.Class...-"><code>JAXBContext.newInstance( com.acme.foo.Foo.class )</code></a> <br>
The JAXBContext instance is initialized with class(es)
passed as parameter(s) and classes that are statically reachable from
these class(es). See <a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.Class...-"><code>newInstance(Class...)</code></a> for details.
</li>
</ul>
<p><i>
The following JAXB 1.0 requirement is only required for schema to
java interface/implementation binding. It does not apply to JAXB annotated
classes. JAXB Providers must generate a <code>jaxb.properties</code> file in
each package containing schema derived classes. The property file must
contain a property named <code>jakarta.xml.bind.context.factory</code> whose
value is the name of the class that implements the <code>createContext</code>
APIs.</i>
<p><i>
The class supplied by the provider does not have to be assignable to
<code>jakarta.xml.bind.JAXBContext</code>, it simply has to provide a class that
implements the <code>createContext</code> APIs.</i>
<p><i>
In addition, the provider must call the
<a href="../../../jakarta/xml/bind/DatatypeConverter.html#setDatatypeConverter-jakarta.xml.bind.DatatypeConverterInterface-"><code>DatatypeConverter.setDatatypeConverter</code></a> api prior to any client
invocations of the marshal and unmarshal methods. This is necessary to
configure the datatype converter that will be used during these operations.</i>
<a id="Unmarshalling"></a>
<h2>Unmarshalling</h2>
<p>
The <a href="../../../jakarta/xml/bind/Unmarshaller.html" title="interface in jakarta.xml.bind"><code>Unmarshaller</code></a> class provides the client application the ability
to convert XML data into a tree of Java content objects.
The unmarshal method allows for
any global XML element declared in the schema to be unmarshalled as
the root of an instance document.
Additionally, the unmarshal method allows for an unrecognized root element that
has an xsi:type attribute's value that references a type definition declared in
the schema to be unmarshalled as the root of an instance document.
The <code>JAXBContext</code> object
allows the merging of global elements and type definitions across a set of schemas (listed
in the <code>contextPath</code>). Since each schema in the schema set can belong
to distinct namespaces, the unification of schemas to an unmarshalling
context must be namespace independent. This means that a client
application is able to unmarshal XML documents that are instances of
any of the schemas listed in the <code>contextPath</code>. For example:
<pre>
JAXBContext jc = JAXBContext.newInstance( "com.acme.foo:com.acme.bar" );
Unmarshaller u = jc.createUnmarshaller();
FooObject fooObj = (FooObject)u.unmarshal( new File( "foo.xml" ) ); // ok
BarObject barObj = (BarObject)u.unmarshal( new File( "bar.xml" ) ); // ok
BazObject bazObj = (BazObject)u.unmarshal( new File( "baz.xml" ) ); // error, "com.acme.baz" not in contextPath
</pre>
<p>
The client application may also generate Java content trees explicitly rather
than unmarshalling existing XML data. For all JAXB-annotated value classes,
an application can create content using constructors.
For schema-derived interface/implementation classes and for the
creation of elements that are not bound to a JAXB-annotated
class, an application needs to have access and knowledge about each of
the schema derived <code>ObjectFactory</code> classes that exist in each of
java packages contained in the <code>contextPath</code>. For each schema
derived java class, there is a static factory method that produces objects
of that type. For example,
assume that after compiling a schema, you have a package <code>com.acme.foo</code>
that contains a schema derived interface named <code>PurchaseOrder</code>. In
order to create objects of that type, the client application would use the
factory method like this:
<pre>
com.acme.foo.PurchaseOrder po =
com.acme.foo.ObjectFactory.createPurchaseOrder();
</pre>
<p>
Once the client application has an instance of the the schema derived object,
it can use the mutator methods to set content on it.
<p>
For more information on the generated <code>ObjectFactory</code> classes, see
Section 4.2 <i>Java Package</i> of the specification.
<p>
<i>The provider must generate a class in each
package that contains all of the necessary object factory methods for that
package named ObjectFactory as well as the static
<code>newInstance( javaContentInterface )</code> method</i>
<h3>Marshalling</h3>
<p>
The <a href="../../../jakarta/xml/bind/Marshaller.html" title="interface in jakarta.xml.bind"><code>Marshaller</code></a> class provides the client application the ability
to convert a Java content tree back into XML data. There is no difference
between marshalling a content tree that is created manually using the factory
methods and marshalling a content tree that is the result an <code>unmarshal</code>
operation. Clients can marshal a java content tree back to XML data
to a <code>java.io.OutputStream</code> or a <code>java.io.Writer</code>. The
marshalling process can alternatively produce SAX2 event streams to a
registered <code>ContentHandler</code> or produce a DOM Node object.
Client applications have control over the output encoding as well as
whether or not to marshal the XML data as a complete document or
as a fragment.
<p>
Here is a simple example that unmarshals an XML document and then marshals
it back out:
<pre>
JAXBContext jc = JAXBContext.newInstance( "com.acme.foo" );
// unmarshal from foo.xml
Unmarshaller u = jc.createUnmarshaller();
FooObject fooObj = (FooObject)u.unmarshal( new File( "foo.xml" ) );
// marshal to System.out
Marshaller m = jc.createMarshaller();
m.marshal( fooObj, System.out );
</pre>
<h3>Validation</h3>
<p>
Validation has been changed significantly since JAXB 1.0. The <a href="../../../jakarta/xml/bind/Validator.html" title="interface in jakarta.xml.bind"><code>Validator</code></a>
class has been deprecated and made optional. This means that you are advised
not to use this class and, in fact, it may not even be available depending on
your JAXB provider. JAXB 1.0 client applications that rely on <code>Validator</code>
will still work properly when deployed with the JAXB 1.0 runtime system.
In JAXB 2.0, the <a href="../../../jakarta/xml/bind/Unmarshaller.html" title="interface in jakarta.xml.bind"><code>Unmarshaller</code></a> has included convenince methods that expose
the JAXP 1.3 <code>javax.xml.validation</code> framework. Please refer to the
<a href="../../../jakarta/xml/bind/Unmarshaller.html#setSchema-javax.xml.validation.Schema-"><code>Unmarshaller.setSchema(javax.xml.validation.Schema)</code></a> API for more
information.
<h3>JAXB Runtime Binding Framework Compatibility</h3>
<p>
The following JAXB 1.0 restriction only applies to binding schema to
interfaces/implementation classes.
Since this binding does not require a common runtime system, a JAXB
client application must not attempt to mix runtime objects (<code>JAXBContext,
Marshaller</code>, etc. ) from different providers. This does not
mean that the client application isn't portable, it simply means that a
client has to use a runtime system provided by the same provider that was
used to compile the schema.
<h3>Discovery of JAXB implementation</h3>
<p>
To create an instance of <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind"><code>JAXBContext</code></a>, one of <code>JAXBContext.newInstance(...)</code> methods is invoked. After
JAX-B implementation is discovered, call is delegated to appropriate provider's method <code>createContext(...)</code>
passing parameters from the original call.
<p>
JAX-B implementation discovery happens each time <code>JAXBContext.newInstance</code> is invoked. If there is no user
specific configuration provided, default JAX-B provider must be returned.
<p>
Implementation discovery consists of following steps:
<ol>
<li>
Packages/classes explicitly passed in to the <a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.String-"><code>newInstance(java.lang.String)</code></a> method are processed in the order they are
specified, until <code>jaxb.properties</code> file is looked up in its package, by using the associated classloader &mdash;
this is <code>the owner class loader</code> for a <code>Class</code> argument, and for a package
the specified <code>ClassLoader</code>.
<p>
If such a resource is discovered, it is <code>loaded</code> as a property file, and
the value of the <a href="../../../jakarta/xml/bind/JAXBContext.html#JAXB_CONTEXT_FACTORY"><code>JAXB_CONTEXT_FACTORY</code></a> key will be assumed to be the provider factory class. If no value
found, <code>"jakarta.xml.bind.context.factory"</code> is used as a key for backwards compatibility reasons. This class is
then loaded by the associated class loader discussed above.
<p>
This phase of the look up allows some packages to force the use of a certain JAXB implementation.
(For example, perhaps the schema compiler has generated some vendor extension in the code.)
<p>
This configuration method is deprecated.
<li>
If the system property <a href="../../../jakarta/xml/bind/JAXBContext.html#JAXB_CONTEXT_FACTORY"><code>JAXB_CONTEXT_FACTORY</code></a> exists, then its value is assumed to be the provider
factory class. If no such property exists, properties <code>"jakarta.xml.bind.context.factory"</code> and
<code>"jakarta.xml.bind.JAXBContext"</code> are checked too (in this order), for backwards compatibility reasons. This phase
of the look up enables per-JVM override of the JAXB implementation.
<li>
Provider of <a href="../../../jakarta/xml/bind/JAXBContextFactory.html" title="interface in jakarta.xml.bind"><code>JAXBContextFactory</code></a> is loaded using the service-provider loading
facilities, defined by the <code>ServiceLoader</code> class, to attempt
to locate and load an implementation of the service using the default loading mechanism: the service-provider loading facility
will use the current thread's context class loader
to attempt to load the context factory. If the context class loader is null, the
system class loader will be used.
<br>
In case of <code>service
configuration error</code> a <a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind"><code>JAXBException</code></a> will be thrown.
<li>
Look for resource <code>/META-INF/services/jakarta.xml.bind.JAXBContext</code> using provided class loader.
Methods without class loader parameter use <code>Thread.currentThread().getContextClassLoader()</code>.
If such a resource exists, its content is assumed to be the provider factory class.
This configuration method is deprecated.
<li>
Finally, if all the steps above fail, then the rest of the look up is unspecified. That said,
the recommended behavior is to simply look for some hard-coded platform default JAXB implementation.
This phase of the look up is so that Java SE can have its own JAXB implementation as the last resort.
</ol>
<p>
Once the provider factory class is discovered, context creation is delegated to one of its
<code>createContext(...)</code> methods.
For backward compatibility reasons, there are two ways how to implement provider factory class:
<ol>
<li>the class is implementation of <a href="../../../jakarta/xml/bind/JAXBContextFactory.html" title="interface in jakarta.xml.bind"><code>JAXBContextFactory</code></a>. It must also implement no-arg
constructor. If discovered in other step then 3, new instance using no-arg constructor is created first.
After that, appropriate instance method is invoked on this instance.
<li>the class is not implementation of interface above and then it is mandated to implement the following
static method signatures:
<pre>
public static JAXBContext createContext(
String contextPath,
ClassLoader classLoader,
Map&lt;String,Object&gt; properties ) throws JAXBException
public static JAXBContext createContext(
Class[] classes,
Map&lt;String,Object&gt; properties ) throws JAXBException
</pre>
In this scenario, appropriate static method is used instead of instance method. This approach is incompatible
with <code>ServiceLoader</code> so it can't be used with step 3.
</ol>
<p>
There is no difference in behavior of given method <code>createContext(...)</code> regardless of whether it uses approach
1 (JAXBContextFactory) or 2 (no interface, static methods).</div>
<dl>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.6, JAXB 1.0</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../jakarta/xml/bind/Marshaller.html" title="interface in jakarta.xml.bind"><code>Marshaller</code></a>,
<a href="../../../jakarta/xml/bind/Unmarshaller.html" title="interface in jakarta.xml.bind"><code>Unmarshaller</code></a>,
<a href="http://docs.oracle.com/javase/specs/jls/se7/html/jls-7.html#jls-7.4.1">S 7.4.1 "Named Packages"
in Java Language Specification</a></dd>
</dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== FIELD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="field.summary">
<!-- -->
</a>
<h3>Field Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
<caption><span>Fields</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Field and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static java.lang.String</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#JAXB_CONTEXT_FACTORY">JAXB_CONTEXT_FACTORY</a></span></code>
<div class="block">The name of the property that contains the name of the class capable
of creating new <code>JAXBContext</code> objects.</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier</th>
<th class="colLast" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected </code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#JAXBContext--">JAXBContext</a></span>()</code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t6" class="tableTab"><span><a href="javascript:show(32);">Deprecated Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code><a href="../../../jakarta/xml/bind/Binder.html" title="class in jakarta.xml.bind">Binder</a>&lt;org.w3c.dom.Node&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#createBinder--">createBinder</a></span>()</code>
<div class="block">Creates a <code>Binder</code> for W3C DOM.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>&lt;T&gt;&nbsp;<a href="../../../jakarta/xml/bind/Binder.html" title="class in jakarta.xml.bind">Binder</a>&lt;T&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#createBinder-java.lang.Class-">createBinder</a></span>(java.lang.Class&lt;T&gt;&nbsp;domType)</code>
<div class="block">Creates a <code>Binder</code> object that can be used for
associative/in-place unmarshalling/marshalling.</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code><a href="../../../jakarta/xml/bind/JAXBIntrospector.html" title="class in jakarta.xml.bind">JAXBIntrospector</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#createJAXBIntrospector--">createJAXBIntrospector</a></span>()</code>
<div class="block">Creates a <code>JAXBIntrospector</code> object that can be used to
introspect JAXB objects.</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code>abstract <a href="../../../jakarta/xml/bind/Marshaller.html" title="interface in jakarta.xml.bind">Marshaller</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#createMarshaller--">createMarshaller</a></span>()</code>
<div class="block">Create a <code>Marshaller</code> object that can be used to convert a
java content tree into XML data.</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code>abstract <a href="../../../jakarta/xml/bind/Unmarshaller.html" title="interface in jakarta.xml.bind">Unmarshaller</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#createUnmarshaller--">createUnmarshaller</a></span>()</code>
<div class="block">Create an <code>Unmarshaller</code> object that can be used to convert XML
data into a java content tree.</div>
</td>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><code>abstract <a href="../../../jakarta/xml/bind/Validator.html" title="interface in jakarta.xml.bind">Validator</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#createValidator--">createValidator</a></span>()</code>
<div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;
<div class="block"><span class="deprecationComment">since JAXB2.0</span></div>
</div>
</td>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#generateSchema-jakarta.xml.bind.SchemaOutputResolver-">generateSchema</a></span>(<a href="../../../jakarta/xml/bind/SchemaOutputResolver.html" title="class in jakarta.xml.bind">SchemaOutputResolver</a>&nbsp;outputResolver)</code>
<div class="block">Generates the schema documents for this context.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code>static <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.Class...-">newInstance</a></span>(java.lang.Class&lt;?&gt;...&nbsp;classesToBeBound)</code>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.</div>
</td>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><code>static <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.Class:A-java.util.Map-">newInstance</a></span>(java.lang.Class&lt;?&gt;[]&nbsp;classesToBeBound,
java.util.Map&lt;java.lang.String,?&gt;&nbsp;properties)</code>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.</div>
</td>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><code>static <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.String-">newInstance</a></span>(java.lang.String&nbsp;contextPath)</code>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.</div>
</td>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><code>static <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.String-java.lang.ClassLoader-">newInstance</a></span>(java.lang.String&nbsp;contextPath,
java.lang.ClassLoader&nbsp;classLoader)</code>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.</div>
</td>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><code>static <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.String-java.lang.ClassLoader-java.util.Map-">newInstance</a></span>(java.lang.String&nbsp;contextPath,
java.lang.ClassLoader&nbsp;classLoader,
java.util.Map&lt;java.lang.String,?&gt;&nbsp;properties)</code>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.Object</h3>
<code>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ FIELD DETAIL =========== -->
<ul class="blockList">
<li class="blockList"><a name="field.detail">
<!-- -->
</a>
<h3>Field Detail</h3>
<a name="JAXB_CONTEXT_FACTORY">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>JAXB_CONTEXT_FACTORY</h4>
<pre>public static final&nbsp;java.lang.String JAXB_CONTEXT_FACTORY</pre>
<div class="block">The name of the property that contains the name of the class capable
of creating new <code>JAXBContext</code> objects.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../constant-values.html#jakarta.xml.bind.JAXBContext.JAXB_CONTEXT_FACTORY">Constant Field Values</a></dd>
</dl>
</li>
</ul>
</li>
</ul>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a name="JAXBContext--">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>JAXBContext</h4>
<pre>protected&nbsp;JAXBContext()</pre>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="newInstance-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>newInstance</h4>
<pre>public static&nbsp;<a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a>&nbsp;newInstance(java.lang.String&nbsp;contextPath)
throws <a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></pre>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.
<p>
This is a convenience method to invoke the
<a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.String-java.lang.ClassLoader-"><code>newInstance(String,ClassLoader)</code></a> method with
the context class loader of the current thread.</div>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></code> - if an error was encountered while creating the
<code>JAXBContext</code> such as
<ol>
<li>failure to locate either ObjectFactory.class or jaxb.index in the packages</li>
<li>an ambiguity among global elements contained in the contextPath</li>
<li>failure to locate a value for the context factory provider property</li>
<li>mixing schema derived packages from different providers on the same contextPath</li>
<li>packages are not open to <code>java.xml.bind</code> module</li>
</ol></dd>
</dl>
</li>
</ul>
<a name="newInstance-java.lang.String-java.lang.ClassLoader-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>newInstance</h4>
<pre>public static&nbsp;<a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a>&nbsp;newInstance(java.lang.String&nbsp;contextPath,
java.lang.ClassLoader&nbsp;classLoader)
throws <a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></pre>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.
<p>
The client application must supply a context path which is a list of
colon (':', \u003A) separated java package names that contain
schema-derived classes and/or fully qualified JAXB-annotated classes.
Schema-derived
code is registered with the JAXBContext by the
ObjectFactory.class generated per package.
Alternatively than being listed in the context path, programmer
annotated JAXB mapped classes can be listed in a
<code>jaxb.index</code> resource file, format described below.
Note that a java package can contain both schema-derived classes and
user annotated JAXB classes. Additionally, the java package may
contain JAXB package annotations that must be processed. (see JLS,
Section 7.4.1 "Named Packages").
</p>
<p>
Every package listed on the contextPath must meet <b>one or both</b> of the
following conditions otherwise a <code>JAXBException</code> will be thrown:
</p>
<ol>
<li>it must contain ObjectFactory.class</li>
<li>it must contain jaxb.index</li>
</ol>
<p>
<b>Format for jaxb.index</b>
<p>
The file contains a newline-separated list of class names.
Space and tab characters, as well as blank
lines, are ignored. The comment character
is '#' (0x23); on each line all characters following the first comment
character are ignored. The file must be encoded in UTF-8. Classes that
are reachable, as defined in <a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.Class...-"><code>newInstance(Class...)</code></a>, from the
listed classes are also registered with JAXBContext.
<p>
Constraints on class name occuring in a <code>jaxb.index</code> file are:
<ul>
<li>Must not end with ".class".</li>
<li>Class names are resolved relative to package containing
<code>jaxb.index</code> file. Only classes occuring directly in package
containing <code>jaxb.index</code> file are allowed.</li>
<li>Fully qualified class names are not allowed.
A qualified class name,relative to current package,
is only allowed to specify a nested or inner class.</li>
</ul>
<p>
To maintain compatibility with JAXB 1.0 schema to java
interface/implementation binding, enabled by schema customization
<code>&lt;jaxb:globalBindings valueClass="false"&gt;</code>,
the JAXB provider will ensure that each package on the context path
has a <code>jaxb.properties</code> file which contains a value for the
<code>jakarta.xml.bind.context.factory</code> property and that all values
resolve to the same provider. This requirement does not apply to
JAXB annotated classes.
<p>
If there are any global XML element name collisions across the various
packages listed on the <code>contextPath</code>, a <code>JAXBException</code>
will be thrown.
<p>
Mixing generated interface/impl bindings from multiple JAXB Providers
in the same context path may result in a <code>JAXBException</code>
being thrown.
<p>
The steps involved in discovering the JAXB implementation is discussed in the class javadoc.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>contextPath</code> - List of java package names that contain schema
derived class and/or java to schema (JAXB-annotated)
mapped classes.
Packages in <code>contextPath</code> that are in named modules must be
<code>open</code> to at least the <code>java.xml.bind</code> module.</dd>
<dd><code>classLoader</code> - This class loader will be used to locate the implementation
classes.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a new instance of a <code>JAXBContext</code></dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></code> - if an error was encountered while creating the
<code>JAXBContext</code> such as
<ol>
<li>failure to locate either ObjectFactory.class or jaxb.index in the packages</li>
<li>an ambiguity among global elements contained in the contextPath</li>
<li>failure to locate a value for the context factory provider property</li>
<li>mixing schema derived packages from different providers on the same contextPath</li>
<li>packages are not open to <code>java.xml.bind</code> module</li>
</ol></dd>
</dl>
</li>
</ul>
<a name="newInstance-java.lang.String-java.lang.ClassLoader-java.util.Map-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>newInstance</h4>
<pre>public static&nbsp;<a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a>&nbsp;newInstance(java.lang.String&nbsp;contextPath,
java.lang.ClassLoader&nbsp;classLoader,
java.util.Map&lt;java.lang.String,?&gt;&nbsp;properties)
throws <a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></pre>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.
<p>
This is mostly the same as <a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.String-java.lang.ClassLoader-"><code>newInstance(String, ClassLoader)</code></a>,
but this version allows you to pass in provider-specific properties to configure
the instantiation of <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind"><code>JAXBContext</code></a>.
<p>
The interpretation of properties is up to implementations. Implementations must
throw <code>JAXBException</code> if it finds properties that it doesn't understand.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>contextPath</code> - List of java package names that contain schema
derived class and/or java to schema (JAXB-annotated)
mapped classes.
Packages in <code>contextPath</code> that are in named modules must be
<code>open</code> to at least the <code>java.xml.bind</code> module.</dd>
<dd><code>classLoader</code> - This class loader will be used to locate the implementation classes.</dd>
<dd><code>properties</code> - provider-specific properties. Can be null, which means the same thing as passing
in an empty map.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a new instance of a <code>JAXBContext</code></dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></code> - if an error was encountered while creating the
<code>JAXBContext</code> such as
<ol>
<li>failure to locate either ObjectFactory.class or jaxb.index in the packages</li>
<li>an ambiguity among global elements contained in the contextPath</li>
<li>failure to locate a value for the context factory provider property</li>
<li>mixing schema derived packages from different providers on the same contextPath</li>
<li>packages are not open to <code>java.xml.bind</code> module</li>
</ol></dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.6, JAXB 2.0</dd>
</dl>
</li>
</ul>
<a name="newInstance-java.lang.Class...-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>newInstance</h4>
<pre>public static&nbsp;<a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a>&nbsp;newInstance(java.lang.Class&lt;?&gt;...&nbsp;classesToBeBound)
throws <a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></pre>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.
<p>
The client application must supply a list of classes that the new
context object needs to recognize.
Not only the new context will recognize all the classes specified,
but it will also recognize any classes that are directly/indirectly
referenced statically from the specified classes. Subclasses of
referenced classes nor <code>@XmlTransient</code> referenced classes
are not registered with JAXBContext.
For example, in the following Java code, if you do
<code>newInstance(Foo.class)</code>, the newly created <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind"><code>JAXBContext</code></a>
will recognize both <code>Foo</code> and <code>Bar</code>, but not <code>Zot</code> or <code>FooBar</code>:
<pre>
class Foo {
&#64;XmlTransient FooBar c;
Bar b;
}
class Bar { int x; }
class Zot extends Bar { int y; }
class FooBar { }
</pre>
Therefore, a typical client application only needs to specify the
top-level classes, but it needs to be careful.
<p>
Note that for each java package registered with JAXBContext,
when the optional package annotations exist, they must be processed.
(see JLS, Section 7.4.1 "Named Packages").
<p>
The steps involved in discovering the JAXB implementation is discussed in the class javadoc.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>classesToBeBound</code> - List of java classes to be recognized by the new <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind"><code>JAXBContext</code></a>.
Classes in <code>classesToBeBound</code> that are in named modules must be in a package
that is <code>open</code> to at least the <code>java.xml.bind</code> module.
Can be empty, in which case a <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind"><code>JAXBContext</code></a> that only knows about
spec-defined classes will be returned.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>A new instance of a <code>JAXBContext</code>.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></code> - if an error was encountered while creating the
<code>JAXBContext</code>, such as (but not limited to):
<ol>
<li>No JAXB implementation was discovered
<li>Classes use JAXB annotations incorrectly
<li>Classes have colliding annotations (i.e., two classes with the same type name)
<li>The JAXB implementation was unable to locate
provider-specific out-of-band information (such as additional
files generated at the development time.)
<li><code>classesToBeBound</code> are not open to <code>java.xml.bind</code> module
</ol></dd>
<dd><code>java.lang.IllegalArgumentException</code> - if the parameter contains <code>null</code> (i.e., <code>newInstance(null);</code>)</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.6, JAXB 2.0</dd>
</dl>
</li>
</ul>
<a name="newInstance-java.lang.Class:A-java.util.Map-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>newInstance</h4>
<pre>public static&nbsp;<a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind">JAXBContext</a>&nbsp;newInstance(java.lang.Class&lt;?&gt;[]&nbsp;classesToBeBound,
java.util.Map&lt;java.lang.String,?&gt;&nbsp;properties)
throws <a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></pre>
<div class="block">Create a new instance of a <code>JAXBContext</code> class.
<p>
An overloading of <a href="../../../jakarta/xml/bind/JAXBContext.html#newInstance-java.lang.Class...-"><code>newInstance(Class...)</code></a>
to configure 'properties' for this instantiation of <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind"><code>JAXBContext</code></a>.
<p>
The interpretation of properties is up to implementations. Implementations must
throw <code>JAXBException</code> if it finds properties that it doesn't understand.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>classesToBeBound</code> - List of java classes to be recognized by the new <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind"><code>JAXBContext</code></a>.
Classes in <code>classesToBeBound</code> that are in named modules must be in a package
that is <code>open</code> to at least the <code>java.xml.bind</code> module.
Can be empty, in which case a <a href="../../../jakarta/xml/bind/JAXBContext.html" title="class in jakarta.xml.bind"><code>JAXBContext</code></a> that only knows about
spec-defined classes will be returned.</dd>
<dd><code>properties</code> - provider-specific properties. Can be null, which means the same thing as passing
in an empty map.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>A new instance of a <code>JAXBContext</code>.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></code> - if an error was encountered while creating the
<code>JAXBContext</code>, such as (but not limited to):
<ol>
<li>No JAXB implementation was discovered
<li>Classes use JAXB annotations incorrectly
<li>Classes have colliding annotations (i.e., two classes with the same type name)
<li>The JAXB implementation was unable to locate
provider-specific out-of-band information (such as additional
files generated at the development time.)
<li><code>classesToBeBound</code> are not open to <code>java.xml.bind</code> module
</ol></dd>
<dd><code>java.lang.IllegalArgumentException</code> - if the parameter contains <code>null</code> (i.e., <code>newInstance(null,someMap);</code>)</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.6, JAXB 2.0</dd>
</dl>
</li>
</ul>
<a name="createUnmarshaller--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createUnmarshaller</h4>
<pre>public abstract&nbsp;<a href="../../../jakarta/xml/bind/Unmarshaller.html" title="interface in jakarta.xml.bind">Unmarshaller</a>&nbsp;createUnmarshaller()
throws <a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></pre>
<div class="block">Create an <code>Unmarshaller</code> object that can be used to convert XML
data into a java content tree.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>an <code>Unmarshaller</code> object</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></code> - if an error was encountered while creating the
<code>Unmarshaller</code> object</dd>
</dl>
</li>
</ul>
<a name="createMarshaller--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createMarshaller</h4>
<pre>public abstract&nbsp;<a href="../../../jakarta/xml/bind/Marshaller.html" title="interface in jakarta.xml.bind">Marshaller</a>&nbsp;createMarshaller()
throws <a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></pre>
<div class="block">Create a <code>Marshaller</code> object that can be used to convert a
java content tree into XML data.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a <code>Marshaller</code> object</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></code> - if an error was encountered while creating the
<code>Marshaller</code> object</dd>
</dl>
</li>
</ul>
<a name="createValidator--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createValidator</h4>
<pre>@Deprecated
public abstract&nbsp;<a href="../../../jakarta/xml/bind/Validator.html" title="interface in jakarta.xml.bind">Validator</a>&nbsp;createValidator()
throws <a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></pre>
<div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;<span class="deprecationComment">since JAXB2.0</span></div>
<div class="block"><a href="../../../jakarta/xml/bind/Validator.html" title="interface in jakarta.xml.bind"><code>Validator</code></a> has been made optional and deprecated in JAXB 2.0. Please
refer to the javadoc for <a href="../../../jakarta/xml/bind/Validator.html" title="interface in jakarta.xml.bind"><code>Validator</code></a> for more detail.
<p>
Create a <code>Validator</code> object that can be used to validate a
java content tree against its source schema.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a <code>Validator</code> object</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="../../../jakarta/xml/bind/JAXBException.html" title="class in jakarta.xml.bind">JAXBException</a></code> - if an error was encountered while creating the
<code>Validator</code> object</dd>
</dl>
</li>
</ul>
<a name="createBinder-java.lang.Class-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createBinder</h4>
<pre>public&nbsp;&lt;T&gt;&nbsp;<a href="../../../jakarta/xml/bind/Binder.html" title="class in jakarta.xml.bind">Binder</a>&lt;T&gt;&nbsp;createBinder(java.lang.Class&lt;T&gt;&nbsp;domType)</pre>
<div class="block">Creates a <code>Binder</code> object that can be used for
associative/in-place unmarshalling/marshalling.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>domType</code> - select the DOM API to use by passing in its DOM Node class.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>always a new valid <code>Binder</code> object.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.lang.UnsupportedOperationException</code> - if DOM API corresponding to <code>domType</code> is not supported by
the implementation.</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.6, JAXB 2.0</dd>
</dl>
</li>
</ul>
<a name="createBinder--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createBinder</h4>
<pre>public&nbsp;<a href="../../../jakarta/xml/bind/Binder.html" title="class in jakarta.xml.bind">Binder</a>&lt;org.w3c.dom.Node&gt;&nbsp;createBinder()</pre>
<div class="block">Creates a <code>Binder</code> for W3C DOM.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>always a new valid <code>Binder</code> object.</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.6, JAXB 2.0</dd>
</dl>
</li>
</ul>
<a name="createJAXBIntrospector--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createJAXBIntrospector</h4>
<pre>public&nbsp;<a href="../../../jakarta/xml/bind/JAXBIntrospector.html" title="class in jakarta.xml.bind">JAXBIntrospector</a>&nbsp;createJAXBIntrospector()</pre>
<div class="block">Creates a <code>JAXBIntrospector</code> object that can be used to
introspect JAXB objects.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>always return a non-null valid <code>JAXBIntrospector</code> object.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.lang.UnsupportedOperationException</code> - Calling this method on JAXB 1.0 implementations will throw
an UnsupportedOperationException.</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.6, JAXB 2.0</dd>
</dl>
</li>
</ul>
<a name="generateSchema-jakarta.xml.bind.SchemaOutputResolver-">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>generateSchema</h4>
<pre>public&nbsp;void&nbsp;generateSchema(<a href="../../../jakarta/xml/bind/SchemaOutputResolver.html" title="class in jakarta.xml.bind">SchemaOutputResolver</a>&nbsp;outputResolver)
throws java.io.IOException</pre>
<div class="block">Generates the schema documents for this context.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>outputResolver</code> - this object controls the output to which schemas
will be sent.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if <a href="../../../jakarta/xml/bind/SchemaOutputResolver.html" title="class in jakarta.xml.bind"><code>SchemaOutputResolver</code></a> throws an <code>IOException</code>.</dd>
<dd><code>java.lang.UnsupportedOperationException</code> - Calling this method on JAXB 1.0 implementations will throw
an UnsupportedOperationException.</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.6, JAXB 2.0</dd>
</dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../index-all.html">Index</a></li>
<li><a href="../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../jakarta/xml/bind/JAXB.html" title="class in jakarta.xml.bind"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../jakarta/xml/bind/JAXBContextFactory.html" title="interface in jakarta.xml.bind"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../index.html?jakarta/xml/bind/JAXBContext.html" target="_top">Frames</a></li>
<li><a href="JAXBContext.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field.summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field.detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</body>
</html>