C# Класс Be.Windows.Forms.DynamicFileByteProvider

Implements a fully editable byte provider for file data of any size.
Only changes to the file are stored in memory with reads from the original data occurring as required.
Наследование: IByteProvider, IDisposable
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
ApplyChanges ( ) : void

See IByteProvider.ApplyChanges for more information.

DeleteBytes ( long index, long length ) : void

See IByteProvider.DeleteBytes for more information.

Dispose ( ) : void

See IDisposable.Dispose for more information.

DynamicFileByteProvider ( Stream stream ) : System

Constructs a new DynamicFileByteProvider instance.

The stream must supported seek operations.

DynamicFileByteProvider ( string fileName ) : System

Constructs a new DynamicFileByteProvider instance.

DynamicFileByteProvider ( string fileName, bool readOnly ) : System

Constructs a new DynamicFileByteProvider instance.

HasChanges ( ) : bool

See IByteProvider.HasChanges for more information.

InsertBytes ( long index, byte bs ) : void

See IByteProvider.InsertBytes for more information.

ReadByte ( long index ) : byte

See IByteProvider.ReadByte for more information.

SupportsDeleteBytes ( ) : bool

See IByteProvider.SupportsDeleteBytes for more information.

SupportsInsertBytes ( ) : bool

See IByteProvider.SupportsInsertBytes for more information.

SupportsWriteByte ( ) : bool

See IByteProvider.SupportsWriteByte for more information.

WriteByte ( long index, byte value ) : void

See IByteProvider.WriteByte for more information.

Приватные методы

Метод Описание
GetDataBlock ( long findOffset, long &blockOffset ) : Be.Windows.Forms.DataBlock
GetNextFileDataBlock ( Be.Windows.Forms.DataBlock block, long dataOffset, long &nextDataOffset ) : Be.Windows.Forms.FileDataBlock
MoveFileBlock ( Be.Windows.Forms.FileDataBlock fileBlock, long dataOffset ) : void
OnChanged ( EventArgs e ) : void
OnLengthChanged ( EventArgs e ) : void
ReInitialize ( ) : void
ReadByteFromFile ( long fileOffset ) : byte

Описание методов

ApplyChanges() публичный Метод

See IByteProvider.ApplyChanges for more information.
public ApplyChanges ( ) : void
Результат void

DeleteBytes() публичный Метод

See IByteProvider.DeleteBytes for more information.
public DeleteBytes ( long index, long length ) : void
index long
length long
Результат void

Dispose() публичный Метод

See IDisposable.Dispose for more information.
public Dispose ( ) : void
Результат void

DynamicFileByteProvider() публичный Метод

Constructs a new DynamicFileByteProvider instance.
The stream must supported seek operations.
public DynamicFileByteProvider ( Stream stream ) : System
stream Stream the stream containing the data.
Результат System

DynamicFileByteProvider() публичный Метод

Constructs a new DynamicFileByteProvider instance.
public DynamicFileByteProvider ( string fileName ) : System
fileName string The name of the file from which bytes should be provided.
Результат System

DynamicFileByteProvider() публичный Метод

Constructs a new DynamicFileByteProvider instance.
public DynamicFileByteProvider ( string fileName, bool readOnly ) : System
fileName string The name of the file from which bytes should be provided.
readOnly bool True, opens the file in read-only mode.
Результат System

HasChanges() публичный Метод

See IByteProvider.HasChanges for more information.
public HasChanges ( ) : bool
Результат bool

InsertBytes() публичный Метод

See IByteProvider.InsertBytes for more information.
public InsertBytes ( long index, byte bs ) : void
index long
bs byte
Результат void

ReadByte() публичный Метод

See IByteProvider.ReadByte for more information.
public ReadByte ( long index ) : byte
index long
Результат byte

SupportsDeleteBytes() публичный Метод

See IByteProvider.SupportsDeleteBytes for more information.
public SupportsDeleteBytes ( ) : bool
Результат bool

SupportsInsertBytes() публичный Метод

See IByteProvider.SupportsInsertBytes for more information.
public SupportsInsertBytes ( ) : bool
Результат bool

SupportsWriteByte() публичный Метод

See IByteProvider.SupportsWriteByte for more information.
public SupportsWriteByte ( ) : bool
Результат bool

WriteByte() публичный Метод

See IByteProvider.WriteByte for more information.
public WriteByte ( long index, byte value ) : void
index long
value byte
Результат void