java.lang.Object
org.apache.maven.plugins.dependency.utils.CopyUtil

@Named @Singleton public class CopyUtil extends Object
Provide a copyFile method in one place.
Since:
3.7.0
  • Constructor Summary

    Constructors
    Constructor
    Description
    CopyUtil(org.sonatype.plexus.build.incremental.BuildContext buildContext)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    copyArtifactFile(org.apache.maven.artifact.Artifact sourceArtifact, File destination)
    Does the actual copy of the artifact (file) and logging.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • CopyUtil

      @Inject public CopyUtil(org.sonatype.plexus.build.incremental.BuildContext buildContext)
  • Method Details

    • copyArtifactFile

      public void copyArtifactFile(org.apache.maven.artifact.Artifact sourceArtifact, File destination) throws IOException, org.apache.maven.plugin.MojoExecutionException
      Does the actual copy of the artifact (file) and logging.
      Parameters:
      sourceArtifact - represents the artifact (file) to copy.
      destination - file name of destination file.
      Throws:
      IOException - if copy has failed
      org.apache.maven.plugin.MojoExecutionException - if artifact file is a directory (which has not been packaged yet)
      Since:
      3.7.0