Retrieves and removes data from the buffer.
Parameters |
Description |
VBytes |
Storage for values extracted from the buffer. |
AByteCount |
Number of bytes requested from the buffer. |
AAppend |
Append values to exisitng bytes in the destination. |
ExtractToBytes is a procedure used to extract data from the buffer into the vBytes argument.
AByteCount indicates the number of bytes requested from the internal storage for the buffer. AByteCount must be a positive non-zero value, or no data is extracted into vBytes.
ExtractToBytes checks the Size of Bytes to ensure that the requested number of bytes in AByteCount is available in the buffer. When the data is available, ExtractToBytes will increase the length of VBytes to allow storing the extracted values, and calls CopyTIdBytes to perform the copy operation.
AAppend indicates that values extracted from the buffer are appended to existing byte values in VBytes. When AAppend is False, the contents of VBytes is overwritten with the values extracted from the buffer. The default value for AAppend is True.
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 ExtractToIdBuffer to retrieve and remove data from the buffer into another TIdBuffer instance.
Use ExtractToStream to retrieve and remove data from the buffer into a TIdStream instance.
Exceptions |
Description |
Raised with RSNotEnoughDataInBuffer and the requested byte count. |
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. |