use of org.jetbrains.plugins.gradle.model.ExtIdeaCompilerOutput in project android by JetBrains.
the class CompilerOutputModuleSetupStep method doSetUpModule.
@Override
protected void doSetUpModule(@NotNull Module module, @NotNull IdeModifiableModelsProvider ideModelsProvider, @NotNull JavaModuleModel javaModuleModel, @Nullable SyncAction.ModuleModels gradleModels, @Nullable ProgressIndicator indicator) {
File mainClassesFolder = null;
File testClassesFolder = null;
ExtIdeaCompilerOutput compilerOutput = javaModuleModel.getCompilerOutput();
if (compilerOutput == null) {
File buildFolderPath = javaModuleModel.getBuildFolderPath();
if (buildFolderPath != null) {
mainClassesFolder = new File(buildFolderPath, join(CLASSES_FOLDER_NAME, "main"));
testClassesFolder = new File(buildFolderPath, join(CLASSES_FOLDER_NAME, "test"));
}
} else {
mainClassesFolder = compilerOutput.getMainClassesDir();
testClassesFolder = compilerOutput.getTestClassesDir();
}
if (mainClassesFolder != null) {
// This folder is null for modules that are just folders containing other modules. This type of modules are later on removed by
// PostProjectSyncTaskExecutor.
ModifiableRootModel moduleModel = ideModelsProvider.getModifiableRootModel(module);
myCompilerSettingsSetup.setOutputPaths(moduleModel, mainClassesFolder, testClassesFolder);
}
}
Aggregations