org.sonatype.aether.deployment
Class DeployResult

java.lang.Object
  extended by org.sonatype.aether.deployment.DeployResult

public class DeployResult
extends java.lang.Object

The result of deploying artifacts and their accompanying metadata into the a remote repository.

Author:
Benjamin Bentmann
See Also:
RepositorySystem.deploy(RepositorySystemSession, DeployRequest)

Constructor Summary
DeployResult(DeployRequest request)
          Creates a new result for the specified request.
 
Method Summary
 DeployResult addArtifact(Artifact artifact)
          Adds the specified artifacts to the result.
 DeployResult addMetadata(Metadata metadata)
          Adds the specified metadata to this result.
 java.util.Collection<Artifact> getArtifacts()
          Gets the artifact that got deployed.
 java.util.Collection<Metadata> getMetadata()
          Gets the metadata that got deployed.
 DeployRequest getRequest()
          Gets the deploy request that was made.
 DeployResult setArtifacts(java.util.Collection<Artifact> artifacts)
          Sets the artifacts that got deployed.
 DeployResult setMetadata(java.util.Collection<Metadata> metadata)
          Sets the metadata that got deployed.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DeployResult

public DeployResult(DeployRequest request)
Creates a new result for the specified request.

Parameters:
request - The deployment request, must not be null.
Method Detail

getRequest

public DeployRequest getRequest()
Gets the deploy request that was made.

Returns:
The deploy request, never null.

getArtifacts

public java.util.Collection<Artifact> getArtifacts()
Gets the artifact that got deployed.

Returns:
The artifacts to deploy, never null.

setArtifacts

public DeployResult setArtifacts(java.util.Collection<Artifact> artifacts)
Sets the artifacts that got deployed.

Parameters:
artifacts - The deployed artifacts, may be null.
Returns:
This result for chaining, never null.

addArtifact

public DeployResult addArtifact(Artifact artifact)
Adds the specified artifacts to the result.

Parameters:
artifact - The deployed artifact to add, may be null.
Returns:
This result for chaining, never null.

getMetadata

public java.util.Collection<Metadata> getMetadata()
Gets the metadata that got deployed. Note that due to automatically generated metadata, there might have been more metadata deployed than originally specified in the deploy request.

Returns:
The deployed metadata, never null.

setMetadata

public DeployResult setMetadata(java.util.Collection<Metadata> metadata)
Sets the metadata that got deployed.

Parameters:
metadata - The deployed metadata, may be null.
Returns:
This result for chaining, never null.

addMetadata

public DeployResult addMetadata(Metadata metadata)
Adds the specified metadata to this result.

Parameters:
metadata - The deployed metadata to add, may be null.
Returns:
This result for chaining, never null.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2010-2011 Sonatype, Inc.. All Rights Reserved.