DependencyResolver

dotty.tools.repl.DependencyResolver

Handles dependency resolution using Coursier for the REPL

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete methods

def addToCompilerClasspath(files: List[File], prevClassLoader: ClassLoader, prevOutputDir: AbstractFile)(using ctx: Context): AbstractFileClassLoader

Add resolved dependencies to the compiler classpath and classloader. Returns the new classloader.

Add resolved dependencies to the compiler classpath and classloader. Returns the new classloader.

This follows the same pattern as the :jar command.

Attributes

def extractDependencies(sourceCode: String): List[String]

Extract all dependencies from using directives in source code

Extract all dependencies from using directives in source code

Attributes

Parse a dependency string of the form org::artifact:version or org:artifact:version and return the (organization, artifact, version) triple if successful.

Parse a dependency string of the form org::artifact:version or org:artifact:version and return the (organization, artifact, version) triple if successful.

Supports both Maven-style (single colon) and Scala-style (double colon) notation:

  • Maven: com.lihaoyi:scalatags_3:0.13.1
  • Scala: com.lihaoyi::scalatags:0.13.1 (automatically appends _3)

Attributes

Resolve dependencies using Coursier Interface and return the classpath as a list of File objects

Resolve dependencies using Coursier Interface and return the classpath as a list of File objects

Attributes