Package org.jwat.gzip

Examples of org.jwat.gzip.GzipReader


        ByteCountingPushBackInputStream pbin =
                new ByteCountingPushBackInputStream(
                        new BufferedInputStream(in, buffer_size),
                PUSHBACK_BUFFER_SIZE);
        if (GzipReader.isGzipped(pbin)) {
            return new WarcReaderCompressed(new GzipReader(pbin),
                                            buffer_size);
        }
        return new WarcReaderUncompressed(pbin);
    }
View Full Code Here


                    "The inputstream 'in' is null");
        }
        ByteCountingPushBackInputStream pbin =
                new ByteCountingPushBackInputStream(in, PUSHBACK_BUFFER_SIZE);
        if (GzipReader.isGzipped(pbin)) {
            return new WarcReaderCompressed(new GzipReader(pbin));
        }
        return new WarcReaderUncompressed(pbin);
    }
View Full Code Here

                                                        throws IOException {
        if (in == null) {
            throw new IllegalArgumentException(
                    "The inputstream 'in' is null");
        }
        return new WarcReaderCompressed(new GzipReader(in));
    }
View Full Code Here

        if (buffer_size <= 0) {
            throw new IllegalArgumentException(
                    "The 'buffer_size' is less than or equal to zero: " +
                    buffer_size);
        }
        return new WarcReaderCompressed(new GzipReader(
                new BufferedInputStream(in, buffer_size)));
    }
View Full Code Here

        if (offset < -1) {
            throw new IllegalArgumentException(
                    "The 'offset' is less than -1: " + offset);
        }
        currentRecord = null;
        currentReader = new GzipReader(rin);
        currentEntry = currentReader.getNextEntry();
        if (currentEntry != null) {
            ByteCountingPushBackInputStream pbin =
                    new ByteCountingPushBackInputStream(
                            currentEntry.getInputStream(), PUSHBACK_BUFFER_SIZE);
View Full Code Here

            throw new IllegalArgumentException(
                    "The 'buffer_size' is less than or equal to zero: "
                    + buffer_size);
        }
        currentRecord = null;
        currentReader = new GzipReader(rin);
        currentEntry = currentReader.getNextEntry();
        if (currentEntry != null) {
            ByteCountingPushBackInputStream pbin =
                    new ByteCountingPushBackInputStream(
                            new BufferedInputStream(
View Full Code Here

    r.pbin = new ByteCountingPushBackInputStream(rin, 32);
    ByteCountingPushBackInputStream in = null;

    if (GzipReader.isGzipped(r.pbin)) {
      r.gzipReader = new GzipReader(r.pbin);
      if ( (r.gzipEntry = r.gzipReader.getNextEntry()) != null ) {
        in = new ByteCountingPushBackInputStream(new BufferedInputStream( r.gzipEntry.getInputStream(), 8192), 32);
      } else {
        throw new ResourceNotAvailableException("GZip entry is invalid");
      }
View Full Code Here

TOP

Related Classes of org.jwat.gzip.GzipReader

Copyright © 2018 www.massapicom. 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.