Dali Provisional API
Release 3.2

org.eclipse.jpt.jaxb.core.context.java
Interface JavaType

All Superinterfaces:
IAdaptable, JaxbContextNode, JaxbNode, JptResourceTypeReference, Model, XmlAdaptable
All Known Subinterfaces:
JavaClass, JavaEnum

public interface JavaType
extends XmlAdaptable

Represents a java class (or enum or interface) with JAXB metadata (specified or implied).

Provisional API: This interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.

Since:
3.1

Nested Class Summary
static class JavaType.IsKind
           
 
Nested classes/interfaces inherited from interface org.eclipse.jpt.common.core.JptResourceTypeReference
JptResourceTypeReference.ResourceTypeTransformer
 
Field Summary
static String DEFAULT_MAPPED_PROPERTY
           
static String MAPPING_PROPERTY
           
 
Fields inherited from interface org.eclipse.jpt.jaxb.core.context.XmlAdaptable
XML_JAVA_TYPE_ADAPTER_PROPERTY
 
Fields inherited from interface org.eclipse.jpt.common.core.JptResourceTypeReference
RESOURCE_TYPE_TRANSFORMER
 
Method Summary
 JavaResourceAbstractType getJavaResourceType()
          Return the associated java resource type
 JaxbPackage getJaxbPackage()
          Return the JaxbPackage associated with this type (NB: may be null in some partially built cases)
 JaxbPackageInfo getJaxbPackageInfo()
          Return the JaxbPackageInfo associated with this type, if it exists
 TypeKind getKind()
          Return the kind of type represented.
 JavaTypeMapping getMapping()
          Return the mapping of this type.
 TypeName getTypeName()
          Return the type's name object
 boolean isDefaultMapped()
          Return true if this type is mapped by reference.
 void setDefaultMapped(boolean newValue)
          Set this to true if this type is referenced by another mapped type.
 void validate(List<IMessage> messages, IReporter reporter)
          Add to the list of current validation messages
 
Methods inherited from interface org.eclipse.jpt.jaxb.core.context.XmlAdaptable
addXmlJavaTypeAdapter, getXmlJavaTypeAdapter, removeXmlJavaTypeAdapter
 
Methods inherited from interface org.eclipse.jpt.jaxb.core.context.JaxbContextNode
getCompletionProposals, getContextRoot, getValidationTextRange, synchronizeWithResourceModel, update
 
Methods inherited from interface org.eclipse.jpt.jaxb.core.JaxbNode
getJaxbProject, getParent, getResource, stateChanged
 
Methods inherited from interface org.eclipse.jpt.common.utility.model.Model
addChangeListener, addCollectionChangeListener, addListChangeListener, addPropertyChangeListener, addStateChangeListener, removeChangeListener, removeCollectionChangeListener, removeListChangeListener, removePropertyChangeListener, removeStateChangeListener
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 
Methods inherited from interface org.eclipse.jpt.common.core.JptResourceTypeReference
getResourceType
 

Field Detail

MAPPING_PROPERTY

static final String MAPPING_PROPERTY
See Also:
Constant Field Values

DEFAULT_MAPPED_PROPERTY

static final String DEFAULT_MAPPED_PROPERTY
See Also:
Constant Field Values
Method Detail

getKind

TypeKind getKind()
Return the kind of type represented. JavaTypes of TypeKind CLASS may safely be cast to JavaClass JavaTypes of TypeKind ENUM may safely be cast to JavaEnum


getMapping

JavaTypeMapping getMapping()
Return the mapping of this type. May be null. Will not be null if this type has an XmlType annotation (or other mapping annotation) or if this type is default mapped.


isDefaultMapped

boolean isDefaultMapped()
Return true if this type is mapped by reference. (If this type has a default mapping by virtue of it being referenced by another mapped type.)


setDefaultMapped

void setDefaultMapped(boolean newValue)
Set this to true if this type is referenced by another mapped type. (NB: should only be called by JaxbContextRoot object.)


getJavaResourceType

JavaResourceAbstractType getJavaResourceType()
Return the associated java resource type


getTypeName

TypeName getTypeName()
Return the type's name object


getJaxbPackage

JaxbPackage getJaxbPackage()
Return the JaxbPackage associated with this type (NB: may be null in some partially built cases)


getJaxbPackageInfo

JaxbPackageInfo getJaxbPackageInfo()
Return the JaxbPackageInfo associated with this type, if it exists


validate

void validate(List<IMessage> messages,
              IReporter reporter)
Add to the list of current validation messages

Specified by:
validate in interface JaxbContextNode

Dali Provisional API
Release 3.2

Copyright (c) 2012 Oracle. All rights reserved.