System.Classes.TReader.ReadListBegin

From Appmethod Libraries
Jump to: navigation, search

Object Pascal

procedure ReadListBegin; inline;

C++

void __fastcall ReadListBegin(void);

Properties

Type Visibility Source Unit Parent
procedure
function
public
System.Classes.pas
System.Classes.hpp
System.Classes TReader

Description

Reads a start-of-list marker from the reader object's associated stream.

ReadListBegin is used by other methods that iterate through a list of items to ensure that the type about to be read is a list. ReadListBegin is also used by component writers in defined property ReadData methods.

If the next item in the stream is not a start-of list marker as written by the WriteListBegin method, ReadListBegin raises an EReadError exception.

A call to ReadListBegin is generally followed by a reading loop that terminates when the EndOfList method returns true, indicating that an end-of-list marker is next on the stream, at which point a call to ReadListEnd is required.

See Also