Packages

final class BuildTargets extends AnyRef

In-memory cache for looking up build server metadata.

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. BuildTargets
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new BuildTargets(ammoniteBuildServer: (BuildTargetIdentifier) ⇒ Option[BuildServerConnection])

Type Members

  1. case class InferredBuildTarget(jar: io.AbsolutePath, symbol: String, id: BuildTargetIdentifier) extends Product with Serializable

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def addDependencySource(sourcesJar: io.AbsolutePath, target: BuildTargetIdentifier): Unit
  5. def addJavacOptions(result: JavacOptionsResult): Unit
  6. def addScalacOptions(result: ScalacOptionsResult): Unit
  7. def addSourceItem(sourceItem: io.AbsolutePath, buildTarget: BuildTargetIdentifier): Unit
  8. def addSourceRoot(root: io.AbsolutePath): Unit
  9. def addWorkspaceBuildTargets(result: WorkspaceBuildTargetsResult): Unit
  10. def all: Iterator[BuildTarget]
  11. def allBuildTargetIds: Seq[BuildTargetIdentifier]
  12. def allInverseDependencies(target: BuildTargetIdentifier): Set[BuildTargetIdentifier]
  13. def allJava: Iterator[JavaTarget]
  14. def allScala: Iterator[ScalaTarget]
  15. def allSourceJars: Iterator[io.AbsolutePath]
  16. def allTargetRoots: Iterator[io.AbsolutePath]
  17. def allWorkspaceJars: Iterator[io.AbsolutePath]
  18. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  19. def buildServerOf(id: BuildTargetIdentifier): Option[BuildServerConnection]
  20. def buildTargetSources(id: BuildTargetIdentifier): Iterable[io.AbsolutePath]
  21. def buildTargetTransitiveDependencies(id: BuildTargetIdentifier): Iterable[BuildTargetIdentifier]
  22. def buildTargetTransitiveSources(id: BuildTargetIdentifier): Iterator[io.AbsolutePath]
  23. val buildTargetsOrder: (BuildTargetIdentifier) ⇒ Int
  24. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  25. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  26. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  27. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  28. def findByDisplayName(name: String): Option[BuildTarget]
  29. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  30. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  31. def inferBuildTarget(toplevels: Iterable[mtags.Symbol]): Option[InferredBuildTarget]
  32. def inferBuildTarget(source: io.AbsolutePath): Option[BuildTargetIdentifier]

    Tries to guess what build target this readonly file belongs to from the symbols it defines.

    Tries to guess what build target this readonly file belongs to from the symbols it defines.

    By default, we rely on carefully recording what build target produced what files in the .metals/readonly/ directory. This approach has the problem that navigation failed to work in readonly/ sources if

    - a new metals feature forgot to record the build target - a user removes .metals/metals.h2.db

    When encountering an unknown readonly/ file we do the following steps to infer what build target it belongs to:

    - check if file is in .metals/readonly/dependencies/${source-jar-name} - find the build targets that have a sourceDependency with that name

    Otherwise if it's a jar file we find a build target it belongs to.

    This approach is not glamorous but it seems to work reasonably well.

  33. def info(id: BuildTargetIdentifier): Option[BuildTarget]
  34. def inverseDependencyLeaves(target: BuildTargetIdentifier): Set[BuildTargetIdentifier]
  35. def inverseDependencySource(sourceJar: io.AbsolutePath): Set[BuildTargetIdentifier]
  36. def inverseSourceItem(source: io.AbsolutePath): Option[io.AbsolutePath]
  37. def inverseSources(source: io.AbsolutePath): Option[BuildTargetIdentifier]

    Returns the first build target containing this source file.

  38. def isInsideSourceRoot(path: io.AbsolutePath): Boolean
  39. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  40. def isInverseDependency(query: BuildTargetIdentifier, roots: List[BuildTargetIdentifier]): Boolean
  41. def javaTarget(id: BuildTargetIdentifier): Option[JavaTarget]
  42. def javaTargetRoot(buildTarget: BuildTargetIdentifier): Option[io.AbsolutePath]
  43. def linkSourceFile(id: BuildTargetIdentifier, source: io.AbsolutePath): Unit
  44. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  45. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  46. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  47. def onCreate(source: io.AbsolutePath): Unit
  48. def originalInverseSourceItem(source: io.AbsolutePath): Option[io.AbsolutePath]
  49. def reset(): Unit
  50. def resetConnections(idToConn: List[(BuildTargetIdentifier, BuildServerConnection)]): Unit
  51. def sbtAutoImports(path: io.AbsolutePath): Option[Seq[String]]

    Resolves sbt auto imports if a file belongs to a Sbt build target.

  52. def sbtBuildScalaTarget(file: io.AbsolutePath): Option[BuildTargetIdentifier]

    Returns meta build target for *.sbt or *.scala files.

    Returns meta build target for *.sbt or *.scala files. It selects build target by directory of its connection because *.sbt and *.scala aren't included in sourceFiles set

  53. def scalaTarget(id: BuildTargetIdentifier): Option[ScalaTarget]
  54. def scalaTargetRoot(buildTarget: BuildTargetIdentifier): Option[io.AbsolutePath]
  55. def scalaVersion(source: io.AbsolutePath): Option[String]
  56. def setTables(newTables: Tables): Unit
  57. def setWorkspaceDirectory(newWorkspace: io.AbsolutePath): Unit
  58. def sourceBuildTargets(sourceItem: io.AbsolutePath): Iterable[BuildTargetIdentifier]
  59. def sourceItems: Iterable[io.AbsolutePath]
  60. def sourceItemsToBuildTargets: Iterator[(io.AbsolutePath, java.lang.Iterable[BuildTargetIdentifier])]
  61. def sourceJarFile(sourceJarName: String): Option[io.AbsolutePath]
  62. def sourceRoots: Iterable[io.AbsolutePath]
  63. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  64. def targetClassDirectories(id: BuildTargetIdentifier): List[String]
  65. def targetJarClasspath(id: BuildTargetIdentifier): Option[List[io.AbsolutePath]]
  66. def targetRoots(buildTarget: BuildTargetIdentifier): List[io.AbsolutePath]
  67. def toString(): String
    Definition Classes
    AnyRef → Any
  68. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  69. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  70. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  71. def workspaceDirectory(buildTarget: BuildTargetIdentifier): Option[io.AbsolutePath]

Inherited from AnyRef

Inherited from Any

Ungrouped