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

public abstract Class BIConversion

extends AbstractDeclarationImpl
Class Inheritance
Known Direct Subclasses
com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.Static, com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.User, com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.UserAdapter
Imports
jakarta.xml.bind.DatatypeConverter, jakarta.xml.bind.annotation.XmlAttribute, .XmlRootElement, jakarta.xml.bind.annotation.adapters.XmlAdapter, javax.xml.XMLConstants, javax.xml.namespace.QName, com.sun.codemodel.JClass, .JClassAlreadyExistsException, .JCodeModel, .JDefinedClass, .JExpr, .JExpression, .JMethod, .JMod, .JPackage, .JType, .JVar, .JConditional, com.sun.tools.xjc.ErrorReceiver, com.sun.tools.xjc.model.CAdapter, .CBuiltinLeafInfo, .TypeUse, .TypeUseFactory, com.sun.tools.xjc.reader.Const, .Ring, .TypeUtil, com.sun.tools.xjc.reader.xmlschema.ClassSelector, com.sun.xml.xsom.XSSimpleType, org.xml.sax.Locator

Conversion declaration.

A conversion declaration specifies how an XML type gets mapped to a Java type.

Author
Kohsuke Kawaguchi ([email protected])

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
BIConversion.Static

Implementation that returns a statically-determined constant TypeUse.

public static class
BIConversion.User

User-specified <javaType> customization.

public static class

Field Summary

Modifier and TypeField and Description
public static final QName
NAME

Name of the conversion declaration.

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

Constructor Summary

AccessConstructor and Description
public
BIConversion(Locator loc)
Deprecated

protected

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 abstract TypeUse
getTypeUse(XSSimpleType
A is always associated with one XSSimpleType, but that's not always available when a is built. So we pass this as a parameter to this method.
owner
)

Gets the TypeUse object that this conversion represents.

Inherited from com.sun.tools.xjc.reader.xmlschema.bindinfo.AbstractDeclarationImpl:
getBuildergetChildrengetCodeModelgetLocationgetOwnerisAcknowledgedmarkAsAcknowledgedonSetOwnersetParent

Field Detail

NAMEback to summary
public static final QName NAME

Name of the conversion declaration.

Constructor Detail

BIConversionback to summary
public BIConversion(Locator loc)

Deprecated

Annotations
@Deprecated
BIConversionback to summary
protected BIConversion()

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
getTypeUseback to summary
public abstract TypeUse getTypeUse(XSSimpleType owner)

Gets the TypeUse object that this conversion represents.

The returned TypeUse object is properly adapted.

Parameters
owner:XSSimpleType

A is always associated with one XSSimpleType, but that's not always available when a is built. So we pass this as a parameter to this method.

com.sun.tools.xjc.reader.xmlschema.bindinfo back to summary

public final Class BIConversion.Static

extends BIConversion
Class Inheritance

Implementation that returns a statically-determined constant TypeUse.

Field Summary

Modifier and TypeField and Description
private final TypeUse
transducer

Always non-null.

Inherited from com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion:
NAME

Constructor Summary

AccessConstructor and Description
public
Static(Locator loc, TypeUse transducer)

Method Summary

Modifier and TypeMethod and Description
public TypeUse
getTypeUse(XSSimpleType owner)

Implements abstract com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.getTypeUse.

Gets the TypeUse object that this conversion represents.

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

Field Detail

transducerback to summary
private final TypeUse transducer

Always non-null.

Constructor Detail

Staticback to summary
public Static(Locator loc, TypeUse transducer)

Method Detail

getTypeUseback to summary
public TypeUse getTypeUse(XSSimpleType owner)

Implements abstract com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.getTypeUse.

Doc from com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.getTypeUse.

Gets the TypeUse object that this conversion represents.

The returned TypeUse object is properly adapted.

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

public Class BIConversion.User

extends BIConversion
Class Inheritance
Known Direct Subclasses
com.sun.tools.xjc.reader.xmlschema.bindinfo.BIGlobalBinding.GlobalStandardConversion
Annotations
@XmlRootElement
name:javaType

User-specified <javaType> customization. The parse/print methods are allowed to be null, and their default values are determined based on the owner of the token.

