Internet Direct (Indy)
Home
PreviousUpNext
FillBytes Function

Initializes a specified number of bytes in an array of bytes to a specific value.

Pascal
procedure FillBytes(
    var VBytes: TIdBytes; 
    const ACount: Integer; 
    const AValue: Byte
);
Parameters 
Description 
VBytes 
Byte values to be initialized.
 
ACount 
Number of bytes in the array to be given the specified value.
 
AValue 
Value to store in bytes in the array. 

FillBytes is a procedure used to initialize a specified number of bytes in an array of bytes to a specified value. 

VBytes is the array of byte to be initialized using the value specified in AValue. ACount indicates the number of bytes in the array to be given the specified value. 

FillBytes is used primarily to isolate any dependency on the platform-specific classes or procedures required for the operation in the Indy library. 

 

On the .Net platform, FillBytes calls the Clear method in the FCL System.Array class to store the specified value in the number of bytes requested. 

 

For all other platforms where the Borland RTL is supported, the FillChar procedure is called to initialize the requested number of bytes at the specified address using the value in AValue.

Internet Direct (Indy) version 10.1.5
Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Website http://www.indyproject.org.
Post feedback to the Indy Documentation newsgroup.