Decodes the specified values using a decoder class reference.
function DecodeString( const aClass: TIdDecoderClass; const aIn: string ): string;
Parameters |
Description |
aClass |
Class reference to use when creating the decoder for the operation. |
aIn |
Encoded values for the operation. |
string - Un-encoded values from the operation.
DecodeString is a function used to decode values specified in AIn using an instance of the decoder class identified in AClass. DecodeString will raise an EAssertionFailed exception if the class reference in AClass has not been assigned (contains the value Nil).
DecodeString creates an instance of the class reference in AClass for use in decoding the specified values. The return value for the function is derived by by calling the DecodeString method in the decoder class instance. The decoder class instance is freed prior to exiting from the procedure.
Use the EncodeString function to perform encoding for values in a string data type using a specified encoder class.
Exceptions |
Description |
EAssertionFailed |
Raised if the decoder class reference has not been assigned. |
Decoding string values using a class reference.
[Delphi]
var sIn, sOut: String; sOut := DecodeString(TIdDecoder, sIn);
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. |