Class Ear

  • All Implemented Interfaces:
    java.lang.Cloneable, SelectorContainer

    public class Ear
    extends Jar
    Creates a EAR archive. Based on WAR task
    Since:
    Ant 1.4
    • Constructor Detail

      • Ear

        public Ear()
        Create an Ear task.
    • Method Detail

      • setEarfile

        @Deprecated
        public void setEarfile​(java.io.File earFile)
        Deprecated.
        since 1.5.x. Use setDestFile(destfile) instead.
        Set the destination file.
        Parameters:
        earFile - the destination file
      • setAppxml

        public void setAppxml​(java.io.File descr)
        File to incorporate as application.xml.
        Parameters:
        descr - the descriptor file
      • addArchives

        public void addArchives​(ZipFileSet fs)
        Adds zipfileset.
        Parameters:
        fs - zipfileset to add
      • zipFile

        protected void zipFile​(java.io.File file,
                               ZipOutputStream zOut,
                               java.lang.String vPath,
                               int mode)
                        throws java.io.IOException
        Overridden from Zip class to deal with application.xml
        Overrides:
        zipFile in class Zip
        Parameters:
        file - the file to add to the archive
        zOut - the stream to write to
        vPath - the name this entry shall have in the archive
        mode - the Unix permissions to set.
        Throws:
        java.io.IOException - on error
      • cleanUp

        protected void cleanUp()
        Make sure we don't think we already have a application.xml next time this task gets executed.
        Overrides:
        cleanUp in class Jar
        See Also:
        Zip.cleanUp()