Web.HTTPApp.EncodingGetBytes

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

function EncodingGetBytes(const AContentType: string; const AValue: string): TBytes;

C++

extern DELPHI_PACKAGE System::DynamicArray<System::Byte> __fastcall EncodingGetBytes(const System::UnicodeString AContentType, const System::UnicodeString AValue);

Properties

Type Visibility Source Unit Parent
function public
Web.HTTPApp.pas
Web.HTTPApp.hpp
Web.HTTPApp Web.HTTPApp

Description

Encodes a string into an array of bytes, in accordance with the content type encoding.

EncodingGetBytes extracts from AContentType the content type encoding (can be UTF-8 or ANSI) and encodes the string AValue into the corresponding array of bytes.

The inverse function is EncodingGetString.

See Also