Class Symbols.UnknownMethodSymbol

All Implemented Interfaces:
Symbol, Symbol.MethodSymbol
Enclosing class:
Symbols

public static final class Symbols.UnknownMethodSymbol extends Symbols.UnknownSymbol implements Symbol.MethodSymbol
  • Constructor Details

    • UnknownMethodSymbol

      public UnknownMethodSymbol()
  • Method Details

    • declaration

      public MethodTree declaration()
      Description copied from interface: Symbol
      Declaration node of this symbol. Currently, only works for declaration within the same file.
      Specified by:
      declaration in interface Symbol
      Specified by:
      declaration in interface Symbol.MethodSymbol
      Overrides:
      declaration in class Symbols.UnknownSymbol
      Returns:
      the Tree of the declaration of this symbol. Null if declaration does not occur in the currently analyzed file.
    • parameterTypes

      public List<Type> parameterTypes()
      Description copied from interface: Symbol.MethodSymbol
      Type of parameters declared by this method. In case of generic types of method invocations, this list of types is more specialized than declarationParameters().stream().map(Symbol::type). For example it could be String instead of T.
      Specified by:
      parameterTypes in interface Symbol.MethodSymbol
      Returns:
      empty list if method has a zero arity.
    • declarationParameters

      public List<Symbol> declarationParameters()
      Description copied from interface: Symbol.MethodSymbol
      Symbols of parameters declared by this method. Use to access parameter annotations. Note: 1) in case of generic types of method invocations, this list of types is less specialized than Symbol.MethodSymbol.parameterTypes(). For example it could be T instead of String. 2) when the declaration comes from binaries, the name of the symbol will be generated (@see JVariableSymbol.ParameterPlaceholderSymbol).
      Specified by:
      declarationParameters in interface Symbol.MethodSymbol
      Returns:
      empty list if methods has not parameters
    • returnType

      public Symbol.TypeSymbol returnType()
      Specified by:
      returnType in interface Symbol.MethodSymbol
    • thrownTypes

      public List<Type> thrownTypes()
      Description copied from interface: Symbol.MethodSymbol
      List of the exceptions that can be thrown by the method.
      Specified by:
      thrownTypes in interface Symbol.MethodSymbol
      Returns:
      empty list if no exception are declared in the throw clause of the method.
    • overriddenSymbols

      public List<Symbol.MethodSymbol> overriddenSymbols()
      Description copied from interface: Symbol.MethodSymbol
      Retrieve the overridden symbols in all the known type hierarchy. Note that it will only returns the symbols which might be determined from known types. The list might therefore not be complete in case of missing dependencies.
      Specified by:
      overriddenSymbols in interface Symbol.MethodSymbol
      Returns:
      the overridden symbols, or an empty list if the method is not overriding any method or overriding can not be determined (incomplete semantics)
    • owner

      public Symbol owner()
      Description copied from interface: Symbol
      The owner of this symbol.
      Specified by:
      owner in interface Symbol
      Overrides:
      owner in class Symbols.UnknownSymbol
      Returns:
      the symbol that owns this symbol, null for package symbols, or unknown symbols
    • name

      public String name()
      Description copied from interface: Symbol
      Name of this symbol.
      Specified by:
      name in interface Symbol
      Overrides:
      name in class Symbols.UnknownSymbol
      Returns:
      simple name of the symbol.
    • signature

      public String signature()
      Description copied from interface: Symbol.MethodSymbol
      Compute the signature as identified from bytecode point of view. Will be unique for each method.
      Specified by:
      signature in interface Symbol.MethodSymbol
      Returns:
      the signature of the method, as String
    • isOverridable

      public boolean isOverridable()
      Specified by:
      isOverridable in interface Symbol.MethodSymbol
      Returns:
      true if the method symbol is overridable.
    • isParametrizedMethod

      public boolean isParametrizedMethod()
      Specified by:
      isParametrizedMethod in interface Symbol.MethodSymbol
      Returns:
      true if the method has type parameters.
    • isDefaultMethod

      public boolean isDefaultMethod()
      Specified by:
      isDefaultMethod in interface Symbol.MethodSymbol
      Returns:
      true if the method has a default implementation.
    • isSynchronizedMethod

      public boolean isSynchronizedMethod()
      Specified by:
      isSynchronizedMethod in interface Symbol.MethodSymbol
      Returns:
      true if the method is synchronized.
    • isVarArgsMethod

      public boolean isVarArgsMethod()
      Specified by:
      isVarArgsMethod in interface Symbol.MethodSymbol
      Returns:
      true if the method takes a vararg argument (e.g. `String... args`).
    • isNativeMethod

      public boolean isNativeMethod()
      Specified by:
      isNativeMethod in interface Symbol.MethodSymbol
      Returns:
      true if the method is native.