The SDL Component Suite is an industry leading collection of components supporting scientific and engineering computing. Please visit the SDL Web site for more information....



ReadStreamUntilTagList


Unit:SDL_streams
Class: none
Declaration: function ReadStreamUntilTagList (InStream: TStream; const TagList: array of string; var TagNr: integer): string; { Pascal }
AnsiString __fastcall ReadStreamUntilTagList(Classes::TStream* InStream, const AnsiString * TagList, const int TagList_Size, int &TagNr); { C++ }

The function ReadStreamUntilTagList reads the stream InStream from the current stream position until one of the substrings specified in the array TagList is found. The function returns all characters between the current position and the matched substring, including the substring. The parameter TagList has to be a zero-based array which contains the substrings to be searched for. The search is not case sensitive. On return the variable parameter TagNr contains the index of the found substring, or a value of -1 if no substring in the TagList matches the input stream InStream.

Hint: The declaration of ReadStreamUntilTagList in C++ slightly differs from the Pascal declaration (note the extra parameter TagList_Size which specifies the highest index of the TagList array):
AnsiString __fastcall ReadStreamUntilTagList(Classes::TStream* InStream, const AnsiString * TagList, const int TagList_Size, int &TagNr);



Last Update: 2012-Oct-20