Package: org.gradle.api.plugins

## [Java] Class LegacyJavaComponentPlugin

- org.gradle.api.plugins.LegacyJavaComponentPlugin

- All Implemented Interfaces and Traits:
    Plugin

      @Incubating
      public class LegacyJavaComponentPlugin
      extends Object

  Plugin for compiling Java code. Applies the LanguageBasePlugin. Base plugin for Java language support. Applies the LanguageBasePlugin. Registers the ClassDirectoryBinarySpec element type for the BinaryContainer. Adds a lifecycle task named `classes` for each ClassDirectoryBinarySpec. Adds a JavaCompile task for each JavaSourceSet added to a ClassDirectoryBinarySpec.

- - ### Constructor Summary

    Constructors
    Constructor and description
    `LegacyJavaComponentPlugin (org.gradle.internal.reflect.Instantiator instantiator, JavaToolChain toolChain)`

  - ### Methods Summary

    Methods
    Type | Name and description
    --- | ---
    `void` | `apply(Project target)`
    `void` | `configureCompileTask(AbstractCompile compile, JavaSourceSet sourceSet, ClassDirectoryBinarySpec binary)` Preconfigures the specified compile task based on the specified source set and class directory binary.

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class Object` | `wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll`

- - ### Constructor Detail

    - #### @javax.inject.Inject public LegacyJavaComponentPlugin(org.gradle.internal.reflect.Instantiator instantiator, JavaToolChain toolChain)

  - ### Method Detail

    - #### public void apply(Project target)

    - #### public void configureCompileTask(AbstractCompile compile, JavaSourceSet sourceSet, ClassDirectoryBinarySpec binary)

      Preconfigures the specified compile task based on the specified source set and class directory binary.

      Parameters:
        `compile` - the compile task to be preconfigured
        `sourceSet` - the source set for the compile task
        `binary` - the binary for the compile task