Packages

c

scala.meta.internal.metals

MetalsLspService

abstract class MetalsLspService extends Folder with Cancelable with TextDocumentService

Metals implementation of the Scala Language Service.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. MetalsLspService
  2. TextDocumentService
  3. Cancelable
  4. Folder
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new MetalsLspService(ec: ExecutionContextExecutorService, sh: ScheduledExecutorService, serverInputs: MetalsServerInputs, languageClient: ConfiguredLanguageClient, initializeParams: InitializeParams, clientConfig: ClientConfiguration, statusBar: StatusBar, focusedDocument: () => Option[io.AbsolutePath], shellRunner: ShellRunner, timerProvider: TimerProvider, folder: io.AbsolutePath, folderVisibleName: Option[String], headDoctor: HeadDoctor, bspStatus: BspStatus, workDoneProgress: WorkDoneProgress, maxScalaCliServers: Int)

    ec

    Execution context used for submitting tasks. This class DO NOT manage the lifecycle of this execution context.

    sh

    Scheduled executor service used for scheduling tasks. This class DO NOT manage the lifecycle of this executor.

    serverInputs

    Collection of different parameters used by Metals for running, which main purpose is allowing for custom behavior in tests.

    initializeParams

    Initialization parameters send by the client in the initialize request, which is the first request sent to the server by the client.

Abstract Value Members

  1. abstract def buildData(): Seq[BuildTool]
    Attributes
    protected
  2. abstract def fileWatcher: FileWatcher
  3. abstract def maybeImportFileAndLoad(path: io.AbsolutePath, load: () => Future[Unit]): Future[Unit]
  4. abstract def onBuildTargetChanges(params: DidChangeBuildTarget): Unit
    Attributes
    protected
  5. abstract def onInitialized(): Future[Unit]
    Attributes
    protected
  6. abstract def pauseables: Pauseable
  7. abstract def projectInfo: MetalsServiceInfo
  8. abstract def semanticdbs(): Semanticdbs
    Attributes
    protected

