Examples of GZipTarFile


Examples of org.codehaus.plexus.archiver.tar.GZipTarFile

    public static void assertTarContents( Set<String> required, Set<String> banned, File assembly )
        throws IOException
    {
        assertTrue( "Assembly archive missing: " + assembly, assembly.isFile() );

        GZipTarFile tarFile = null;
        try
        {
            tarFile = new GZipTarFile( assembly );

            LinkedHashSet<String> pathSet = new LinkedHashSet<String>();

            for ( @SuppressWarnings( "unchecked" )
            Enumeration<TarEntry> enumeration = tarFile.getEntries(); enumeration.hasMoreElements(); )
            {
                pathSet.add( enumeration.nextElement().getName() );
            }
            assertArchiveContents( required, banned, assembly.getAbsolutePath(), pathSet );
        }
        finally
        {
            if ( tarFile != null )
            {
                tarFile.close();
            }
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.