Exemplo n.º 1
0
 /// <summary>
 /// End a deflation session.
 /// </summary>
 /// <remarks>
 /// Call this after making a series of one or more calls to Deflate(). All buffers are flushed.
 /// </remarks>
 /// <returns>Z_OK if all goes well.</returns>
 public int EndDeflate()
 {
     if (dstate == null)
         throw new ZlibException("No Deflate State!");
     //int ret = dstate.End();
     dstate = null;
     return ZlibConstants.Z_OK; //ret;
 }
Exemplo n.º 2
0
        private int _InternalInitializeDeflate(bool wantRfc1950Header)
        {
            if (istate != null) throw new ZlibException("You may not call InitializeDeflate() after calling InitializeInflate().");
            dstate = new DeflateManager();
            dstate.WantRfc1950HeaderBytes = wantRfc1950Header;

            return dstate.Initialize(this, this.CompressLevel, this.WindowBits, this.Strategy);
        }