Concrete 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 allActionCommandsIds: Set[String]
  5. def analyzeStackTrace(content: String): Option[ExecuteCommandParams]
  6. def applyEdits(uri: String, edits: List[TextEdit]): Future[ApplyWorkspaceEditResponse]
    Attributes
    protected
  7. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  8. val bspErrorHandler: BspErrorHandler
    Attributes
    protected
  9. var bspSession: Option[BspSession]
  10. val buildClient: ForwardingMetalsBuildClient
  11. def buildHasErrors(path: io.AbsolutePath): Boolean
  12. var buildServerPromise: Promise[Unit]
  13. val buildTargetClasses: BuildTargetClasses
    Attributes
    protected
  14. val buildTargets: BuildTargets
  15. val buildToolSelector: BuildToolSelector
    Attributes
    protected
  16. def callHierarchyIncomingCalls(params: CallHierarchyIncomingCallsParams): CompletableFuture[java.util.List[CallHierarchyIncomingCall]]
  17. def callHierarchyOutgoingCalls(params: CallHierarchyOutgoingCallsParams): CompletableFuture[java.util.List[CallHierarchyOutgoingCall]]
  18. val callHierarchyProvider: CallHierarchyProvider
    Attributes
    protected
  19. def cancel(): Unit
    Definition Classes
    MetalsLspServiceCancelable
  20. def cancelCompile(): Future[Unit]
  21. val cancelables: MutableCancelable
    Attributes
    protected
  22. def cascadeCompile(): Future[Unit]
  23. def check(): Unit
    Attributes
    protected
  24. def chooseClass(uri: String, granurality: ClassFinderGranularity): Future[DecoderResponse]
  25. def cleanCompile(): Future[Unit]
  26. def clearBloopDir(folder: io.AbsolutePath): Unit
    Attributes
    protected
  27. def clearFolders(folders: io.AbsolutePath*): Unit
    Attributes
    protected
  28. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
  29. def codeAction(params: CodeActionParams): CompletableFuture[java.util.List[CodeAction]]
  30. val codeActionProvider: CodeActionProvider
    Attributes
    protected
  31. def codeLens(params: CodeLensParams): CompletableFuture[java.util.List[CodeLens]]
  32. val codeLensProvider: CodeLensProvider
    Attributes
    protected
  33. val compilations: Compilations
  34. val compilers: Compilers
    Attributes
    protected
  35. def completion(params: CompletionParams): CompletableFuture[CompletionList]
  36. def completionItemResolve(item: CompletionItem): CompletableFuture[CompletionItem]
  37. val connectionBspStatus: ConnectionBspStatus
    Attributes
    protected
  38. def copyWorksheetOutput(worksheetPath: io.AbsolutePath): CompletableFuture[AnyRef]
  39. def createDebugSession(target: BuildTargetIdentifier): Future[DebugSession]
  40. def createFile(directoryURI: Option[String], name: Option[String], fileType: Option[String], isScala: Boolean): CompletableFuture[AnyRef]
  41. def debugDiscovery(params: DebugDiscoveryParams): Future[DebugSession]
  42. val debugDiscovery: DebugDiscovery
    Attributes
    protected
  43. val debugProvider: DebugProvider
    Attributes
    protected
  44. def decodeFile(uri: String): Future[DecoderResponse]
  45. def definition(position: TextDocumentPositionParams): CompletableFuture[java.util.List[Location]]
  46. val definitionIndex: OnDemandSymbolIndex
    Attributes
    protected
  47. def definitionOrReferences(positionParams: TextDocumentPositionParams, token: CancelToken = EmptyCancelToken, definitionOnly: Boolean = false): Future[DefinitionResult]

    Returns the definition location or reference locations of a symbol at a given text document position.

    Returns the definition location or reference locations of a symbol at a given text document position. If the symbol represents the definition itself, this method returns the reference locations, otherwise this returns definition location. https://github.com/scalameta/metals/issues/755

  48. val definitionProvider: DefinitionProvider
    Attributes
    protected
  49. def definitionResult(position: TextDocumentPositionParams, token: CancelToken = EmptyCancelToken): Future[DefinitionResult]

    Returns textDocument/definition in addition to the resolved symbol.

    Returns textDocument/definition in addition to the resolved symbol.

    The resolved symbol is used for testing purposes only.

  50. val diagnostics: Diagnostics
    Attributes
    protected
  51. def didChange(params: DidChangeTextDocumentParams): CompletableFuture[Unit]
  52. def didChangeWatchedFiles(events: List[FileEvent]): Future[Unit]
  53. def didClose(params: DidCloseTextDocumentParams): Unit
  54. def didCompileTarget(report: CompileReport): Unit
    Attributes
    protected
  55. def didFocus(uri: String): CompletableFuture[DidFocusResult.Value]
  56. def didOpen(params: DidOpenTextDocumentParams): CompletableFuture[Unit]
  57. def didSave(params: DidSaveTextDocumentParams): CompletableFuture[Unit]
  58. def discoverMainClasses(unresolvedParams: DebugDiscoveryParams): Future[DebugSessionParams]
  59. def discoverTestSuites(uri: Option[String]): Future[List[BuildTargetUpdate]]
  60. val doctor: Doctor
  61. def documentHighlights(params: TextDocumentPositionParams): CompletableFuture[java.util.List[DocumentHighlight]]
  62. def documentSymbol(params: DocumentSymbolParams): CompletableFuture[org.eclipse.lsp4j.jsonrpc.messages.Either[java.util.List[DocumentSymbol], java.util.List[SymbolInformation]]]
  63. val documentSymbolProvider: DocumentSymbolProvider
    Attributes
    protected
  64. val embedded: Embedded
    Attributes
    protected
  65. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  66. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  67. var excludedPackageHandler: ExcludedPackagesHandler
  68. def executeCodeActionCommand(params: ExecuteCommandParams, token: CancelToken): Future[Unit]
  69. implicit val executionContext: ExecutionContextExecutorService
    Attributes
    protected
  70. val fileDecoderProvider: FileDecoderProvider
    Attributes
    protected
  71. def fileWatchFilter(path: Path): Boolean

    This filter is an optimization and it is closely related to which files are processed in didChangeWatchedFiles

    This filter is an optimization and it is closely related to which files are processed in didChangeWatchedFiles

    Attributes
    protected
  72. def findBuildTargetByDisplayName(target: String): Option[BuildTarget]
  73. def findTextInDependencyJars(params: FindTextInDependencyJarsRequest): Future[List[Location]]
  74. val findTextInJars: FindTextInDependencyJars
    Attributes
    protected
  75. val fingerprints: MutableMd5Fingerprints
    Attributes
    protected
  76. val focusedDocumentBuildTarget: AtomicReference[BuildTargetIdentifier]
    Attributes
    protected
  77. val folderReportsZippper: FolderReportsZippper
  78. def foldingRange(params: FoldingRangeRequestParams): CompletableFuture[java.util.List[FoldingRange]]
  79. val foldingRangeProvider: FoldingRangeProvider
    Attributes
    protected
  80. def formatting(params: DocumentFormattingParams): CompletableFuture[java.util.List[TextEdit]]
  81. val formattingProvider: FormattingProvider
    Attributes
    protected
  82. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @IntrinsicCandidate() @native()
  83. def getLocationForSymbol(symbol: String): Option[Location]
  84. def getTastyForURI(uri: URI): Future[Either[String, String]]
  85. def getVisibleName: String
  86. def gotoSupermethod(textDocumentPositionParams: TextDocumentPositionParams): CompletableFuture[AnyRef]
  87. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @IntrinsicCandidate() @native()
  88. def hover(params: HoverExtParams): CompletableFuture[Hover]
  89. def implementation(position: TextDocumentPositionParams): CompletableFuture[java.util.List[Location]]
  90. val implementationProvider: ImplementationProvider
    Attributes
    protected
  91. def importAfterScalaCliChanges(servers: Iterable[ScalaCli]): Iterable[Unit]
    Attributes
    protected
  92. def indexSources(): Future[Unit]
  93. val indexer: Indexer
    Attributes
    protected
  94. var indexingPromise: Promise[Unit]
  95. def initialized(): Future[Unit]
  96. def inlayHintResolve(inlayHint: InlayHint): CompletableFuture[InlayHint]
  97. val inlayHintResolveProvider: InlayHintResolveProvider
    Attributes
    protected
  98. def inlayHints(params: InlayHintParams): CompletableFuture[java.util.List[InlayHint]]
  99. val interactiveSemanticdbs: InteractiveSemanticdbs
    Attributes
    protected
  100. val isCancelled: AtomicBoolean
  101. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  102. lazy val isMetalsProject: Boolean
    Definition Classes
    Folder
  103. val javaFormattingProvider: JavaFormattingProvider
    Attributes
    protected
  104. val javaHighlightProvider: JavaDocumentHighlightProvider
    Attributes
    protected
  105. def javaHome: Option[String]
  106. def loadFingerPrints(): Future[Unit]
    Attributes
    protected
  107. def loadedPresentationCompilerCount(): Int
  108. val mainBuildTargetsData: TargetData
    Attributes
    protected
  109. def mainClassSearch(params: DebugUnresolvedMainClassParams): MainClassSearch
  110. def maybeCompileOnDidFocus(path: io.AbsolutePath, prevBuildTarget: BuildTargetIdentifier): Future[DidFocusResult.Value]
    Attributes
    protected
  111. val mtags: Mtags
    Attributes
    protected
  112. def nameOrUri: String
    Definition Classes
    Folder
  113. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  114. val newFileProvider: NewFileProvider
    Attributes
    protected
  115. def newSymbolIndex(): OnDemandSymbolIndex
    Attributes
    protected
  116. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @IntrinsicCandidate() @native()
  117. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @IntrinsicCandidate() @native()
  118. def onChange(paths: Seq[io.AbsolutePath]): Future[Unit]
    Attributes
    protected
  119. def onCreate(path: io.AbsolutePath): Unit
    Attributes
    protected
  120. def onDelete(path: io.AbsolutePath): Future[Unit]
    Attributes
    protected
  121. def onShutdown(): Unit
  122. def onTypeFormatting(params: DocumentOnTypeFormattingParams): CompletableFuture[java.util.List[TextEdit]]
  123. val onTypeFormattingProvider: OnTypeFormattingProvider
    Attributes
    protected
  124. def onUserConfigUpdate(newConfig: UserConfiguration): Future[Unit]
  125. def onWorksheetChanged(paths: Seq[io.AbsolutePath]): Future[Unit]
    Attributes
    protected
  126. lazy val optDelegatePath: Option[io.AbsolutePath]

    A workspace folder might be a project reference for an other project.

    A workspace folder might be a project reference for an other project. In that case all its commands will be delegated to the main project's service. We keep the path to main project's root in a dedicated setting, so even before the main project is imported, this folder is known to be a reference.

    Definition Classes
    Folder
  127. def optFileSystemSemanticdbs(): Option[FileSystemSemanticdbs]
  128. def optProjectRoot: Option[io.AbsolutePath]
    Attributes
    protected
  129. val packageProvider: PackageProvider
    Attributes
    protected
  130. val parseTrees: BatchedFunction[io.AbsolutePath, Unit]
  131. def parseTreesAndPublishDiags(paths: Seq[io.AbsolutePath]): Future[Unit]
  132. val path: io.AbsolutePath
    Definition Classes
    Folder
  133. def pause(): Unit
  134. def prepareCallHierarchy(params: CallHierarchyPrepareParams): CompletableFuture[java.util.List[CallHierarchyItem]]
  135. def prepareRename(params: TextDocumentPositionParams): CompletableFuture[org.eclipse.lsp4j.Range]
  136. def projectReferences: List[io.AbsolutePath]
    Definition Classes
    Folder
  137. def rangeFormatting(params: DocumentRangeFormattingParams): CompletableFuture[java.util.List[TextEdit]]
  138. val rangeFormattingProvider: RangeFormattingProvider
    Attributes
    protected
  139. val recentlyOpenedFiles: ActiveFiles
    Attributes
    protected
  140. def references(params: ReferenceParams): CompletableFuture[java.util.List[Location]]
  141. val referencesProvider: ReferenceProvider
    Attributes
    protected
  142. def referencesResult(params: ReferenceParams): Future[List[ReferencesResult]]
  143. def register[T <: Cancelable](cancelable: T): T
  144. def registerNiceToHaveFilePatterns(): Unit
    Attributes
    protected
  145. def rename(params: RenameParams): CompletableFuture[WorkspaceEdit]
  146. val renameProvider: RenameProvider
    Attributes
    protected
  147. implicit val reports: StdReportContext
  148. def resetNotifications(): Future[Unit]
  149. def resetService(): Unit
    Attributes
    protected
  150. def restartCompiler(): Future[Unit]
  151. def runScalafix(uri: String): Future[ApplyWorkspaceEditResponse]
  152. def runScalafixRules(uri: String, rules: List[String]): Future[ApplyWorkspaceEditResponse]
  153. val savedFiles: ActiveFiles
    Attributes
    protected
  154. val scalaCli: ScalaCliServers
  155. val scalaVersionSelector: ScalaVersionSelector
    Attributes
    protected
  156. val scalafixProvider: ScalafixProvider
    Attributes
    protected
  157. def selectionRange(params: SelectionRangeParams): CompletableFuture[java.util.List[SelectionRange]]
  158. val semanticDBIndexer: SemanticdbIndexer
    Attributes
    protected
  159. def semanticTokensFull(params: SemanticTokensParams): CompletableFuture[SemanticTokens]

    Requesting semantic tokens for a whole file in order to highlight

    Requesting semantic tokens for a whole file in order to highlight

    Definition Classes
    MetalsLspServiceTextDocumentService
  160. def setUserConfig(newConfig: UserConfiguration): UserConfiguration
  161. def signatureHelp(params: TextDocumentPositionParams): CompletableFuture[SignatureHelp]
  162. val sourceMapper: SourceMapper
    Attributes
    protected
  163. val stacktraceAnalyzer: StacktraceAnalyzer
  164. def startDebugProvider(params: DebugSessionParams): Future[DebugSession]
  165. def startScalaCli(path: io.AbsolutePath): Future[Unit]
  166. def startTestSuite(target: BuildTarget, params: ScalaTestSuitesDebugRequest): Future[DebugSession]
  167. def stopScalaCli(): Future[Unit]
  168. def superMethodHierarchy(textDocumentPositionParams: TextDocumentPositionParams): CompletableFuture[AnyRef]
  169. val supermethods: Supermethods
    Attributes
    protected
  170. def supportsBuildTarget(target: BuildTargetIdentifier): Option[BuildTarget]
  171. val symbolDocs: Docstrings
    Attributes
    protected
  172. val symbolHierarchyOps: SymbolHierarchyOps
    Attributes
    protected
  173. val symbolSearch: MetalsSymbolSearch
    Attributes
    protected
  174. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  175. val tables: Tables
  176. def testClassSearch(params: DebugUnresolvedTestClassParams): TestClassSearch
  177. val testProvider: TestSuitesProvider
    Attributes
    protected
  178. def toString(): String
    Definition Classes
    AnyRef → Any
  179. val trees: Trees
    Attributes
    protected
  180. def typeDefinition(position: TextDocumentPositionParams): CompletableFuture[java.util.List[Location]]
  181. def unpause(): Unit
  182. var userConfig: UserConfiguration
    Attributes
    protected
  183. val userConfigPromise: Promise[Unit]
    Attributes
    protected
  184. val visibleName: Option[String]
    Definition Classes
    Folder
  185. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  186. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  187. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  188. def warnings: Warnings
    Attributes
    protected
  189. val wasInitialized: AtomicBoolean
  190. def willRenameFile(oldPath: io.AbsolutePath, newPath: io.AbsolutePath): Future[WorkspaceEdit]
  191. val worksheetProvider: WorksheetProvider
  192. val workspaceReload: WorkspaceReload
    Attributes
    protected
  193. def workspaceSymbol(query: String): Seq[SymbolInformation]
  194. def workspaceSymbol(params: WorkspaceSymbolParams, token: CancelToken): Future[List[SymbolInformation]]
  195. val workspaceSymbols: WorkspaceSymbolProvider
    Attributes
    protected

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

    (Since version 9)

Inherited from TextDocumentService

Inherited from Cancelable

Inherited from Folder

Inherited from AnyRef

Inherited from Any

Ungrouped