test_class.declarator: CONTENT = new DefaultDeflateCompatibilityWindow().getCorpus()
test_class.modifier: private final static
test_class.original_string: private final static byte[] CONTENT = new DefaultDeflateCompatibilityWindow().getCorpus();
test_class.type: byte[]
test_class.var_name: CONTENT
test_class.declarator: compressor
test_class.modifier: private
test_class.original_string: private DeflateCompressor compressor;
test_class.type: DeflateCompressor
test_class.var_name: compressor
test_class.declarator: rawContentIn
test_class.modifier: private
test_class.original_string: private ByteArrayInputStream rawContentIn;
test_class.type: ByteArrayInputStream
test_class.var_name: rawContentIn
test_class.declarator: compressedContentOut
test_class.modifier: private
test_class.original_string: private ByteArrayOutputStream compressedContentOut;
test_class.type: ByteArrayOutputStream
test_class.var_name: compressedContentOut
test_class.file: feya/libraries/archive_diff/diff.shared/src/test/java/com/google/archivepatcher/shared/DeflateCompressorTest.java
test_class.identifier: DeflateCompressorTest
test_case.body: @Test
    public void testCompress() throws IOException {
      compressor.compress(rawContentIn, compressedContentOut);
      Assert.assertTrue(compressedContentOut.size() > 0);
      Assert.assertTrue(compressedContentOut.size() < CONTENT.length);
      byte[] uncompressed =
          uncompressWithJavaInflater(compressor.isNowrap(), compressedContentOut.toByteArray());
      Assert.assertArrayEquals(CONTENT, uncompressed);
    }
