Changes for page Running KEITH
Last modified by Richard Kreissig on 2023/09/14 08:48
Change comment:
There is no comment for this version
Summary
-
Page properties (1 modified, 0 added, 0 removed)
-
Objects (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -2,7 +2,7 @@ 2 2 3 3 4 4 5 -{{toc/}} 5 +{{toc maxLevel="2"/}} 6 6 7 7 == Setting up your eclipse == 8 8 ... ... @@ -143,8 +143,6 @@ 143 143 144 144 The {{code language="none"}}LSP_PORT{{/code}} option is used to activate the connection via socket. It is also possible to specify a relative location to a LS via {{code language="none"}}LS_PATH=<path to LS>{{/code}}. 145 145 146 -You can also set these options for an already build [[keith electron app>>url:http://rtsys.informatik.uni-kiel.de/~~kieler/files/nightly/sccharts-integration/||shape="rect"]]. 147 - 148 148 \\ 149 149 150 150 == How run KEITH in developer setup (socket) == ... ... @@ -177,9 +177,9 @@ 177 177 178 178 We use java ServiceLoader to register stuff. Here is a small example how a LanguageServerExtension is registered via a ServiceLoader and how it is used: 179 179 180 -== ServiceLoader Example == 178 +== Register LanguageServerExtensions (ServiceLoader Example) == 181 181 182 -This is a LanguageServerExtension. It has to be used in the de.cau.cs.kieler.language.server plugin. Since the language-sever-plugin should not have dependencies to all plugins that define a language server extension dependency inversion is used to prevent that. A ServiceLoader does exactly that. 180 +This is a LanguageServerExtension. It has to be used in the de.cau.cs.kieler.language.server plugin. Since the language-server-plugin should not have dependencies to all plugins that define a language server extension dependency inversion is used to prevent that. A ServiceLoader does exactly that. 183 183 184 184 Here is such an example extension, the KiCoolLanguageServerExtension: 185 185 ... ... @@ -192,11 +192,23 @@ 192 192 * 193 193 */ 194 194 @Singleton 195 -class KiCoolLanguageServerExtension implements ILanguageServerExtension, CommandExtension { 196 - // fancy extension stuff 193 +class KiCoolLanguageServerExtension implements ILanguageServerExtension, CommandExtension, ILanguageClientProvider { 194 + // fancy extension stuff 195 + 196 + // A language server extension must implement the initialize method, 197 + // it is however only called if the extension is registered via a language. 198 + // This should never be the case, so this is never called. 199 + override initialize(ILanguageServerAccess access) { 200 + this.languageServerAccess = access 201 + } 202 + 197 197 } 198 198 {{/code}} 199 199 206 +The CommandExtension defines all commands (requests or notifications) that are send from client to server. An example how this looks like can be seen in the code snippet Example CommandExtension in the section Register an extension (on server side). 207 + 208 +\\ 209 + 200 200 This language server extension is provided by a corresponding contribution, which is later used to access it: 201 201 202 202 {{code}} ... ... @@ -242,7 +242,7 @@ 242 242 243 243 What is still missing are the contents of the CommandExtension implemented by the KiCoolLanguageServerExtension. This is an interface defining all additional commands. The CommandExtension looks like this. 244 244 245 -{{code}} 255 +{{code title="Example CommandExtension"}} 246 246 package de.cau.cs.kieler.kicool.ide.language.server 247 247 248 248 import java.util.concurrent.CompletableFuture ... ... @@ -358,4 +358,8 @@ 358 358 359 359 Look at examples in KEITH or Theia to see how this is done. 360 360 371 +== How to make a new module for sprotty (see actionModule, ...) == 372 + 373 +WIP 374 + 361 361 \\
- Confluence.Code.ConfluencePageClass[0]
-
- Id
-
... ... @@ -1,1 +1,1 @@ 1 -5 68525361 +57802992 - URL
-
... ... @@ -1,1 +1,1 @@ 1 -https://rtsys.informatik.uni-kiel.de/confluence//wiki/spaces/KIELER/pages/5 6852536/Running KEITH1 +https://rtsys.informatik.uni-kiel.de/confluence//wiki/spaces/KIELER/pages/57802992/Running KEITH