Synopsis

size_t saff_UTF8ToSTEP(char * instring, FILE *outfile)

Purpose

Map UTF-8 string to STEP

Description

Given an input string containing charcters in UTF-8 encoding, convert the characters to STEP Part 21 encoding using the Unicode \X2 (ISO 10646) format. See section 7.3.3.2 of the Part 21 standard for a description. See also, http://en.wikipedia.org/wiki/UTF-8 for a description of the method used for the conversion.

This function must be registered using the saff_RegisterEncoder function prior to calling the saff_FormatFile function.

The function unl_Initialize must be called prior to invoking this function.

Input

instring

The UTF-8 encoded string

outfile

File descriptor to write the Unicode string to

Return

The number of characters written.