~ubuntu-branches/ubuntu/oneiric/monodevelop/oneiric

« back to all changes in this revision

Viewing changes to contrib/NSch/NSch.ZLib/JZlib.cs

  • Committer: Bazaar Package Importer
  • Author(s): Jo Shields
  • Date: 2011-06-27 17:03:13 UTC
  • mto: (1.8.1 upstream)
  • mto: This revision was merged to the branch mainline in revision 54.
  • Revision ID: james.westby@ubuntu.com-20110627170313-6cvz3s19x6e9hqe9
ImportĀ upstreamĀ versionĀ 2.5.92+dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
Copyright (c) 2000,2001,2002,2003 ymnk, JCraft,Inc. All rights reserved.
 
3
 
 
4
Redistribution and use in source and binary forms, with or without
 
5
modification, are permitted provided that the following conditions are met:
 
6
 
 
7
  1. Redistributions of source code must retain the above copyright notice,
 
8
     this list of conditions and the following disclaimer.
 
9
 
 
10
  2. Redistributions in binary form must reproduce the above copyright 
 
11
     notice, this list of conditions and the following disclaimer in 
 
12
     the documentation and/or other materials provided with the distribution.
 
13
 
 
14
  3. The names of the authors may not be used to endorse or promote products
 
15
     derived from this software without specific prior written permission.
 
16
 
 
17
THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
 
18
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
 
19
FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,
 
20
INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,
 
21
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
 
22
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
 
23
OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
 
24
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
 
25
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
 
26
EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
27
 
 
28
This program is based on zlib-1.1.3, so all credit should go authors
 
29
Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)
 
30
and contributors of zlib.
 
31
*/
 
32
 
 
33
using NSch.ZLib;
 
34
using Sharpen;
 
35
 
 
36
namespace NSch.ZLib
 
37
{
 
38
        public sealed class JZlib
 
39
        {
 
40
                private static readonly string version = "1.0.2";
 
41
 
 
42
                public static string Version()
 
43
                {
 
44
                        return version;
 
45
                }
 
46
 
 
47
                public const int Z_NO_COMPRESSION = 0;
 
48
 
 
49
                public const int Z_BEST_SPEED = 1;
 
50
 
 
51
                public const int Z_BEST_COMPRESSION = 9;
 
52
 
 
53
                public const int Z_DEFAULT_COMPRESSION = (-1);
 
54
 
 
55
                public const int Z_FILTERED = 1;
 
56
 
 
57
                public const int Z_HUFFMAN_ONLY = 2;
 
58
 
 
59
                public const int Z_DEFAULT_STRATEGY = 0;
 
60
 
 
61
                public const int Z_NO_FLUSH = 0;
 
62
 
 
63
                public const int Z_PARTIAL_FLUSH = 1;
 
64
 
 
65
                public const int Z_SYNC_FLUSH = 2;
 
66
 
 
67
                public const int Z_FULL_FLUSH = 3;
 
68
 
 
69
                public const int Z_FINISH = 4;
 
70
 
 
71
                public const int Z_OK = 0;
 
72
 
 
73
                public const int Z_STREAM_END = 1;
 
74
 
 
75
                public const int Z_NEED_DICT = 2;
 
76
 
 
77
                public const int Z_ERRNO = -1;
 
78
 
 
79
                public const int Z_STREAM_ERROR = -2;
 
80
 
 
81
                public const int Z_DATA_ERROR = -3;
 
82
 
 
83
                public const int Z_MEM_ERROR = -4;
 
84
 
 
85
                public const int Z_BUF_ERROR = -5;
 
86
 
 
87
                public const int Z_VERSION_ERROR = -6;
 
88
                // compression levels
 
89
                // compression strategy
 
90
        }
 
91
}