Examples of ArchiverException


Examples of org.codehaus.plexus.archiver.ArchiverException

                    manifest = getManifest( file );
                }
            }
            catch ( UnsupportedEncodingException e )
            {
                throw new ArchiverException( "Unsupported encoding while reading "
                                             + "manifest: " + e.getMessage(), e );
            }
        }
        else if ( ( filesetManifestConfig != null )
                  && !filesetManifestConfig.getValue().equals( "skip" ) )
        {
            // we add this to our group of fileset manifests
            getLogger().debug( "Found manifest to merge in file " + file );

            try
            {
                Manifest newManifest;
                if ( is != null )
                {
                    Reader reader;
                    if ( manifestEncoding == null )
                    {
                        reader = new InputStreamReader( is );
                    }
                    else
                    {
                        reader = new InputStreamReader( is, manifestEncoding );
                    }
                    newManifest = getManifest( reader );
                }
                else
                {
                    newManifest = getManifest( file );
                }

                if ( filesetManifest == null )
                {
                    filesetManifest = newManifest;
                }
                else
                {
                    filesetManifest.merge( newManifest );
                }
            }
            catch ( UnsupportedEncodingException e )
            {
                throw new ArchiverException( "Unsupported encoding while reading manifest: " + e.getMessage(), e );
            }
            catch ( ManifestException e )
            {
                getLogger().error( "Manifest in file " + file + " is invalid: " + e.getMessage() );
                throw new ArchiverException( "Invalid Manifest", e );
            }
        }
    }
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.