org.ow2.petals.ant
Class AbstractConfigureArchiveAntTask

java.lang.Object
  extended by org.apache.tools.ant.ProjectComponent
      extended by org.apache.tools.ant.Task
          extended by org.ow2.petals.ant.AbstractConfigureArchiveAntTask
All Implemented Interfaces:
java.lang.Cloneable
Direct Known Subclasses:
ConfigureComponentTask, ConfigureServiceAssemblyTask

public class AbstractConfigureArchiveAntTask
extends org.apache.tools.ant.Task

Abstract class for all tasks configuring an archive.

Author:
rnaudin

Field Summary
protected  java.lang.String file
          Ant task attribute 'file' locating the archive to configure.
protected static java.lang.String JBIDESCRIPTOR_ZIPENTRY_NAME
           
protected  java.lang.String outputFile
          Ant task attribute 'outputFile' defined the filename of the archive configured.
protected  boolean overwriteOutputFile
          Overwrite the output archive
 
Fields inherited from class org.apache.tools.ant.Task
target, taskName, taskType, wrapper
 
Fields inherited from class org.apache.tools.ant.ProjectComponent
description, location, project
 
Constructor Summary
AbstractConfigureArchiveAntTask()
           
 
Method Summary
protected static java.io.File downloadURL(java.net.URL componentURL)
          Download the given URL into a File.
 void execute()
           
 java.lang.String getFile()
          File getter.
 java.lang.String getOutputFile()
          OutputFile getter.
 boolean isOverwriteOutputFile()
           
 void setFile(java.lang.String file)
          File setter.
 void setOutputFile(java.lang.String outputFile)
          OutputFile setter.
 void setOverwriteOutputFile(boolean overwriteOutputFile)
           
protected static java.net.URL validateFileParameter(java.lang.String fileParameter, java.lang.String paramaterName)
          Validate the file parameter.
 
Methods inherited from class org.apache.tools.ant.Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
 
Methods inherited from class org.apache.tools.ant.ProjectComponent
clone, getDescription, getLocation, getProject, setDescription, setLocation, setProject
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

JBIDESCRIPTOR_ZIPENTRY_NAME

protected static final java.lang.String JBIDESCRIPTOR_ZIPENTRY_NAME
See Also:
Constant Field Values

file

protected java.lang.String file
Ant task attribute 'file' locating the archive to configure.


outputFile

protected java.lang.String outputFile
Ant task attribute 'outputFile' defined the filename of the archive configured.


overwriteOutputFile

protected boolean overwriteOutputFile
Overwrite the output archive

Constructor Detail

AbstractConfigureArchiveAntTask

public AbstractConfigureArchiveAntTask()
Method Detail

execute

public void execute()
             throws org.apache.tools.ant.BuildException
Overrides:
execute in class org.apache.tools.ant.Task
Throws:
org.apache.tools.ant.BuildException

downloadURL

protected static final java.io.File downloadURL(java.net.URL componentURL)
                                         throws java.io.IOException
Download the given URL into a File.

Parameters:
componentURL -
Returns:
Throws:
java.io.IOException

validateFileParameter

protected static final java.net.URL validateFileParameter(java.lang.String fileParameter,
                                                          java.lang.String paramaterName)
                                                   throws org.apache.tools.ant.BuildException
Validate the file parameter. The file parameter should not be null and must be a jar or a zip archive.

Throws:
org.apache.tools.ant.BuildException

getFile

public java.lang.String getFile()
File getter.

Returns:

setFile

public void setFile(java.lang.String file)
File setter.

Parameters:
file -

getOutputFile

public java.lang.String getOutputFile()
OutputFile getter.

Returns:

setOutputFile

public void setOutputFile(java.lang.String outputFile)
OutputFile setter.

Parameters:
outputFile -

isOverwriteOutputFile

public boolean isOverwriteOutputFile()
Returns:
the overwriteOutputFile

setOverwriteOutputFile

public void setOverwriteOutputFile(boolean overwriteOutputFile)
Parameters:
overwriteOutputFile - the overwriteOutputFile to set


Copyright © 2005-2011 Petals Link (EBM Websourcing). All Rights Reserved.