Sign in Join
FPDoc Onlineexperiment

THandleStream class

In unit Classes

Base class for streams that are identified by an OS handle.

Declaration

pascal
THandleStream = class(TStream)

Inheritance

  1. THandleStream
  2. TStream
  3. TObject

Descends from it: TFileStream TInputPipeStream TIOStream TNullStream TOutputPipeStream TReleaseHandleStream

Description

THandleStream is an abstract descendant of the TStream class that provides methods for a stream to handle all reading and writing to and from a handle, provided by the underlying OS. To this end, it overrides the Read and Write methods of TStream.

  • ThandleStream does not obtain a handle from the OS by itself, it just handles reading and writing to such a handle by wrapping the system calls for reading and writing; Descendant classes should obtain a handle from the OS by themselves and pass it on in the inherited constructor.
  • Contrary to Delphi, no seek is implemented for THandleStream, since pipes and sockets do not support this. The seek is implemented in descendant methods that support it.

See also

Properties

HandlepublicThe OS handle of the stream.

Methods

SetSizeprotected
CreatepublicCreate a handlestream from an OS Handle.
ReadpublicOverrides standard read method.
WritepublicOverrides standard write method.
SeekpublicOverrides the Seek method.

Inherited

From TObject (41)

AfterConstruction BeforeDestruction CheckDisposed ClassInfo ClassName ClassNameIs ClassParent ClassType CleanupInstance DefaultHandler DefaultHandlerStr Destroy Dispatch DispatchStr Disposed DisposeOf Equals FieldAddress Free FreeInstance GetDisposed GetHashCode GetInterface GetInterfaceByStr GetInterfaceEntry GetInterfaceEntryByStr GetInterfaceTable GetInterfaceWeak GetLastCastErrorInfo InheritsFrom InitInstance InstanceSize MethodAddress MethodName newinstance QualifiedClassName SafeCallException StringMessageTable SystemHasExtendedRTTI ToString UnitName

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.