Inheritance: IFileFormatReader
Ejemplo n.º 1
0
 public Inflater(bool doGZip) {
     this.using_gzip = doGZip;
     this.output = new OutputWindow();
     this.input = new InputBuffer();
     this.gZipDecoder = new GZipDecoder(this.input);
     this.codeList = new byte[320];
     this.codeLengthTreeCodeLength = new byte[0x13];
     this.Reset();
 }
Ejemplo n.º 2
0
 public Inflater(bool doGZip)
 {
     this.using_gzip  = doGZip;
     this.output      = new OutputWindow();
     this.input       = new InputBuffer();
     this.gZipDecoder = new GZipDecoder(this.input);
     this.codeList    = new byte[320];
     this.codeLengthTreeCodeLength = new byte[0x13];
     this.Reset();
 }
Ejemplo n.º 3
0
        GZipDecoder gZipDecoder;        // class to decode gzip header and footer

        public Inflater(bool doGZip)
        {
            using_gzip  = doGZip;
            output      = new OutputWindow();
            input       = new InputBuffer();
            gZipDecoder = new GZipDecoder(input);

            codeList = new byte[HuffmanTree.MaxLiteralTreeElements + HuffmanTree.MaxDistTreeElements];
            codeLengthTreeCodeLength = new byte[HuffmanTree.NumberOfCodeLengthTreeElements];
            Reset();
        }
Ejemplo n.º 4
0
        private void SetDeflateStreamFileFormatter(CompressionMode mode) {

            if (mode == CompressionMode.Compress) {

                IFileFormatWriter writeCommand = new GZipFormatter();
                deflateStream.SetFileFormatWriter(writeCommand);

            } else {

                IFileFormatReader readCommand = new GZipDecoder();
                deflateStream.SetFileFormatReader(readCommand);
            }
        }
Ejemplo n.º 5
0
 private void SetDeflateStreamFileFormatter(CompressionMode mode)
 {
     if (mode == CompressionMode.Compress)
     {
         IFileFormatWriter writeCommand = new GZipFormatter();
         _deflateStream.SetFileFormatWriter(writeCommand);
     }
     else
     {
         IFileFormatReader readCommand = new GZipDecoder();
         _deflateStream.SetFileFormatReader(readCommand);
     }
 }
Ejemplo n.º 6
0
 public GZipStream(Stream stream, CompressionMode mode, bool leaveOpen)
 {
     this.deflateStream = new DeflateStream(stream, mode, leaveOpen);
     if (mode == CompressionMode.Compress)
     {
         IFileFormatWriter writer = new GZipFormatter();
         this.deflateStream.SetFileFormatWriter(writer);
     }
     else
     {
         IFileFormatReader reader = new GZipDecoder();
         this.deflateStream.SetFileFormatReader(reader);
     }
 }
 public GZipStream(Stream stream, CompressionMode mode, bool leaveOpen)
 {
     this.deflateStream = new DeflateStream(stream, mode, leaveOpen);
     if (mode == CompressionMode.Compress)
     {
         IFileFormatWriter writer = new GZipFormatter();
         this.deflateStream.SetFileFormatWriter(writer);
     }
     else
     {
         IFileFormatReader reader = new GZipDecoder();
         this.deflateStream.SetFileFormatReader(reader);
     }
 }
Ejemplo n.º 8
0
        GZipDecoder gZipDecoder;        // class to decode gzip header and footer

        public Inflater(bool doGZip) {
            using_gzip = doGZip;            
            output = new OutputWindow();
            input  = new InputBuffer();
            gZipDecoder = new GZipDecoder(input);

            codeList = new byte[HuffmanTree.MaxLiteralTreeElements + HuffmanTree.MaxDistTreeElements];
            codeLengthTreeCodeLength = new byte[HuffmanTree.NumberOfCodeLengthTreeElements];
            Reset();
        }