Logo Search packages:      
Sourcecode: icu version File versions

U_STABLE int32_t U_EXPORT2 u_formatMessageWithError ( const char *  locale,
const UChar *  pattern,
int32_t  patternLength,
UChar *  result,
int32_t  resultLength,
UParseError parseError,
UErrorCode status,

Format a message for a locale. This function may perform re-ordering of the arguments depending on the locale. For all numeric arguments, double is assumed unless the type is explicitly integer. All choice format arguments must be of type double.

locale The locale for which the message will be formatted
pattern The pattern specifying the message's format
patternLength The length of pattern
result A pointer to a buffer to receive the formatted message.
resultLength The maximum size of result.
status A pointer to an UErrorCode to receive any errors
... A variable-length argument list containing the arguments specified in pattern.
parseError A pointer to UParseError to receive information about errors occurred during parsing.
The total buffer size needed; if greater than resultLength, the output was truncated.
See also:
u_parseMessage ICU 2.0

Definition at line 77 of file umsg.cpp.

    va_list    ap;
    int32_t actLen;
    //argument checking defered to subsequent method calls
    // start vararg processing
    va_start(ap, status);

    actLen = u_vformatMessageWithError(locale,pattern,patternLength,result,resultLength,parseError,ap,status);

    // end vararg processing
    return actLen;

Generated by  Doxygen 1.6.0   Back to index