test_case.class_method_signature: DeflateCompressorTest.testCompress()
test_case.full_signature: @Test public void testCompress()
test_case.identifier: testCompress
test_case.invocations: compress assertTrue size assertTrue size uncompressWithJavaInflater isNowrap toByteArray assertArrayEquals
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testCompress()
focal_class.declarator: compressionLevel = Deflater.DEFAULT_COMPRESSION
focal_class.modifier: private
focal_class.original_string: private int compressionLevel = Deflater.DEFAULT_COMPRESSION;
focal_class.type: int
focal_class.var_name: compressionLevel
focal_class.declarator: strategy = Deflater.DEFAULT_STRATEGY
focal_class.modifier: private
focal_class.original_string: private int strategy = Deflater.DEFAULT_STRATEGY;
focal_class.type: int
focal_class.var_name: strategy
focal_class.declarator: nowrap = true
focal_class.modifier: private
focal_class.original_string: private boolean nowrap = true;
focal_class.type: boolean
focal_class.var_name: nowrap
focal_class.declarator: inputBufferSize = 32768
focal_class.modifier: private
focal_class.original_string: private int inputBufferSize = 32768;
focal_class.type: int
focal_class.var_name: inputBufferSize
focal_class.declarator: outputBufferSize = 32768
focal_class.modifier: private
focal_class.original_string: private int outputBufferSize = 32768;
focal_class.type: int
focal_class.var_name: outputBufferSize
focal_class.declarator: deflater = null
focal_class.modifier: private
focal_class.original_string: private Deflater deflater = null;
focal_class.type: Deflater
focal_class.var_name: deflater
focal_class.declarator: caching = false
focal_class.modifier: private
focal_class.original_string: private boolean caching = false;
focal_class.type: boolean
focal_class.var_name: caching
focal_class.file: feya/libraries/archive_diff/diff.shared/src/main/java/com/google/archivepatcher/shared/DeflateCompressor.java
focal_class.identifier: DeflateCompressor
focal_class.interfaces: implements Compressor
focal_class.class_method_signature: DeflateCompressor.isNowrap()
focal_class.full_signature: public boolean isNowrap()
focal_class.identifier: isNowrap
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: boolean
focal_class.signature: boolean isNowrap()
focal_class.class_method_signature: DeflateCompressor.setNowrap(boolean nowrap)
focal_class.full_signature: public void setNowrap(boolean nowrap)
focal_class.identifier: setNowrap
focal_class.modifiers: public
focal_class.parameters: (boolean nowrap)
focal_class.return: void
focal_class.signature: void setNowrap(boolean nowrap)
focal_class.class_method_signature: DeflateCompressor.getCompressionLevel()
focal_class.full_signature: public int getCompressionLevel()
focal_class.identifier: getCompressionLevel
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int getCompressionLevel()
focal_class.class_method_signature: DeflateCompressor.setCompressionLevel(int compressionLevel)
focal_class.full_signature: public void setCompressionLevel(int compressionLevel)
focal_class.identifier: setCompressionLevel
focal_class.modifiers: public
focal_class.parameters: (int compressionLevel)
focal_class.return: void
focal_class.signature: void setCompressionLevel(int compressionLevel)
focal_class.class_method_signature: DeflateCompressor.getStrategy()
focal_class.full_signature: public int getStrategy()
focal_class.identifier: getStrategy
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int getStrategy()
focal_class.class_method_signature: DeflateCompressor.setStrategy(int strategy)
focal_class.full_signature: public void setStrategy(int strategy)
focal_class.identifier: setStrategy
focal_class.modifiers: public
focal_class.parameters: (int strategy)
focal_class.return: void
focal_class.signature: void setStrategy(int strategy)
focal_class.class_method_signature: DeflateCompressor.getInputBufferSize()
focal_class.full_signature: public int getInputBufferSize()
focal_class.identifier: getInputBufferSize
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int getInputBufferSize()
focal_class.class_method_signature: DeflateCompressor.setInputBufferSize(int inputBufferSize)
focal_class.full_signature: public void setInputBufferSize(int inputBufferSize)
focal_class.identifier: setInputBufferSize
focal_class.modifiers: public
focal_class.parameters: (int inputBufferSize)
focal_class.return: void
focal_class.signature: void setInputBufferSize(int inputBufferSize)
focal_class.class_method_signature: DeflateCompressor.getOutputBufferSize()
focal_class.full_signature: public int getOutputBufferSize()
focal_class.identifier: getOutputBufferSize
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int getOutputBufferSize()
focal_class.class_method_signature: DeflateCompressor.setOutputBufferSize(int outputBufferSize)
focal_class.full_signature: public void setOutputBufferSize(int outputBufferSize)
focal_class.identifier: setOutputBufferSize
focal_class.modifiers: public
focal_class.parameters: (int outputBufferSize)
focal_class.return: void
focal_class.signature: void setOutputBufferSize(int outputBufferSize)
focal_class.class_method_signature: DeflateCompressor.isCaching()
focal_class.full_signature: public boolean isCaching()
focal_class.identifier: isCaching
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: boolean
focal_class.signature: boolean isCaching()
focal_class.class_method_signature: DeflateCompressor.setCaching(boolean caching)
focal_class.full_signature: public void setCaching(boolean caching)
focal_class.identifier: setCaching
focal_class.modifiers: public
focal_class.parameters: (boolean caching)
focal_class.return: void
focal_class.signature: void setCaching(boolean caching)
focal_class.class_method_signature: DeflateCompressor.createOrResetDeflater()
focal_class.full_signature: protected Deflater createOrResetDeflater()
focal_class.identifier: createOrResetDeflater
focal_class.modifiers: protected
focal_class.parameters: ()
focal_class.return: Deflater
focal_class.signature: Deflater createOrResetDeflater()
focal_class.class_method_signature: DeflateCompressor.release()
focal_class.full_signature: public void release()
focal_class.identifier: release
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void release()
focal_class.class_method_signature: DeflateCompressor.compress(InputStream uncompressedIn, OutputStream compressedOut)
focal_class.full_signature: @Override public void compress(InputStream uncompressedIn, OutputStream compressedOut)
focal_class.identifier: compress
focal_class.modifiers: @Override public
focal_class.parameters: (InputStream uncompressedIn, OutputStream compressedOut)
focal_class.return: void
focal_class.signature: void compress(InputStream uncompressedIn, OutputStream compressedOut)
focal_method.body: @Override
    public void compress(InputStream uncompressedIn, OutputStream compressedOut) throws IOException {
      byte[] buffer = new byte[inputBufferSize];
      DeflaterOutputStream deflaterOut =
          new DeflaterOutputStream(compressedOut, createOrResetDeflater(), outputBufferSize);
      int numRead = 0;
      while ((numRead = uncompressedIn.read(buffer)) >= 0) {
        deflaterOut.write(buffer, 0, numRead);
      }
      deflaterOut.finish();
      deflaterOut.flush();
    }
focal_method.class_method_signature: DeflateCompressor.compress(InputStream uncompressedIn, OutputStream compressedOut)
focal_method.full_signature: @Override public void compress(InputStream uncompressedIn, OutputStream compressedOut)
focal_method.identifier: compress
focal_method.invocations: createOrResetDeflater read write finish flush
focal_method.modifiers: @Override public
focal_method.parameters: (InputStream uncompressedIn, OutputStream compressedOut)
focal_method.return: void
focal_method.signature: void compress(InputStream uncompressedIn, OutputStream compressedOut)