Show / Hide Table of Contents

Class InflaterInputBuffer

An input buffer customised for use by InflaterInputStream

Inheritance
System.Object
InflaterInputBuffer
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: ICSharpCode.SharpZipLib.Zip.Compression.Streams
Assembly: ICSharpCode.SharpZipLib.dll
Syntax
public class InflaterInputBuffer
Remarks

The buffer supports decryption of incoming data.

Constructors

| Improve this Doc View Source

InflaterInputBuffer(Stream)

Initialise a new instance of InflaterInputBuffer with a default buffer size

Declaration
public InflaterInputBuffer(Stream stream)
Parameters
Type Name Description
System.IO.Stream stream

The stream to buffer.

| Improve this Doc View Source

InflaterInputBuffer(Stream, Int32)

Initialise a new instance of InflaterInputBuffer

Declaration
public InflaterInputBuffer(Stream stream, int bufferSize)
Parameters
Type Name Description
System.IO.Stream stream

The stream to buffer.

System.Int32 bufferSize

The size to use for the buffer

Remarks

A minimum buffer size of 1KB is permitted. Lower sizes are treated as 1KB.

Properties

| Improve this Doc View Source

Available

Get/set the number of bytes available

Declaration
public int Available { get; set; }
Property Value
Type Description
System.Int32
| Improve this Doc View Source

ClearText

Get the contents of the clear text buffer.

Declaration
public byte[] ClearText { get; }
Property Value
Type Description
System.Byte[]
| Improve this Doc View Source

ClearTextLength

Get the number of useable bytes in ClearText

Declaration
public int ClearTextLength { get; }
Property Value
Type Description
System.Int32
| Improve this Doc View Source

CryptoTransform

Get/set the System.Security.Cryptography.ICryptoTransform to apply to any data.

Declaration
public ICryptoTransform CryptoTransform { set; }
Property Value
Type Description
System.Security.Cryptography.ICryptoTransform
Remarks

Set this value to null to have no transform applied.

| Improve this Doc View Source

RawData

Get the contents of the raw data buffer.

Declaration
public byte[] RawData { get; }
Property Value
Type Description
System.Byte[]
Remarks

This may contain encrypted data.

| Improve this Doc View Source

RawLength

Get the length of bytes in the RawData

Declaration
public int RawLength { get; }
Property Value
Type Description
System.Int32

Methods

| Improve this Doc View Source

Fill()

Fill the buffer from the underlying input stream.

Declaration
public void Fill()
| Improve this Doc View Source

ReadClearTextBuffer(Byte[], Int32, Int32)

Read clear text data from the input stream.

Declaration
public int ReadClearTextBuffer(byte[] outBuffer, int offset, int length)
Parameters
Type Name Description
System.Byte[] outBuffer

The buffer to add data to.

System.Int32 offset

The offset to start adding data at.

System.Int32 length

The number of bytes to read.

Returns
Type Description
System.Int32

Returns the number of bytes actually read.

| Improve this Doc View Source

ReadLeByte()

Read a System.Byte from the input stream.

Declaration
public byte ReadLeByte()
Returns
Type Description
System.Byte

Returns the byte read.

| Improve this Doc View Source

ReadLeInt()

Read an System.Int32 in little endian byte order.

Declaration
public int ReadLeInt()
Returns
Type Description
System.Int32

The int value read.

| Improve this Doc View Source

ReadLeLong()

Read a System.Int64 in little endian byte order.

Declaration
public long ReadLeLong()
Returns
Type Description
System.Int64

The long value read.

| Improve this Doc View Source

ReadLeShort()

Read an System.Int16 in little endian byte order.

Declaration
public int ReadLeShort()
Returns
Type Description
System.Int32

The short value read case to an int.

| Improve this Doc View Source

ReadRawBuffer(Byte[])

Read a buffer directly from the input stream

Declaration
public int ReadRawBuffer(byte[] buffer)
Parameters
Type Name Description
System.Byte[] buffer

The buffer to fill

Returns
Type Description
System.Int32

Returns the number of bytes read.

| Improve this Doc View Source

ReadRawBuffer(Byte[], Int32, Int32)

Read a buffer directly from the input stream

Declaration
public int ReadRawBuffer(byte[] outBuffer, int offset, int length)
Parameters
Type Name Description
System.Byte[] outBuffer

The buffer to read into

System.Int32 offset

The offset to start reading data into.

System.Int32 length

The number of bytes to read.

Returns
Type Description
System.Int32

Returns the number of bytes read.

| Improve this Doc View Source

SetInflaterInput(Inflater)

Call SetInput(Byte[], Int32, Int32) passing the current clear text buffer contents.

Declaration
public void SetInflaterInput(Inflater inflater)
Parameters
Type Name Description
Inflater inflater

The inflater to set input for.

  • Improve this Doc
  • View Source
In This Article
Back to top Copyright © 2000-2022 SharpZipLib Contributors