|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.plexus.logging.AbstractLogEnabled
org.codehaus.plexus.archiver.AbstractArchiver
org.codehaus.plexus.archiver.zip.AbstractZipArchiver
org.codehaus.plexus.archiver.zip.ZipArchiver
org.codehaus.plexus.archiver.jar.JarArchiver
org.codehaus.plexus.archiver.war.WarArchiver
public class WarArchiver
An extension of <jar> to create a WAR archive.
Contains special treatment for files that should end up in the
WEB-INF/lib
, WEB-INF/classes
or
WEB-INF
directories of the Web Application Archive.
(The War task is a shortcut for specifying the particular layout of a WAR file. The same thing can be accomplished by using the prefix and fullpath attributes of zipfilesets in a Zip or Jar task.)
The extended zipfileset element from the zip task (with attributes prefix, fullpath, and src) is available in the War task.
JarArchiver
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.codehaus.plexus.archiver.jar.JarArchiver |
---|
JarArchiver.FilesetManifestConfig |
Field Summary |
---|
Fields inherited from class org.codehaus.plexus.archiver.zip.AbstractZipArchiver |
---|
addedDirs, addingNewFiles, archiveType, doubleFilePass, duplicate, entries, skipWriting |
Fields inherited from interface org.codehaus.plexus.archiver.Archiver |
---|
DEFAULT_DIR_MODE, DEFAULT_FILE_MODE, DUPLICATES_ADD, DUPLICATES_FAIL, DUPLICATES_PRESERVE, DUPLICATES_SKIP, DUPLICATES_VALID_BEHAVIORS, ROLE |
Constructor Summary | |
---|---|
WarArchiver()
|
Method Summary | |
---|---|
void |
addClass(java.io.File fileName)
add a file under WEB-INF/lib/ |
void |
addClasses(java.io.File directoryName,
java.lang.String[] includes,
java.lang.String[] excludes)
add files under WEB-INF/classes |
void |
addLib(java.io.File fileName)
add a file under WEB-INF/lib/ |
void |
addLibs(java.io.File directoryName,
java.lang.String[] includes,
java.lang.String[] excludes)
add files under WEB-INF/lib/ |
void |
addWebinf(java.io.File directoryName,
java.lang.String[] includes,
java.lang.String[] excludes)
files to add under WEB-INF; |
protected void |
cleanUp()
Make sure we don't think we already have a web.xml next time this task gets executed. |
protected void |
initZipOutputStream(ZipOutputStream zOut)
override of parent; validates configuration before initializing the output stream. |
void |
setIgnoreWebxml(boolean ignore)
|
void |
setWebxml(java.io.File descr)
set the deployment descriptor to use (WEB-INF/web.xml); required unless update=true |
protected void |
zipFile(ArchiveEntry entry,
ZipOutputStream zOut,
java.lang.String vPath,
int mode)
Overridden from ZipArchiver class to deal with web.xml |
Methods inherited from class org.codehaus.plexus.archiver.jar.JarArchiver |
---|
addConfiguredIndexJars, addConfiguredManifest, createEmptyZip, finalizeZipOutputStream, findJarName, grabFilesAndDirs, hasVirtualFiles, reset, setFilesetmanifest, setIndex, setManifest, setManifestEncoding, writeIndexLikeList, zipFile |
Methods inherited from class org.codehaus.plexus.archiver.zip.AbstractZipArchiver |
---|
addParentDirs, addResources, close, execute, getArchiveType, getComment, getEncoding, getZipEntryNames, isCompress, isFileAdded, isFilesonly, isFileUpdated, isInUpdateMode, isRoundUp, isSupportingForced, revert, setComment, setCompress, setEncoding, setFilesonly, setRoundUp, setUpdateMode, zipDir, zipFile |
Methods inherited from class org.codehaus.plexus.logging.AbstractLogEnabled |
---|
enableLogging, setupLogger, setupLogger, setupLogger |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public WarArchiver()
Method Detail |
---|
public void setIgnoreWebxml(boolean ignore)
public void setWebxml(java.io.File descr) throws ArchiverException
ArchiverException
public void addLib(java.io.File fileName) throws ArchiverException
ArchiverException
public void addLibs(java.io.File directoryName, java.lang.String[] includes, java.lang.String[] excludes) throws ArchiverException
ArchiverException
public void addClass(java.io.File fileName) throws ArchiverException
ArchiverException
public void addClasses(java.io.File directoryName, java.lang.String[] includes, java.lang.String[] excludes) throws ArchiverException
ArchiverException
public void addWebinf(java.io.File directoryName, java.lang.String[] includes, java.lang.String[] excludes) throws ArchiverException
ArchiverException
protected void initZipOutputStream(ZipOutputStream zOut) throws java.io.IOException, ArchiverException
initZipOutputStream
in class JarArchiver
java.io.IOException
ArchiverException
protected void zipFile(ArchiveEntry entry, ZipOutputStream zOut, java.lang.String vPath, int mode) throws java.io.IOException, ArchiverException
java.io.IOException
ArchiverException
protected void cleanUp()
cleanUp
in class JarArchiver
AbstractZipArchiver.cleanUp()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |