Свойство | Тип | Описание | |
---|---|---|---|
LastModified | DateTime? |
Метод | Описание | |
---|---|---|
CompressBuffer ( byte b ) : byte[] |
Compress a byte array into a new byte array using GZip. Uncompress it with GZipStream.UncompressBuffer(byte[]). |
|
CompressString ( String s ) : byte[] |
Compress a string into a byte array using GZip. Uncompress it with GZipStream.UncompressString(byte[]). |
|
Flush ( ) : void |
Flush the stream.
|
|
GZipStream ( Stream stream, CompressionMode mode ) : System |
Create a When mode is As noted in the class documentation, the |
|
GZipStream ( Stream stream, CompressionMode mode, CompressionLevel level ) : System |
Create a The |
|
GZipStream ( Stream stream, CompressionMode mode, CompressionLevel level, bool leaveOpen ) : System |
Create a This constructor allows the application to request that the captive stream remain open after the deflation or inflation occurs. By default, after As noted in the class documentation, the |
|
GZipStream ( Stream stream, CompressionMode mode, bool leaveOpen ) : System |
Create a This constructor allows the application to request that the captive stream remain open after the deflation or inflation occurs. By default, after The CompressionMode (Compress or Decompress) also establishes the "direction" of the stream. A The See the other overloads of this constructor for example code. |
|
Read ( byte buffer, int offset, int count ) : int |
Read and decompress data from the source stream. With a |
|
Seek ( long offset, SeekOrigin origin ) : long |
Calling this method always throws a NotImplementedException.
|
|
SetLength ( long value ) : void |
Calling this method always throws a NotImplementedException.
|
|
UncompressBuffer ( byte compressed ) : byte[] |
Uncompress a GZip'ed byte array into a byte array.
|
|
UncompressString ( byte compressed ) : String |
Uncompress a GZip'ed byte array into a single string.
|
|
Write ( byte buffer, int offset, int count ) : void |
Write data to the stream. If you wish to use the A |
Метод | Описание | |
---|---|---|
Dispose ( bool disposing ) : void |
Dispose the stream. This may or may not result in a This method may be invoked in two distinct scenarios. If disposing == true, the method has been called directly or indirectly by a user's code, for example via the public Dispose() method. In this case, both managed and unmanaged resources can be referenced and disposed. If disposing == false, the method has been called by the runtime from inside the object finalizer and this method should not reference other objects; in that case only unmanaged resources must be referenced or disposed. |
Метод | Описание | |
---|---|---|
EmitHeader ( ) : int |
public static CompressBuffer ( byte b ) : byte[] | ||
b | byte | /// A buffer to compress. /// |
Результат | byte[] |
public static CompressString ( String s ) : byte[] | ||
s | String | /// A string to compress. The string will first be encoded /// using UTF8, then compressed. /// |
Результат | byte[] |
protected Dispose ( bool disposing ) : void | ||
disposing | bool | /// indicates whether the Dispose method was invoked by user code. /// |
Результат | void |
public GZipStream ( Stream stream, CompressionMode mode ) : System | ||
stream | Stream | The stream which will be read or written. |
mode | CompressionMode | Indicates whether the GZipStream will compress or decompress. |
Результат | System |
public GZipStream ( Stream stream, CompressionMode mode, CompressionLevel level ) : System | ||
stream | Stream | The stream to be read or written while deflating or inflating. |
mode | CompressionMode | Indicates whether the |
level | CompressionLevel | A tuning knob to trade speed for effectiveness. |
Результат | System |
public GZipStream ( Stream stream, CompressionMode mode, CompressionLevel level, bool leaveOpen ) : System | ||
stream | Stream | The stream which will be read or written. |
mode | CompressionMode | Indicates whether the GZipStream will compress or decompress. |
level | CompressionLevel | A tuning knob to trade speed for effectiveness. |
leaveOpen | bool | true if the application would like the stream to remain open after inflation/deflation. |
Результат | System |
public GZipStream ( Stream stream, CompressionMode mode, bool leaveOpen ) : System | ||
stream | Stream | /// The stream which will be read or written. This is called the "captive" /// stream in other places in this documentation. /// |
mode | CompressionMode | Indicates whether the GZipStream will compress or decompress. /// |
leaveOpen | bool | /// true if the application would like the base stream to remain open after /// inflation/deflation. /// |
Результат | System |
public Read ( byte buffer, int offset, int count ) : int | ||
buffer | byte | The buffer into which the decompressed data should be placed. |
offset | int | the offset within that data array to put the first byte read. |
count | int | the number of bytes to read. |
Результат | int |
public Seek ( long offset, SeekOrigin origin ) : long | ||
offset | long | irrelevant; it will always throw! |
origin | SeekOrigin | irrelevant; it will always throw! |
Результат | long |
public SetLength ( long value ) : void | ||
value | long | irrelevant; this method will always throw! |
Результат | void |
public static UncompressBuffer ( byte compressed ) : byte[] | ||
compressed | byte | /// A buffer containing data that has been compressed with GZip. /// |
Результат | byte[] |
public static UncompressString ( byte compressed ) : String | ||
compressed | byte | /// A buffer containing GZIP-compressed data. /// |
Результат | String |
public Write ( byte buffer, int offset, int count ) : void | ||
buffer | byte | The buffer holding data to write to the stream. |
offset | int | the offset within that data array to find the first byte to write. |
count | int | the number of bytes to write. |
Результат | void |