Top Description Inners Fields Constructors Methods
com.sun.tools.xjc.reader.xmlschema.bindinfo

public final Class BIEnum

extends AbstractDeclarationImpl
Class Inheritance
Annotations
@XmlRootElement
name:typesafeEnumClass
Imports
java.util.HashMap, .Map, jakarta.xml.bind.annotation.XmlAttribute, .XmlElement, .XmlRootElement, .XmlTransient, javax.xml.namespace.QName, com.sun.tools.xjc.reader.Const, com.sun.tools.xjc.reader.xmlschema.SimpleTypeBuilder

Enumeration customization.

This customization binds a simple type to a type-safe enum class. The actual binding process takes place in SimpleTypeBuilder.

This customization is acknowledged by SimpleTypeBuilder.

Author
Kohsuke Kawaguchi ([email protected])

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class
BIEnum.BIEnumMember2

BIEnumMember used inside BIEnum has additional 'value' attribute.

Field Summary

Modifier and TypeField and Description
public String
className

Gets the specified class name, or null if not specified.

public final String
javadoc

Gets the javadoc comment specified in the customization.

private boolean
map

If false, it means not to bind to a type-safe enum.

public final Map<String, BIEnumMember>
members

Gets the map that contains XML value -> BIEnumMember pairs.

public static final QName
NAME

Name of this declaration.

public String
Inherited from com.sun.tools.xjc.reader.xmlschema.bindinfo.AbstractDeclarationImpl:
locparent

Constructor Summary

AccessConstructor and Description
public
BIEnum()

Default constructor.

Method Summary

Modifier and TypeMethod and Description
public QName
getName()

Implements com.sun.tools.xjc.reader.xmlschema.bindinfo.BIDeclaration.getName.

Gets the name of this binding declaration, which is the same as the tag name of the binding element.

public boolean
private void
public void
Inherited from com.sun.tools.xjc.reader.xmlschema.bindinfo.AbstractDeclarationImpl:
getBuildergetChildrengetCodeModelgetLocationgetOwnerisAcknowledgedmarkAsAcknowledgedonSetOwner

Field Detail

classNameback to summary
public String className

Gets the specified class name, or null if not specified.

Annotations
@XmlAttribute
name:name
javadocback to summary
public final String javadoc

Gets the javadoc comment specified in the customization. Can be null if none is specified.

Annotations
@XmlElement
mapback to summary
private boolean map

If false, it means not to bind to a type-safe enum. this takes precedence over all the other properties of this class.

Annotations
@XmlAttribute
name:map
membersback to summary
public final Map<String, BIEnumMember> members

Gets the map that contains XML value -> BIEnumMember pairs. This table is built from <enumMember> customizations. Always return non-null.

Annotations
@XmlTransient
NAMEback to summary
public static final QName NAME

Name of this declaration.

refback to summary
public String ref
Annotations
@XmlAttribute
name:ref
See Also
BIClass#getExistingClassRef()

Constructor Detail

BIEnumback to summary
public BIEnum()

Default constructor.

Method Detail

getNameback to summary
public QName getName()

Implements com.sun.tools.xjc.reader.xmlschema.bindinfo.BIDeclaration.getName.

Doc from com.sun.tools.xjc.reader.xmlschema.bindinfo.BIDeclaration.getName.

Gets the name of this binding declaration, which is the same as the tag name of the binding element.

Annotations
@Override
isMappedback to summary
public boolean isMapped()
setMembersback to summary
private void setMembers(BIEnum.BIEnumMember2[] mems)
Annotations
@XmlElement
name:typesafeEnumMember
setParentback to summary
public void setParent(BindInfo p)

Overrides com.sun.tools.xjc.reader.xmlschema.bindinfo.AbstractDeclarationImpl.setParent.

Implements com.sun.tools.xjc.reader.xmlschema.bindinfo.BIDeclaration.setParent.

Doc from com.sun.tools.xjc.reader.xmlschema.bindinfo.BIDeclaration.setParent.

Sets the parent BindInfo object of this declaration. A declaration object can use this pointer to access context information, such as other customizations.

This method can be only called from BindInfo, and only once. This is a good opportunity to do some follow-up initialization after JAXB unmarshalling populated .

Annotations
@Override
com.sun.tools.xjc.reader.xmlschema.bindinfo back to summary

pack-priv Class BIEnum.BIEnumMember2

extends BIEnumMember
Class Inheritance

BIEnumMember used inside BIEnum has additional 'value' attribute.

Field Summary

Modifier and TypeField and Description
pack-priv String
value

The lexical representaion of the constant to which we are attaching.

Inherited from com.sun.tools.xjc.reader.xmlschema.bindinfo.BIEnumMember:
javadocnameNAME

Constructor Summary

AccessConstructor and Description
public
BIEnumMember2()

Default constructor.

Method Summary

Inherited from com.sun.tools.xjc.reader.xmlschema.bindinfo.BIEnumMember:
getName

Field Detail

valueback to summary
pack-priv String value

The lexical representaion of the constant to which we are attaching.

Annotations
@XmlAttribute
required:true

Constructor Detail

BIEnumMember2back to summary
public BIEnumMember2()

Default constructor.