oracle.javatools.parser.java.v2.model
Interface JavaElement
- All Superinterfaces:
- Element
- All Known Subinterfaces:
- CompiledAccessExpression, CompiledDocReference, CompiledExpression, CompiledImport, CompiledInvokeExpression, CompiledSelfVariable, CompiledStatementLabel, CompiledTmpVariable, JavaAnnotation, JavaClass, JavaField, JavaFile, JavaHasAnnotations, JavaHasName, JavaHasType, JavaIsGeneric, JavaLocalVariable, JavaMember, JavaMethod, JavaPackage, JavaType, JavaTypeVariable, JavaVariable, JavaWildcardType, SourceAnnotation, SourceAnnotationExpression, SourceArrayAccessExpression, SourceAssignmentExpression, SourceClass, SourceClassInitializer, SourceDereferenceExpression, SourceDocReference, SourceDocTagName, SourceDotExpression, SourceEnumConstant, SourceExpression, SourceFieldDeclaration, SourceFieldVariable, SourceFile, SourceFormalParameter, SourceImport, SourceInfixExpression, SourceInvokeExpression, SourceListExpression, SourceLiteralExpression, SourceLocalVariable, SourceMember, SourceMemberVariable, SourceMethod, SourceMethodCallExpression, SourceName, SourceNewArrayExpression, SourceNewClassExpression, SourceOperatorExpression, SourceQuestionExpression, SourceSimpleNameExpression, SourceStatementLabel, SourceTypeArgument, SourceTypecastExpression, SourceTypeExpression, SourceTypeParameter, SourceTypeReference, SourceUnaryExpression, SourceVariable, SourceWrapperExpression
- All Known Implementing Classes:
- AbstractAnnotation, AbstractClass, AbstractElement, AbstractField, AbstractMethod, AbstractPackage, AbstractType, AbstractVariable, BaseFileProvider.BaseClass, BaseFileProvider.BasePackage, CastedMethod, oracle.javatools.parser.java.v2.classfile.ClClass, PrimitiveType, QuickComponent, QuickHasName, QuickHasType, QuickLocalVariable, QuickMethod, SignatureHasType, Value, WrapperClass, WrapperField, WrapperLocalVariable, WrapperMethod, WrapperPackage
public interface JavaElement
- extends Element
CompiledObject is the compiled representation of a syntactic (aka
symbolic) java element.
EMPTY_ARRAY
static final JavaElement[] EMPTY_ARRAY
getElementKind
int getElementKind()
- Returns:
- The type of JavaElement this is. Valid values are
JavaConstants.ELEM_*.
getFile
JavaFile getFile()
- Returns:
- Returns the JavaFile that this element is contained in.
If a SourceFile is returned, then this element is declared in or
otherwise comes in a SourceFile.
A non-null JavaFile may be returned that is not a SourceFile. For
example, a JavaClass that came from a .class file definition will
return such a JavaFile instance.
If null, then this element was created on-the-fly.
getOwner
JavaElement getOwner()
- TODO: Document me!
isSourceElement
boolean isSourceElement()
- Returns:
- True if this instance is a SourceElement itself. False
otherwise.
getSourceElement
SourceElement getSourceElement()
- Returns:
- The corresponding source symbol to this element. Null if there
is no corresponding source symbol or if the corresponding source symbol
could not be found.
getModifiers
int getModifiers()
- Returns:
- The access modifiers on this element.
isFinal
boolean isFinal()
- Returns:
- True if element is modified with "final".
isSynthetic
boolean isSynthetic()
- Returns:
- True if element is synthetic.
isHidden
boolean isHidden()
- Returns:
- True if this is hidden (bug 2798659). False otherwise.
isDeprecated
boolean isDeprecated()
- Returns:
- True if this is deprecated. False otherwise.
printCompiledInfo
java.lang.String printCompiledInfo()
- Debugging function for printing out compiled information.
Copyright © 1997, 2011, Oracle. All rights reserved.