Topic Path: Symbol Reference > Functions > FetchBytes Function
ContentsIndexHome
PreviousUpNext
FetchBytes Function

Locates and returns the initial byte values up to the indicated delimiter.

File
function FetchBytes(
    var AInput: TIdBytes; 
    const ADelim: TIdBytes; 
    const ADelete: Boolean = IdFetchDeleteDefault
): TIdBytes;
Parameters 
Description 
AInput 
Values to be searched.
 
ADelim 
Delimiter for the fetched values.
 
ADelete 
Indicates if the fetch values are removed from the original input. 

TIdBytes - Values found in the input up to the delimiter.

FetchBytes is a TIdBytes function used to locate and return the inital values in AInput up to (but not including) the delimiter indicated in ADelim. When ADelim does not appear in AInput, the entire contents of AInput is used in the return value. 

When ADelete contains True, the values in AInput are updated to remove the inital byte values and the delimiter character. If ADelim does not appear in AInput, the entire contents of AInput is deleted. 

FetchBytes is the TIdBytes-specific equivalent of the Fetch function.

Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Post feedback to the Indy Docs Newsgroup.