PackageSymbol

tastyquery.Symbols.PackageSymbol
final class PackageSymbol extends Symbol, DeclaringSymbol

Attributes

Graph
Supertypes
class Symbol
class Object
trait Matchable
class Any

Members list

Type members

Types

type DeclType = Symbol
type DefiningTreeType = Nothing

Value members

Concrete methods

final def declarations(using Context): List[Symbol]

Note: this will force all trees in a package

Note: this will force all trees in a package

Attributes

final def findDecl(name: Name)(using Context): Symbol
final def findDecl(name: TypeName)(using Context): TypeSymbol
final def findDecl(name: TermName)(using Context): TermSymbol | PackageSymbol
final def getDecl(name: Name)(using Context): Option[Symbol]
final def getDecl(name: TypeName)(using Context): Option[TypeSymbol]
final def getDecl(name: TermName)(using Context): Option[TermSymbol | PackageSymbol]
final def getPackageDecl(name: SimpleName): Option[PackageSymbol]

Gets the subpackage with the specified name, if it exists.

Gets the subpackage with the specified name, if it exists.

If this package contains a subpackage with the name name, returns Some(subpackage). Otherwise, returns None.

If there exists another kind of declaration with the given name, this method returns None (instead of, for example, throwing).

Attributes

Note

Performance guarantee: This method does not try to load non-package symbols from the classpath.

final def isRootPackage: Boolean

Is this the root package?

Is this the root package?

Attributes

Inherited methods

final def annotations: List[Annotation]

Attributes

Inherited from:
Symbol
final def asClass: ClassSymbol

Attributes

Inherited from:
Symbol

Attributes

Inherited from:
Symbol
final def asTerm: TermSymbol

Attributes

Inherited from:
Symbol
final def asType: TypeSymbol

Attributes

Inherited from:
Symbol
final def displayFullName: String

A full name of this symbol for display purposes, such as debugging or error messages.

A full name of this symbol for display purposes, such as debugging or error messages.

displayFullName must not be used to identify symbols, as it is not unique.

Attributes

Inherited from:
Symbol
protected def doCheckCompleted(): Unit

This method is overridden in every subclass to perform their own checks.

This method is overridden in every subclass to perform their own checks.

Every override is expected to call super.doCheckCompleted() first. If a check fail, it should be reported with failNotCompleted.

Attributes

Inherited from:
Symbol
final protected def failNotCompleted(details: String): Nothing

Attributes

Inherited from:
Symbol
final protected def flags: FlagSet

Attributes

Inherited from:
Symbol
final def getAnnotation(annotClass: ClassSymbol)(using Context): Option[Annotation]

Attributes

Inherited from:
Symbol
final def getAnnotations(annotClass: ClassSymbol)(using Context): List[Annotation]

Attributes

Inherited from:
Symbol
final def hasAnnotation(annotClass: ClassSymbol)(using Context): Boolean

Attributes

Inherited from:
Symbol
final def isClass: Boolean

Attributes

Inherited from:
Symbol
final def isPackage: Boolean

Attributes

Inherited from:
Symbol
final def isTerm: Boolean

Attributes

Inherited from:
Symbol
final def isType: Boolean

Attributes

Inherited from:
Symbol
final protected def privateWithin: Option[DeclaringSymbol]

Attributes

Inherited from:
Symbol
def toDebugString: String

Attributes

Inherited from:
Symbol
override def toString: String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Symbol -> Any
Inherited from:
Symbol
final def tree: Option[DefiningTreeType]

Attributes

Inherited from:
Symbol

Concrete fields

override val owner: PackageSymbol | Null