Class Symbols.UnknownSymbol
java.lang.Object
org.sonar.java.model.Symbols.DefaultSymbol
org.sonar.java.model.Symbols.UnknownSymbol
- All Implemented Interfaces:
Symbol
- Direct Known Subclasses:
Symbols.RootPackageSymbol, Symbols.UnknownMethodSymbol, Symbols.UnkownTypeSymbol
- Enclosing class:
Symbols
-
Nested Class Summary
Nested classes/interfaces inherited from interface Symbol
Symbol.LabelSymbol, Symbol.MethodSymbol, Symbol.TypeSymbol, Symbol.VariableSymbolModifier and TypeInterfaceDescriptionstatic interfaceLabel symbol.static interfaceSymbol for methods.static interfaceSymbol for a type : class, enum, interface or annotation.static interfaceSymbol for field, method parameters and local variables. -
Field Summary
Fields inherited from interface Symbol
ROOT_PACKAGE, UNKNOWN_SYMBOL -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionDeclaration node of this symbol.final Symbol.TypeSymbolThe closest enclosing class.booleanname()Name of this symbol.owner()The owner of this symbol.final Typetype()Type of symbol.final List<IdentifierTree> usages()The identifier trees that reference this symbol.Methods inherited from class Symbols.DefaultSymbol
isAbstract, isDeprecated, isEnum, isFinal, isInterface, isMethodSymbol, isPackageSymbol, isPackageVisibility, isPrivate, isProtected, isPublic, isStatic, isTypeSymbol, isVariableSymbol, isVolatile, metadataModifier and TypeMethodDescriptionfinal booleanfinal booleanfinal booleanisEnum()booleanisFinal()final booleanbooleanbooleanfinal booleanfinal booleanfinal booleanfinal booleanisPublic()final booleanisStatic()final booleanbooleanfinal booleanmetadata()Symbol metadata informations, annotations for instance.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Symbol
isLocalVariable, isParameterModifier and TypeMethodDescriptiondefault booleandefault boolean
-
Constructor Details
-
UnknownSymbol
public UnknownSymbol()
-
-
Method Details
-
isUnknown
public boolean isUnknown() -
name
-
owner
-
type
-
enclosingClass
Description copied from interface:SymbolThe closest enclosing class.- Returns:
- null for package symbols, themselves for type symbol and enclosing class of methods or variables.
-
declaration
-
usages
Description copied from interface:SymbolThe identifier trees that reference this symbol.- Returns:
- a list of IdentifierTree referencing this symbol. An empty list if this symbol is unused.
-