TIDEADeCryptStream.Seek function
Set position on the stream.
Declaration
function Seek(const Offset: Int64; Origin: TSeekOrigin): Int64
; overrideArguments
Offset | Offset to apply to the position in the stream. |
Origin | Origin from where
|
Function result
New position in the stream.
Description
Seek will only work on a forward seek. It emulates a forward seek by
reading and discarding bytes from the input stream.
The
TIDEADecryptStream stream tries to provide seek capabilities for the
following limited number of cases:
- Origin=soFromBeginning
- If
Offsetis larger than the current position, then the remaining bytes are skipped by reading them from the stream and discarding them. - Origin=soFromCurrent
- If
Offsetis zero, the current position is returned. If it is positive, thenOffsetbytes are skipped by reading them from the stream and discarding them.
Errors
An EIDEAError exception is raised if the stream does not allow the requested seek operation.
See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
