|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectTask
installtoolkit.InstallerGeneratorTask
public abstract class InstallerGeneratorTask
Base class for installer-builder tasks.
This class holds common functions for all install-builder
tasks and handles the reading of the descriptorfile.
Field Summary | |
---|---|
protected boolean |
debug
|
protected java.io.File |
descriptor
|
static java.lang.String |
DESCRIPTOR_NAMESPACE
The XML Namespace of the desriptor file |
protected java.io.File |
destdir
|
protected java.lang.String |
email
|
protected java.util.List<java.lang.String> |
license
|
protected java.util.List<java.lang.String> |
longDescription
|
protected java.lang.String |
manufacturer
|
protected java.lang.String |
packageName
|
protected java.io.File |
schema
|
protected java.lang.String |
shortDescription
|
protected boolean |
validate
|
protected java.lang.String |
version
|
protected java.io.File |
workdir
|
Constructor Summary | |
---|---|
InstallerGeneratorTask()
|
Method Summary | |
---|---|
protected abstract void |
build()
The build() method must be overridden by the concrete install-builder classes. |
protected void |
copy(java.io.File src,
java.io.File dst)
Copy a file |
protected FileSet |
createFilesetFromPatterns(java.util.List<Pattern> patterns,
java.io.File dir)
Create an Ant FileSet from a list of patterns |
void |
execute()
The execute method reads the descriptor file and executes the logic of the concrete class by calling the build() method. |
protected void |
readDebTag(Element root)
This method should be overridden if the task needs informations from the <Deb> element of the descriptor file. |
protected java.util.List<Pattern> |
readPatterns(Element root)
Read patterns from the descriptor file |
protected void |
readWindowsTag(Element root)
This method should be overridden if the task needs informations from the <Win> element of the descriptor file. |
void |
setDebug(boolean debug)
Enable debug output |
void |
setDescriptor(java.io.File descriptor)
The descriptor file to read |
void |
setDestdir(java.io.File destdir)
The directory where the installer packge will be created |
void |
setSchema(java.io.File schema)
The XML Schema for the descriptor file |
void |
setValidate(boolean validate)
If false, the descriptor file will not be validated |
void |
setVersion(java.lang.String version)
The version number of the generatd installer package |
void |
setWorkdir(java.io.File workdir)
The directory to compile the installer package |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String DESCRIPTOR_NAMESPACE
protected boolean debug
protected java.lang.String version
protected java.io.File descriptor
protected java.io.File destdir
protected java.io.File workdir
protected boolean validate
protected java.io.File schema
protected java.lang.String packageName
protected java.lang.String manufacturer
protected java.lang.String email
protected java.lang.String shortDescription
protected java.util.List<java.lang.String> longDescription
protected java.util.List<java.lang.String> license
Constructor Detail |
---|
public InstallerGeneratorTask()
Method Detail |
---|
public void execute() throws BuildException
BuildException
Task#execute()
protected abstract void build() throws java.lang.Exception
java.lang.Exception
protected void readWindowsTag(Element root)
root
- protected void readDebTag(Element root)
root
- protected java.util.List<Pattern> readPatterns(Element root)
root
- The element containig <Include> and <Exclude> Elements as childsprotected FileSet createFilesetFromPatterns(java.util.List<Pattern> patterns, java.io.File dir)
patterns
- List of Patternsdir
- The basedirectory for the fileset
protected void copy(java.io.File src, java.io.File dst)
src
- Source filedst
- Destination filepublic void setDebug(boolean debug)
debug
- public void setDescriptor(java.io.File descriptor)
descriptor
- public void setVersion(java.lang.String version)
version
- public void setSchema(java.io.File schema)
schema
- public void setValidate(boolean validate)
validate
- public void setDestdir(java.io.File destdir)
destdir
- public void setWorkdir(java.io.File workdir)
workdir
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |