Skip to main content

GZipCompressor

Assembly: ServiceStack.Client.dll​
View Source​
Declaration
public class GZipCompressor : IStreamCompressor

Properties​

Encoding​

View Source​
Declaration
public string Encoding { get; }

Instance​

View Source​
Declaration
public static GZipCompressor Instance { get; }

Methods​

Compress(String, Encoding)​

View Source​
Declaration
public byte[] Compress(string text, Encoding encoding = null)
Returns​

System.Byte[]

Parameters​
TypeName
System.Stringtext
System.Text.Encodingencoding

Compress(Byte[])​

View Source​
Declaration
public byte[] Compress(byte[] buffer)
Returns​

System.Byte[]

Parameters​
TypeName
System.Byte[]buffer

Compress(Stream, Boolean)​

View Source​
Declaration
public Stream Compress(Stream outputStream, bool leaveOpen = false)
Returns​

System.IO.Stream

Parameters​
TypeName
System.IO.StreamoutputStream
System.BooleanleaveOpen

Decompress(Byte[], Encoding)​

View Source​
Declaration
public string Decompress(byte[] gzBuffer, Encoding encoding = null)
Returns​

System.String

Parameters​
TypeName
System.Byte[]gzBuffer
System.Text.Encodingencoding

DecompressBytes(Byte[])​

View Source​
Declaration
public byte[] DecompressBytes(byte[] gzBuffer)
Returns​

System.Byte[]

Parameters​
TypeName
System.Byte[]gzBuffer

Decompress(Stream, Boolean)​

View Source​
Declaration
public Stream Decompress(Stream gzStream, bool leaveOpen = false)
Returns​

System.IO.Stream

Parameters​
TypeName
System.IO.StreamgzStream
System.BooleanleaveOpen

Implements​