TROBlockFileStream

Overview

TROBlockFileStream is designed for reading a file on disk or writing a file to disk by large chunks. This gives better performance for disk operations.

Usage: the same as TFileStream.

TROBlockFileStream is used in TDADataTable|SaveToFile methods.

Location


Properties


BlockSize

Specified size that will be use for caching.

property BlockSize: Cardinal read write

Instance Methods


constructor Create

Creates a new instance with a supplied values.

constructor Create(const FileName: string; Mode: Word)

Parameters:

  • FileName: name of file.
  • Mode: see description of TFileStream for details.

Flush

Writes the buffer to the file.

procedure Flush

Read  override

Reads up to Count bytes of data from the file into Buffer.

function Read(var Buffer: ; Count: LongInt): LongInt

Parameters:

  • Buffer: buffer
  • Count: count