Field Summary

Modifier and TypeField and Description
private JType
inMemoryType

If null, computed from type.

private static final String[]
public static final QName
NAME

Hides com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.NAME.

Name of the conversion declaration.
private String
private String
private String
private TypeUse
typeUse

Cache used by getTypeUse(XSSimpleType) to improve the performance.

Constructor Summary

AccessConstructor and Description
public
User(Locator loc, String parseMethod, String printMethod, JType inMemoryType)

public
User()

Method Summary

Modifier and TypeMethod and Description
private String
private JDefinedClass
generateAdapter(String parseMethod, String printMethod, XSSimpleType owner)

generate the adapter class.

private String
public QName
getName()

Overrides com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.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 TypeUse
getTypeUse(XSSimpleType owner)

Implements abstract com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.getTypeUse.

Gets the TypeUse object that this conversion represents.

private String
private String

Field Detail

inMemoryTypeback to summary
private JType inMemoryType

If null, computed from type. Sometimes this can be set instead of type.

knownBasesback to summary
private static final String[] knownBases
NAMEback to summary
public static final QName NAME

Hides com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.NAME.

Name of the conversion declaration.

parseMethodback to summary
private String parseMethod
Annotations
@XmlAttribute
printMethodback to summary
private String printMethod
Annotations
@XmlAttribute
typeback to summary
private String type
Annotations
@XmlAttribute
name:name
typeUseback to summary
private TypeUse typeUse

Cache used by getTypeUse(XSSimpleType) to improve the performance.

Constructor Detail

Userback to summary
public User(Locator loc, String parseMethod, String printMethod, JType inMemoryType)
Userback to summary
public User()

Method Detail

findBaseConversionback to summary
private String findBaseConversion(XSSimpleType owner)
generateAdapterback to summary
private JDefinedClass generateAdapter(String parseMethod, String printMethod, XSSimpleType owner)

generate the adapter class.

getConversionMethodback to summary
private String getConversionMethod(String methodPrefix, XSSimpleType owner)
getNameback to summary
public QName getName()

Overrides com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.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
getTypeUseback to summary
public TypeUse getTypeUse(XSSimpleType owner)

Implements abstract com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.getTypeUse.

Doc from com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.getTypeUse.

Gets the TypeUse object that this conversion represents.

The returned TypeUse object is properly adapted.

Annotations
@Override
parseMethodForback to summary
private String parseMethodFor(XSSimpleType owner)
printMethodForback to summary
private String printMethodFor(XSSimpleType owner)
com.sun.tools.xjc.reader.xmlschema.bindinfo back to summary

public Class BIConversion.UserAdapter

extends BIConversion
Class Inheritance
Known Direct Subclasses
com.sun.tools.xjc.reader.xmlschema.bindinfo.BIGlobalBinding.GlobalVendorConversion
Annotations
@XmlRootElement
name:javaType
namespace:http://java.sun.com/xml/ns/jaxb/xjc

Field Summary

Modifier and TypeField and Description
private String
private String
private TypeUse
Inherited from com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion:
NAME

Constructor Summary

AccessConstructor and Description
public
UserAdapter()

Default constructor.

Method Summary

Modifier and TypeMethod and Description
private JClass
public TypeUse
getTypeUse(XSSimpleType owner)

Implements abstract com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.getTypeUse.

Gets the TypeUse object that this conversion represents.

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

Field Detail

adapterback to summary
private String adapter
Annotations
@XmlAttribute
typeback to summary
private String type
Annotations
@XmlAttribute
name:name
typeUseback to summary
private TypeUse typeUse

Constructor Detail

UserAdapterback to summary
public UserAdapter()

Default constructor.

Method Detail

computeClassTypeback to summary
private JClass computeClassType(String type)
getTypeUseback to summary
public TypeUse getTypeUse(XSSimpleType owner)

Implements abstract com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.getTypeUse.

Doc from com.sun.tools.xjc.reader.xmlschema.bindinfo.BIConversion.getTypeUse.

Gets the TypeUse object that this conversion represents.

The returned TypeUse object is properly adapted.

Annotations
@Override