[Overview][Constants][Classes][Index] |
Moves the position in the buffer relative to the specified origin
Source position: bufstream.pp line 130
public function TBufferedFileStream.Seek( |
Offset: LongInt; |
Origin: Word |
):LongInt; override; overload; |
const Offset: Int64; |
Origin: TSeekOrigin |
):Int64; override; overload; |
Offset |
|
Number of bytes to move the stream position relative to its origin |
Origin |
|
Stream position used as the origin for the relative movement |
Number of bytes the stream position was moved, or -1 when not moved
Offset |
|
Number of bytes to move the stream position relative to its origin |
Origin |
|
Stream position used as the origin for the relative movement |
Seek is a method used to change the current position in the buffered file stream by the number of bytes in Offset relative to the given Origin. Overloaded variants are provided which use LongInt or Int64 types for the Offset parameter, and Word or TSeekOrigin types for the Origin parameter.
Seek is overridden to use the size and position in the internal buffer when positioning the buffered file stream.
The return value contains the actual number of bytes the position was moved relative to the Origin. As with TStream, the return value may contain -1 if the stream position was not moved.