Function CDM_ExternalToUtf


Definition:#include <CDM.h>
Prototype:char * CDM_ExternalToUtf(char *encoding, char *str);
Arguments:

encoding: The encoding of the initial string. (char *)
str: A pointer to the string to be converted. (char *)


Prototype:char * CDM_ExternalToUtf(const Tcl_Encoding encoding, const char *str);
Arguments:

encoding: The encoding of the initial string. (char *)
str: A pointer to the string to be converted. (char *)

C/C++ API Sections
Tcl API Sections
Description
Return Value
Notes
See Also
Index

Description:

char * CDM_ExternalToUtf(char *encoding, char *str):
This function will convert a string (referenced by "str") from a specified encoding (provided by the "encoding" parameter) to a UTF-8 string.

This function will always create and return a new string buffer, where the converted string will be placed. The user must call CDM_Free in order to free the returned value, in case it is not needed any more.

The "encoding" parameter can be NULL. In this case, the system encoding will be used.

char * CDM_ExternalToUtf(const Tcl_Encoding encoding, const char *str):
This function will convert a string (referenced by "str") from a specified encoding (provided by the "encoding" parameter) to a UTF-8 string.

This function will always create and return a new string buffer, where the converted string will be placed. The user must call CDM_Free in order to free the returned value, in case it is not needed any more.

The "encoding" parameter can be NULL. In this case, the system encoding will be used.

Return Value:

char * CDM_ExternalToUtf(char *encoding, char *str):
This function will always create and return a new string buffer, where the converted string will be placed. The user must call CDM_Free in order to free the returned value, in case it is not needed any more.

char * CDM_ExternalToUtf(const Tcl_Encoding encoding, const char *str):
This function will always create and return a new string buffer, where the converted string will be placed. The user must call CDM_Free in order to free the returned value, in case it is not needed any more.

Notes:

char * CDM_ExternalToUtf(char *encoding, char *str):
Note that the "encoding" paramemter can be NULL. In this case, the system encoding will be used.

char * CDM_ExternalToUtf(const Tcl_Encoding encoding, const char *str):
Note that the "encoding" paramemter can be NULL. In this case, the system encoding will be used.

See Also:

char * CDM_ExternalToUtf(char *encoding, char *str):
Tcl_ExternalToUtf, Tcl_ExternalToUtfDString

char * CDM_ExternalToUtf(const Tcl_Encoding encoding, const char *str):
Tcl_ExternalToUtf, Tcl_ExternalToUtfDString


Generated by: petasis@aias on Wed Aug 16 10:31:57 PM EEST 2006.