abstract class RootsBase extends api.Mirror[Mirrors.this.type]
- Alphabetic
- By Inheritance
- RootsBase
- Mirror
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
- new RootsBase(rootOwner: SymbolTable.Symbol)
Abstract Value Members
-
abstract
val
EmptyPackage: SymbolTable.ModuleSymbol
The module symbol of the default (unnamed) package
-
abstract
val
EmptyPackageClass: SymbolTable.ClassSymbol
The module class symbol of the default (unnamed) package
-
abstract
val
RootClass: SymbolTable.ClassSymbol
The class symbol of the
_root_
package -
abstract
val
RootPackage: SymbolTable.ModuleSymbol
The module symbol of the
_root_
package -
abstract
def
rootLoader: SymbolTable.LazyType
- Attributes
- protected[scala]
-
abstract
val
universe: Mirrors.this.type
The universe this mirror belongs to.
The universe this mirror belongs to.
- Definition Classes
- Mirror
Concrete Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
erasureName[T](implicit arg0: ClassTag[T]): String
********************** helpers ***********************
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
- def findMemberFromRoot(fullName: SymbolTable.Name): SymbolTable.Symbol
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def getClassByName(fullname: String): SymbolTable.ClassSymbol
- def getClassIfDefined(fullname: String, toName: (String) ⇒ SymbolTable.Name): SymbolTable.Symbol
- def getClassIfDefined(fullname: String): SymbolTable.Symbol
- def getModuleByName(fullname: String): SymbolTable.ModuleSymbol
- def getModuleIfDefined(fullname: String): SymbolTable.Symbol
- def getPackage(fullname: String): SymbolTable.ModuleSymbol
- def getPackageIfDefined(fullname: SymbolTable.TermName): SymbolTable.Symbol
- def getPackageObject(fullname: SymbolTable.TermName): SymbolTable.ModuleSymbol
- def getPackageObject(fullname: String): SymbolTable.ModuleSymbol
- def getPackageObjectIfDefined(fullname: SymbolTable.TermName): SymbolTable.Symbol
- def getPackageObjectIfDefined(fullname: String): SymbolTable.Symbol
- def getRequiredClass(fullname: String): SymbolTable.ClassSymbol
- def getRequiredClass(fullname: String, toName: (String) ⇒ SymbolTable.Name): SymbolTable.ClassSymbol
- def getRequiredModule(fullname: String): SymbolTable.ModuleSymbol
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def init(): Unit
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def isMirrorInitialized: Boolean
-
def
mirrorMissingHook(owner: SymbolTable.Symbol, name: SymbolTable.Name): SymbolTable.Symbol
- Attributes
- protected
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def requiredClass[T](implicit arg0: ClassTag[T]): SymbolTable.ClassSymbol
- def requiredModule[T](implicit arg0: ClassTag[T]): SymbolTable.ModuleSymbol
-
def
staticClass(fullname: String): SymbolTable.ClassSymbol
The symbol corresponding to the globally accessible class with the given fully qualified name
fullName
.The symbol corresponding to the globally accessible class with the given fully qualified name
fullName
.If the name points to a type alias, it's recursively dealiased and its target is returned. If you need a symbol that corresponds to the type alias itself, load it directly from the package class:
scala> cm.staticClass("scala.List") res0: scala.reflect.runtime.universe.ClassSymbol = class List
scala> res0.fullName res1: String = scala.collection.immutable.List
scala> cm.staticPackage("scala") res2: scala.reflect.runtime.universe.ModuleSymbol = package scala
scala> res2.moduleClass.info member TypeName("List") res3: scala.reflect.runtime.universe.Symbol = type List
scala> res3.fullName res4: String = scala.List
To be consistent with Scala name resolution rules, in case of ambiguity between a package and an object, the object is never been considered.
For example for the following code:
package foo { class B }
object foo { class A class B }
staticClass("foo.B") will resolve to the symbol corresponding to the class B declared in the package foo, and staticClass("foo.A") will throw a ScalaReflectionException.
In the example above, to load a symbol that corresponds to the class B declared in the object foo, use staticModule("foo") to load the module symbol and then navigate info.members of its moduleClass.
Unlike getClassByName/getRequiredClass this function can also load packageless symbols. Compiler might ignore them, but they should be loadable with macros.
-
def
staticModule(fullname: String): SymbolTable.ModuleSymbol
The symbol corresponding to the globally accessible object with the given fully qualified name
fullName
.The symbol corresponding to the globally accessible object with the given fully qualified name
fullName
.To be consistent with Scala name resolution rules, in case of ambiguity between a package and an object, the object is never been considered.
For example for the following code:
package foo { object B }
object foo { object A object B }
staticModule("foo.B") will resolve to the symbol corresponding to the object B declared in the package foo, and staticModule("foo.A") will throw a ScalaReflectionException
In the example above, to load a symbol that corresponds to the object B declared in the object foo, use staticModule("foo") to load the module symbol and then navigate info.members of its moduleClass.
Unlike getModule/getRequiredModule this function can also load packageless symbols. Compiler might ignore them, but they should be loadable with macros.
-
def
staticPackage(fullname: String): SymbolTable.ModuleSymbol
The symbol corresponding to a package with the given fully qualified name
fullName
. -
def
symbolOf[T](implicit arg0: SymbolTable.WeakTypeTag[T]): SymbolTable.TypeSymbol
Type symbol of
x
as derived from a type tag. -
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
def
typeOf[T](implicit arg0: SymbolTable.TypeTag[T]): SymbolTable.Type
Shortcut for
implicitly[TypeTag[T]].tpe
Shortcut for
implicitly[TypeTag[T]].tpe
- Definition Classes
- Mirror
-
def
universeMissingHook(owner: SymbolTable.Symbol, name: SymbolTable.Name): SymbolTable.Symbol
- Attributes
- protected
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
weakTypeOf[T](implicit arg0: SymbolTable.WeakTypeTag[T]): SymbolTable.Type
Shortcut for
implicitly[WeakTypeTag[T]].tpe
Shortcut for
implicitly[WeakTypeTag[T]].tpe
- Definition Classes
- Mirror
-
final
def
wrapMissing(body: ⇒ SymbolTable.Symbol): SymbolTable.Symbol
- Annotations
- @inline()
Deprecated Value Members
-
def
getClassByName(fullname: SymbolTable.Name): SymbolTable.ClassSymbol
- Annotations
- @deprecated
- Deprecated
(Since version 2.13.0) Use overload that accepts a String.
-
def
getClassIfDefined(fullname: SymbolTable.Name): SymbolTable.Symbol
- Annotations
- @deprecated
- Deprecated
(Since version 2.13.0) Use overload that accepts a String.
-
def
getModuleByName(fullname: SymbolTable.Name): SymbolTable.ModuleSymbol
- Annotations
- @deprecated
- Deprecated
(Since version 2.13.0) Use overload that accepts a String.
-
def
getModuleIfDefined(fullname: SymbolTable.Name): SymbolTable.Symbol
- Annotations
- @deprecated
- Deprecated
(Since version 2.13.0) Use overload that accepts a String.
-
def
getPackage(fullname: SymbolTable.TermName): SymbolTable.ModuleSymbol
- Annotations
- @deprecated
- Deprecated
(Since version 2.13.0) Use overload that accepts a String.
-
def
getRequiredPackage(fullname: String): SymbolTable.ModuleSymbol
- Annotations
- @deprecated
- Deprecated
(Since version 2.11.0) use getPackage