ScalaInstance

sbt.internal.inc.ScalaInstance
See theScalaInstance companion object
final class ScalaInstance(val version: String, val loader: ClassLoader, val loaderCompilerOnly: ClassLoader, val loaderLibraryOnly: ClassLoader, val libraryJars: Array[File], val compilerJars: Array[File], val allJars: Array[File], val explicitActual: Option[String]) extends ScalaInstance

A Scala instance encapsulates all the information that is bound to a concrete Scala version, like the java.lang.ClassLoader or all the JARs required for Scala compilation: library jar, compiler jar and others.

Both a ClassLoader and the jars are required because the compiler's boot classpath requires the location of the library and compiler jar on the classpath to compile any Scala program and macros.

Attributes

See also

xsbti.compile.ScalaInstance

Companion
object
Graph
Supertypes
trait ScalaInstance
class Object
trait Matchable
class Any

Members list

Value members

Deprecated constructors

def this(version: String, loader: ClassLoader, loaderLibraryOnly: ClassLoader, libraryJar: File, compilerJar: File, allJars: Array[File], explicitActual: Option[String])

Attributes

Deprecated
true
def this(version: String, loader: ClassLoader, loaderLibraryOnly: ClassLoader, libraryJars: Array[File], compilerJar: File, allJars: Array[File], explicitActual: Option[String])

Attributes

Deprecated
true
def this(version: String, loader: ClassLoader, libraryJar: File, compilerJar: File, allJars: Array[File], explicitActual: Option[String])

Attributes

Deprecated
true

Concrete methods

def isManagedVersion: Boolean

Check whether scalaInstance comes from a managed (i.e. ivy-resolved) scala or if it's a free-floating ScalaInstance, in which case we need to do tricks in the classpaths because it won't be on them.

Check whether scalaInstance comes from a managed (i.e. ivy-resolved) scala or if it's a free-floating ScalaInstance, in which case we need to do tricks in the classpaths because it won't be on them.

Attributes

def otherJars: Array[File]
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
Any

Deprecated and Inherited methods

@Deprecated
def compilerJar(): File

Attributes

Deprecated
true
Inherited from:
ScalaInstance
@Deprecated
def libraryJar(): File

Attributes

Deprecated
true
Inherited from:
ScalaInstance

Concrete fields

lazy val actualVersion: String

Get version of Scala in the compiler.properties file from the loader. This version may be different than the one passed in by version.

Get version of Scala in the compiler.properties file from the loader. This version may be different than the one passed in by version.

Attributes

val allJars: Array[File]
val compilerJars: Array[File]
val explicitActual: Option[String]
val libraryJars: Array[File]
val loader: ClassLoader
val loaderCompilerOnly: ClassLoader
val loaderLibraryOnly: ClassLoader
val version: String