com.atlassian.bamboo.build.artifact
Class ArtifactHandlingUtils

java.lang.Object
  extended by com.atlassian.bamboo.build.artifact.ArtifactHandlingUtils

public class ArtifactHandlingUtils
extends java.lang.Object


Method Summary
static void copyFileSet(org.apache.tools.ant.types.FileSet sourceFileSet, java.io.File destinationDirectory)
           
static org.apache.tools.ant.types.FileSet createFileSet(java.io.File baseDirectory, ArtifactDefinitionContext artifact, boolean useRelativeLocation, org.apache.log4j.Logger log)
          Creates a FileSet object.
static java.io.File getArtifactLocation(java.io.File baseDirectory, ArtifactDefinitionContext artifact, boolean useRelativeLocation)
           
static java.lang.String getArtifactMatchDescription(ArtifactDefinitionContext artifact, org.apache.tools.ant.types.FileSet sourceFileSet)
           
static void moveFileSet(org.apache.tools.ant.types.FileSet sourceFileSet, java.io.File destinationDirectory)
           
static com.google.common.collect.Ordering<ArtifactHandler> speedOrdering(java.util.Map<java.lang.String,java.lang.String> artifactHandlersConfiguration)
           
static void transferFileSet(org.apache.tools.ant.types.FileSet sourceFileSet, java.io.File destinationDirectory, boolean deleteSource, boolean debug)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

createFileSet

@NotNull
public static org.apache.tools.ant.types.FileSet createFileSet(java.io.File baseDirectory,
                                                                       ArtifactDefinitionContext artifact,
                                                                       boolean useRelativeLocation,
                                                                       @Nullable
                                                                       org.apache.log4j.Logger log)
                                                        throws java.io.FileNotFoundException
Creates a FileSet object.

Parameters:
baseDirectory - directory used to resolve the copy patterns
artifact - artifact definition
useRelativeLocation - used to determine whether the relative location information from artifact definition should be used
log - optional logger to use for logging of fileset processing
Returns:
the created FileSet
Throws:
java.lang.IllegalArgumentException - if the artifact source is not a directory
java.io.FileNotFoundException

copyFileSet

public static void copyFileSet(org.apache.tools.ant.types.FileSet sourceFileSet,
                               java.io.File destinationDirectory)
                        throws java.io.IOException
Throws:
java.io.IOException

moveFileSet

public static void moveFileSet(org.apache.tools.ant.types.FileSet sourceFileSet,
                               java.io.File destinationDirectory)
                        throws java.io.IOException
Throws:
java.io.IOException

transferFileSet

public static void transferFileSet(org.apache.tools.ant.types.FileSet sourceFileSet,
                                   java.io.File destinationDirectory,
                                   boolean deleteSource,
                                   boolean debug)
                            throws java.io.IOException
Throws:
java.io.IOException

getArtifactLocation

@NotNull
public static java.io.File getArtifactLocation(@NotNull
                                                       java.io.File baseDirectory,
                                                       @NotNull
                                                       ArtifactDefinitionContext artifact,
                                                       boolean useRelativeLocation)

getArtifactMatchDescription

@NotNull
public static java.lang.String getArtifactMatchDescription(@NotNull
                                                                   ArtifactDefinitionContext artifact,
                                                                   @NotNull
                                                                   org.apache.tools.ant.types.FileSet sourceFileSet)

speedOrdering

public static com.google.common.collect.Ordering<ArtifactHandler> speedOrdering(@NotNull
                                                                                java.util.Map<java.lang.String,java.lang.String> artifactHandlersConfiguration)


Copyright © 2012 Atlassian. All Rights Reserved.