Search in sources :

Example 1 with BuildSystemService

use of com.android.tools.idea.project.BuildSystemService in project android by JetBrains.

the class HtmlLinkManager method handleAddDependency.

private static void handleAddDependency(@NotNull String url, @NotNull final Module module) {
    assert url.startsWith(URL_ADD_DEPENDENCY) : url;
    BuildSystemService service = BuildSystemService.getInstance(module.getProject());
    if (service != null) {
        String dependency = url.substring(URL_ADD_DEPENDENCY.length());
        service.addDependency(module, dependency);
    }
}
Also used : BuildSystemService(com.android.tools.idea.project.BuildSystemService)

Example 2 with BuildSystemService

use of com.android.tools.idea.project.BuildSystemService in project intellij by bazelbuild.

the class BlazeBuildSystemServiceTest method initTest.

@Override
protected void initTest(Container applicationServices, Container projectServices) {
    module = new MockModule(project, () -> {
    });
    // For Blaze.isBlazeProject.
    mockBlazeImportSettings(projectServices);
    createMocksForBuildProject(applicationServices);
    createMocksForSyncProject(projectServices);
    createMocksForAddDependency(applicationServices, projectServices);
    ExtensionPoint<BuildSystemService> extensionPoint = registerExtensionPoint(ExtensionPointName.create("com.android.project.buildSystemService"), BuildSystemService.class);
    extensionPoint.registerExtension(new BlazeBuildSystemService());
    service = BuildSystemService.getInstance(project);
}
Also used : BuildSystemService(com.android.tools.idea.project.BuildSystemService) MockModule(com.intellij.mock.MockModule)

Aggregations

BuildSystemService (com.android.tools.idea.project.BuildSystemService)2 MockModule (com.intellij.mock.MockModule)1