Top Description Fields Constructors Methods
org.glassfish.jaxb.runtime.v2.runtime

public final Class NameBuilder

extends Object
Class Inheritance
Annotations
@SuppressWarnings:StringEquality
Imports
org.glassfish.jaxb.runtime.v2.util.QNameMap, javax.xml.namespace.QName, java.util.HashMap, .HashSet, .Map, .Set

Creates Names and assign index numbers to them.

During this process, this class also finds out which namespace URIs are statically known to be un-bindable as the default namespace. Those are the namespace URIs that are used by attribute names.

Author
Kohsuke Kawaguchi

Field Summary

Modifier and TypeField and Description
private QNameMap<Integer>
private QNameMap<Integer>
private Map<String, Integer>
private Set<String>
private Map<String, Integer>

Constructor Summary

AccessConstructor and Description
public
NameBuilder()

Default constructor.

Method Summary

Modifier and TypeMethod and Description
private int
private int
allocIndex(QNameMap<Integer> map, String nsUri, String localName)

public NameList
conclude()

Wraps up everything and creates NameList.

public Name
public Name
createAttributeName(String nsUri, String localName)

public Name
public Name
createElementName(String nsUri, String localName)

private Name
createName(String nsUri, String localName, boolean isAttribute, QNameMap<Integer> map)

private String[]
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

attributeQNameIndexMapback to summary
private QNameMap<Integer> attributeQNameIndexMap
elementQNameIndexMapback to summary
private QNameMap<Integer> elementQNameIndexMap
localNameIndexMapback to summary
private Map<String, Integer> localNameIndexMap
nonDefaultableNsUrisback to summary
private Set<String> nonDefaultableNsUris
uriIndexMapback to summary
private Map<String, Integer> uriIndexMap

Constructor Detail

NameBuilderback to summary
public NameBuilder()

Default constructor.

Method Detail

allocIndexback to summary
private int allocIndex(Map<String, Integer> map, String str)
allocIndexback to summary
private int allocIndex(QNameMap<Integer> map, String nsUri, String localName)
concludeback to summary
public NameList conclude()

Wraps up everything and creates NameList.

createAttributeNameback to summary
public Name createAttributeName(QName name)
createAttributeNameback to summary
public Name createAttributeName(String nsUri, String localName)
createElementNameback to summary
public Name createElementName(QName name)
createElementNameback to summary
public Name createElementName(String nsUri, String localName)
createNameback to summary
private Name createName(String nsUri, String localName, boolean isAttribute, QNameMap<Integer> map)
listback to summary
private String[] list(Map<String, Integer> map)