Topic Path: Pending > TIdBuffer.ExtractToIdBuffer@TIdBuffer@Integer
ContentsIndexHome
PreviousUpNext
TIdBuffer.ExtractToIdBuffer@TIdBuffer@Integer

Retrieves and removes data from the buffer.

Parameters 
Description 
ABuffer 
Storage for values extracted from the buffer.
 
AByteCount 
Number of bytes requested from the buffer. 

ExtractToIdBuffer is a procedure used to extract data from the buffer into the ABuffer argument. 

ABuffer is another TIdBuffer instance used to store values extracted from the current buffer. 

AByteCount indicates the number of bytes requested from the internal storage for the buffer. 

ExtractToIdBuffer checks the Size of Bytes to ensure that the requested number of bytes in AByteCount are available in the buffer. When the data is available, ExtractToIdBuffer will increase the size of ABuffer to allow storing the extracted values. 

ExtractToIdBuffer calls CopyTIdBytes to perform the copy operation. 

ExtractToBytes calls Remove with the AByteCount argument to remove the extracted data from the internal storage for the buffer. 

Use Extract to retrieve and remove data from the buffer as a Delphi string data type. 

Use ExtractToBytes to retrieve and remove data from the buffer into an array of Byte storage variable. 

Use ExtractToStream to retrieve and remove data from the buffer into a TIdStream instance.

Exceptions 
Description 
Raised with RSNotEnoughDataInBuffer and the requested byte count. 
Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Post feedback to the Indy Docs Newsgroup.