Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Registering StructuredProgramming extension #9

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,6 @@ Require-Bundle: de.cau.cs.kieler.graphs.klighd,
org.eclipse.xtend.lib,
org.eclipse.xtext.ide,
org.eclipse.xtext.xbase.lib,
org.aopalliance
org.aopalliance,
de.cau.cs.kieler.core;bundle-version="1.4.0"
Export-Package: de.cau.cs.kieler.pragmatics.language.server
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@
*/
package de.cau.cs.kieler.pragmatics.language.server

import de.cau.cs.kieler.core.services.KielerServiceLoader
import de.cau.cs.kieler.klighd.lsp.KGraphLanguageClient
import de.cau.cs.kieler.klighd.lsp.interactive.layered.LayeredInteractiveLanguageServerExtension
import de.cau.cs.kieler.klighd.lsp.interactive.rectpacking.RectpackingInteractiveLanguageServerExtension
import de.cau.cs.kieler.klighd.lsp.launch.AbstractLsCreator
import de.cau.cs.kieler.klighd.lsp.structuredProgramming.IStructuredProgrammingLanguageServerContribution

/**
* Provides methods to create a LS.
Expand All @@ -29,12 +31,17 @@ class PragmaticsLsCreator extends AbstractLsCreator {

RectpackingInteractiveLanguageServerExtension rectPack


override getLanguageServerExtensions() {
constraints = injector.getInstance(LayeredInteractiveLanguageServerExtension)
rectPack = injector.getInstance(RectpackingInteractiveLanguageServerExtension)

val iLanguageServerExtensions = newArrayList(
injector.getInstance(PragmaticsRegistrationLanguageServerExtension), constraints, rectPack
)
for (lse : KielerServiceLoader.load(IStructuredProgrammingLanguageServerContribution)){
iLanguageServerExtensions.add(lse.getLanguageServerExtension(injector))
}
return iLanguageServerExtensions
}

Expand Down