System.Classes.TReader.ReadFloat
Delphi
function ReadFloat: Extended;
C++
System::Extended __fastcall ReadFloat();
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
function | public | System.Classes.pas System.Classes.hpp |
System.Classes | TReader |
Description
Reads and returns an Extended floating-point number from the reader object's stream.
ReadFloat is a helper method used by other reader methods to read an Extended floating-point value at the current reader Position.
ReadFloat calls ReadValue to check whether the value-type indicator is vaExtended
,and then ReadFloat calls Read and returns the retrieved Extended value. Otherwise, ReadFloat returns the stream position back before the value-type indicator, calls ReadDouble, and returns the retrieved value.
ReadFloat advances the reader Position after the last byte it has read.