use of org.gradle.jvm.toolchain.internal.DefaultToolchainSpec in project gradle by gradle.
the class JavaBasePlugin method addExtensions.
private DefaultJavaPluginExtension addExtensions(final ProjectInternal project) {
DefaultToolchainSpec toolchainSpec = project.getObjects().newInstance(DefaultToolchainSpec.class);
SourceSetContainer sourceSets = (SourceSetContainer) project.getExtensions().getByName("sourceSets");
DefaultJavaPluginExtension javaPluginExtension = (DefaultJavaPluginExtension) project.getExtensions().create(JavaPluginExtension.class, "java", DefaultJavaPluginExtension.class, project, sourceSets, toolchainSpec, jvmPluginServices);
project.getConvention().getPlugins().put("java", new DefaultJavaPluginConvention(project, javaPluginExtension));
project.getExtensions().create(JavaToolchainService.class, "javaToolchains", DefaultJavaToolchainService.class, getJavaToolchainQueryService());
return javaPluginExtension;
}
Aggregations