Package: org.gradle.api.artifacts.maven

## [Java] Interface MavenResolver

- org.gradle.api.artifacts.repositories.ArtifactRepository

- All Superinterfaces:
    PomFilterContainer, ArtifactRepository

  An ArtifactRepository which can be used to publish artifacts to Maven repositories.

- - Inherited fields
    Fields inherited from class | Fields
    --- | ---
    `interface PomFilterContainer` | `DEFAULT_ARTIFACT_POM_NAME`

  - ### Methods Summary

    Methods
    Type | Name and description
    --- | ---
    `void` | `beforeDeployment(Action<? super MavenDeployment> action)` Adds an action to be executed immediately before a deployment to this resolver.
    `void` | `beforeDeployment(groovy.lang.Closure action)` Adds a closure to be executed immediately before a deployment to this resolver.
    `Object` | `getSettings()` Returns a Maven settings object.

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `interface ArtifactRepository` | `getName, setName`
    `interface PomFilterContainer` | `addFilter, addFilter, filter, filter, getActivePomFilters, getFilter, getPom, pom, pom, pom, setFilter, setPom`

- - ### Method Detail

    - #### public void beforeDeployment(Action<? super MavenDeployment> action)

      Adds an action to be executed immediately before a deployment to this resolver. The action is executed after all artifacts have been build, including generation of the POM. The action can modify the set of artifacts to be deployed.

      Parameters:
        `action` - The action to execute.

    - #### public void beforeDeployment(groovy.lang.Closure action)

      Adds a closure to be executed immediately before a deployment to this resolver. The closure is passed a MavenDeployment as a parameter. The closure is executed after all artifacts have been build, including generation of the POM. The closure can modify the set of artifacts to be deployed.

      Parameters:
        `action` - The closure to execute.

    - #### public Object getSettings()

      Returns a Maven settings object. This can be used for example to figure out where the local repository is located. This property is populated on demand.