Package com.sun.xml.bind.v2.model.impl
Class ArrayInfoImpl<TypeT,ClassDeclT,FieldT,MethodT>
java.lang.Object
com.sun.xml.bind.v2.model.impl.ArrayInfoImpl<TypeT,ClassDeclT,FieldT,MethodT>
- All Implemented Interfaces:
Locatable,ArrayInfo<TypeT,,ClassDeclT> NonElement<TypeT,,ClassDeclT> TypeInfo<TypeT,,ClassDeclT> Location
public class ArrayInfoImpl<TypeT,ClassDeclT,FieldT,MethodT>
extends Object
implements ArrayInfo<TypeT,ClassDeclT>, Location
Public because XJC needs to access it
- Author:
- Kohsuke Kawaguchi
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ModelBuilder<TypeT,ClassDeclT, FieldT, MethodT> Reference to theModelBuilder, only until we linkTypeInfos all together, because we don't want to keepModelBuildertoo long.protected final com.sun.xml.bind.v2.model.impl.TypeInfoSetImpl<TypeT,ClassDeclT, FieldT, MethodT> TypeInfoSetto which this class belongs.Fields inherited from interface com.sun.xml.bind.v2.model.core.NonElement
ANYTYPE_NAME -
Constructor Summary
ConstructorsConstructorDescriptionArrayInfoImpl(ModelBuilder<TypeT, ClassDeclT, FieldT, MethodT> builder, Locatable upstream, TypeT arrayType) -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanDeprecated.why are you calling a method whose return value is always known?T of T[].Gets the location object that this object points to.getType()Gets the underlying Java type that object represents.Gets the primary XML type ANYTYPE_NAME of the class.Gets the upstreamLocationinformation.booleanReturns true if thisNonElementmaps to text in XML, without any attribute nor child elements.protected final Navigator<TypeT,ClassDeclT, FieldT, MethodT> nav()protected final QNameparseElementName(ClassDeclT clazz) Parses anXmlRootElementannotation on a class and determine the element name.protected final QNameparseTypeName(ClassDeclT clazz) protected final QNameparseTypeName(ClassDeclT clazz, javax.xml.bind.annotation.XmlType t) Parses a (potentially-null)XmlTypeannotation on a class and determine the actual value.protected final AnnotationReader<TypeT,ClassDeclT, FieldT, MethodT> reader()toString()Returns a human-readable string that represents this position.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.sun.xml.bind.v2.model.annotation.Locatable
getUpstream
-
Field Details
-
owner
protected final com.sun.xml.bind.v2.model.impl.TypeInfoSetImpl<TypeT,ClassDeclT, ownerFieldT, MethodT> TypeInfoSetto which this class belongs. -
builder
Reference to theModelBuilder, only until we linkTypeInfos all together, because we don't want to keepModelBuildertoo long.
-
-
Constructor Details
-
ArrayInfoImpl
public ArrayInfoImpl(ModelBuilder<TypeT, ClassDeclT, FieldT, MethodT> builder, Locatable upstream, TypeT arrayType)
-
-
Method Details
-
getItemType
Description copied from interface:ArrayInfoT of T[]. The type of the items of the array.- Specified by:
getItemTypein interfaceArrayInfo<TypeT,ClassDeclT> - Returns:
- never null
-
getTypeName
Description copied from interface:NonElementGets the primary XML type ANYTYPE_NAME of the class.A Java type can be mapped to multiple XML types, but one of them is considered "primary" and used when we generate a schema.
- Specified by:
getTypeNamein interfaceNonElement<TypeT,ClassDeclT> - Returns:
- null if the object doesn't have an explicit type ANYTYPE_NAME (AKA anonymous.)
-
isSimpleType
public boolean isSimpleType()Description copied from interface:NonElementReturns true if thisNonElementmaps to text in XML, without any attribute nor child elements.- Specified by:
isSimpleTypein interfaceNonElement<TypeT,ClassDeclT>
-
getType
Description copied from interface:TypeInfoGets the underlying Java type that object represents.- Specified by:
getTypein interfaceTypeInfo<TypeT,ClassDeclT> - Returns:
- always non-null.
-
canBeReferencedByIDREF
public final boolean canBeReferencedByIDREF()Deprecated.why are you calling a method whose return value is always known?Leaf-type cannot be referenced from IDREF.- Specified by:
canBeReferencedByIDREFin interfaceTypeInfo<TypeT,ClassDeclT>
-
getLocation
Description copied from interface:LocatableGets the location object that this object points to. This operation could be inefficient and costly.- Specified by:
getLocationin interfaceLocatable
-
toString
Description copied from interface:LocationReturns a human-readable string that represents this position. -
getUpstream
Description copied from interface:LocatableGets the upstreamLocationinformation.- Specified by:
getUpstreamin interfaceLocatable- Returns:
- can be null.
-
reader
-
parseElementName
Parses anXmlRootElementannotation on a class and determine the element name.- Returns:
- null if none was found.
-
parseTypeName
-
parseTypeName
Parses a (potentially-null)XmlTypeannotation on a class and determine the actual value.- Parameters:
clazz- The class on which the XmlType annotation is checked.t- TheXmlTypeannotation on the clazz. This value is taken as a parameter to improve the performance for the case where 't' is pre-computed.
-