Search in sources :

Example 1 with LanguageServerWorkingCopyOwner

use of org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner in project eclipse.jdt.ls by eclipse.

the class CodeActionResolveHandlerTest method setup.

@Override
@Before
public void setup() throws Exception {
    IJavaProject fJProject = newEmptyProject();
    fJProject.setOptions(TestOptions.getDefaultOptions());
    IPackageFragmentRoot fSourceFolder = fJProject.getPackageFragmentRoot(fJProject.getProject().getFolder("src"));
    defaultPackage = fSourceFolder.getPackageFragment("");
    wcOwner = new LanguageServerWorkingCopyOwner(connection);
    server = new JDTLanguageServer(projectsManager, this.preferenceManager);
}
Also used : IJavaProject(org.eclipse.jdt.core.IJavaProject) IPackageFragmentRoot(org.eclipse.jdt.core.IPackageFragmentRoot) LanguageServerWorkingCopyOwner(org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner) Before(org.junit.Before)

Example 2 with LanguageServerWorkingCopyOwner

use of org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner in project eclipse.jdt.ls by eclipse.

the class AbstractCompilationUnitBasedTest method setup.

@Before
public void setup() throws Exception {
    importProjects("eclipse/hello");
    project = WorkspaceHelper.getProject("hello");
    wcOwner = new LanguageServerWorkingCopyOwner(connection);
    server = new JDTLanguageServer(projectsManager, preferenceManager);
    JavaCore.initializeAfterLoad(null);
}
Also used : LanguageServerWorkingCopyOwner(org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner) Before(org.junit.Before)

Example 3 with LanguageServerWorkingCopyOwner

use of org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner in project eclipse.jdt.ls by eclipse.

the class GenerateToStringActionTest method setUp.

@Before
public void setUp() throws Exception {
    fJavaProject = newEmptyProject();
    fRoot = fJavaProject.findPackageFragmentRoot(fJavaProject.getPath().append("src"));
    assertNotNull(fRoot);
    fPackageP = fRoot.createPackageFragment("p", true, null);
    wcOwner = new LanguageServerWorkingCopyOwner(connection);
    server = new JDTLanguageServer(projectsManager, this.preferenceManager);
}
Also used : LanguageServerWorkingCopyOwner(org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner) Before(org.junit.Before)

Example 4 with LanguageServerWorkingCopyOwner

use of org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner in project eclipse.jdt.ls by eclipse.

the class GenerateDelegateMethodsActionTest method setUp.

@Before
public void setUp() throws Exception {
    fJavaProject = newEmptyProject();
    fRoot = fJavaProject.findPackageFragmentRoot(fJavaProject.getPath().append("src"));
    assertNotNull(fRoot);
    fPackageP = fRoot.createPackageFragment("p", true, null);
    wcOwner = new LanguageServerWorkingCopyOwner(connection);
    server = new JDTLanguageServer(projectsManager, this.preferenceManager);
}
Also used : LanguageServerWorkingCopyOwner(org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner) Before(org.junit.Before)

Example 5 with LanguageServerWorkingCopyOwner

use of org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner in project eclipse.jdt.ls by eclipse.

the class JDTLanguageServer method connectClient.

@Override
public void connectClient(JavaLanguageClient client) {
    super.connectClient(client);
    progressReporterManager = new ProgressReporterManager(client, preferenceManager);
    Job.getJobManager().setProgressProvider(progressReporterManager);
    this.workingCopyOwner = new LanguageServerWorkingCopyOwner(this.client);
    pm.setConnection(client);
    WorkingCopyOwner.setPrimaryBufferProvider(this.workingCopyOwner);
    this.documentLifeCycleHandler = new DocumentLifeCycleHandler(this.client, preferenceManager, pm, true);
}
Also used : LanguageServerWorkingCopyOwner(org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner)

Aggregations

LanguageServerWorkingCopyOwner (org.eclipse.jdt.ls.core.internal.LanguageServerWorkingCopyOwner)10 Before (org.junit.Before)9 IJavaProject (org.eclipse.jdt.core.IJavaProject)1 IPackageFragmentRoot (org.eclipse.jdt.core.IPackageFragmentRoot)1