org.gradle.api.artifacts

## Interface ArtifactView

- All Superinterfaces:
    HasAttributes, HasConfigurableAttributes<ArtifactView>

      @Incubating
      public interface ArtifactView
      extends HasConfigurableAttributes<ArtifactView>

  A view over the artifacts resolved for this set of dependencies. By default, the view returns all files and artifacts, but this can be restricted by component identifier or by attributes.
  Since:
    3.4

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `ArtifactView` | `componentFilter(Spec<? super ComponentIdentifier> componentFilter)` Specify a filter for the components that should be included in this view.
    `ArtifactCollection` | `getArtifacts()` Returns the collection of artifacts matching the requested attributes that are sourced from Components matching the specified filter.
    `FileCollection` | `getFiles()` Returns the collection of artifact files matching the requested attributes that are sourced from Components matching the specified filter.

    - ### Methods inherited from interface org.gradle.api.attributes.HasConfigurableAttributes

      `attributes`

    - ### Methods inherited from interface org.gradle.api.attributes.HasAttributes

      `getAttributes`

- - ### Method Detail

    - #### componentFilter

          @Incubating
          ArtifactView componentFilter(Spec<? super ComponentIdentifier> componentFilter)

      Specify a filter for the components that should be included in this view. Only artifacts from components matching the supplied filter will be returned by `getFiles()` or `getArtifacts()`. This method cannot be called a multiple times for a view.

    - #### getArtifacts

          @Incubating
          ArtifactCollection getArtifacts()

      Returns the collection of artifacts matching the requested attributes that are sourced from Components matching the specified filter.

    - #### getFiles

          @Incubating
          FileCollection getFiles()

      Returns the collection of artifact files matching the requested attributes that are sourced from Components matching the specified filter.