Rebex.IO.Compression.Inflate.inflateInit C# (CSharp) Метод

inflateInit() приватный Метод

private inflateInit ( ZStream z, int w ) : int
z ZStream
w int
Результат int
        internal int inflateInit(ZStream z, int w)
        {
            z.msg = null;
            blocks = null;

            // handle undocumented nowrap option (no zlib header or check)
            nowrap = 0;
            if (w < 0)
            {
                w = - w;
                nowrap = 1;
            }

            // set window size
            if (w < 8 || w > 15)
            {
                inflateEnd(z);
                return Z_STREAM_ERROR;
            }
            wbits = w;

            z.istate.blocks = new InfBlocks(z, z.istate.nowrap != 0?null:this, 1 << w);

            // reset state
            inflateReset(z);
            return Z_OK;
        }

Usage Example

Пример #1
0
 public int inflateInit(int w, bool nowrap)
 {
     istate = new Inflate();
     return(istate.inflateInit(this, nowrap?-w:w));
 }
All Usage Examples Of Rebex.IO.Compression.Inflate::inflateInit