Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Search  

ustdio.h File Reference

#include <stdio.h>
#include <stdarg.h>
#include "unicode/utypes.h"
#include "unicode/ucnv.h"
#include "unicode/utrans.h"

Go to the source code of this file.

Defines

#define U_EOF   0xFFFF
 When an end of file is encountered, this value can be returned. More...


Typedefs

typedef UFILE UFILE
 Forward declaration of a Unicode-aware file. More...


Enumerations

enum  UFileDirection { U_READ = 1, U_WRITE = 2, U_READWRITE = 3 }
 Enum for which direction of stream a transliterator applies to. More...


Functions

UFILEu_fopen (const char *filename, const char *perm, const char *locale, const char *codepage)
 Open a UFILE. More...

UFILEu_finit (FILE *f, const char *locale, const char *codepage)
 Open a UFILE on top of an existing FILE* stream. More...

void u_fclose (UFILE *file)
 Close a UFILE. More...

void u_fflush (UFILE *file)
 Flush output of a UFILE. More...

void u_frewind (UFILE *file)
 Rewind the file pointer to the beginning of the file. More...

FILE * u_fgetfile (UFILE *f)
 Get the FILE* associated with a UFILE. More...

const char * u_fgetlocale (UFILE *file)
 Get the locale whose conventions are used to format and parse output. More...

int32_t u_fsetlocale (const char *locale, UFILE *file)
 Set the locale whose conventions will be used to format and parse output. More...

const char * u_fgetcodepage (UFILE *file)
 Get the codepage in which data is written to and read from the UFILE. More...

int32_t u_fsetcodepage (const char *codepage, UFILE *file)
 Set the codepage in which data will be written to and read from the UFILE. More...

UConverteru_fgetConverter (UFILE *f)
 Returns an alias to the converter being used for this file. More...

int32_t u_fprintf (UFILE *f, const char *patternSpecification,...)
 Write formatted data to a UFILE. More...

int32_t u_vfprintf (UFILE *f, const char *patternSpecification, va_list ap)
 Write formatted data to a UFILE. More...

int32_t u_fprintf_u (UFILE *f, const UChar *patternSpecification,...)
 Write formatted data to a UFILE. More...

int32_t u_vfprintf_u (UFILE *f, const UChar *patternSpecification, va_list ap)
 Write formatted data to a UFILE. More...

int32_t u_fputs (const UChar *s, UFILE *f)
 Write a Unicode to a UFILE. More...

int32_t u_fputc (UChar uc, UFILE *f)
 Write a UChar to a UFILE. More...

int32_t u_file_write (const UChar *ustring, int32_t count, UFILE *f)
 Write Unicode to a UFILE. More...

int32_t u_fscanf (UFILE *f, const char *patternSpecification,...)
 Read formatted data from a UFILE. More...

int32_t u_vfscanf (UFILE *f, const char *patternSpecification, va_list ap)
 Read formatted data from a UFILE. More...

int32_t u_fscanf_u (UFILE *f, const UChar *patternSpecification,...)
 Read formatted data from a UFILE. More...

int32_t u_vfscanf_u (UFILE *f, const UChar *patternSpecification, va_list ap)
 Read formatted data from a UFILE. More...

UChar * u_fgets (UChar *s, int32_t n, UFILE *f)
 Read one line of text into a UChar* string from a UFILE. More...

UChar u_fgetc (UFILE *f)
 Read a UChar from a UFILE. More...

UChar32 u_fgetcx (UFILE *f)
 Read a UChar32 from a UFILE. More...

UChar32 u_fungetc (UChar32 c, UFILE *f)
 Unget a UChar from a UFILE. More...

int32_t u_file_read (UChar *chars, int32_t count, UFILE *f)
 Read Unicode from a UFILE. More...

UTransliteratoru_fsettransliterator (UFILE *file, UFileDirection direction, UTransliterator *adopt, UErrorCode *status)
 Set a transliterator on the UFILE. More...

int32_t u_sprintf (UChar *buffer, const char *locale, const char *patternSpecification,...)
 Write formatted data to a Unicode string. More...

int32_t u_snprintf (UChar *buffer, int32_t count, const char *locale, const char *patternSpecification,...)
 Write formatted data to a Unicode string. More...

int32_t u_vsprintf (UChar *buffer, const char *locale, const char *patternSpecification, va_list ap)
 Write formatted data to a Unicode string. More...

int32_t u_vsnprintf (UChar *buffer, int32_t count, const char *locale, const char *patternSpecification, va_list ap)
 Write formatted data to a Unicode string. More...

int32_t u_sprintf_u (UChar *buffer, const char *locale, const UChar *patternSpecification,...)
 Write formatted data to a Unicode string. More...

int32_t u_snprintf_u (UChar *buffer, int32_t count, const char *locale, const UChar *patternSpecification,...)
 Write formatted data to a Unicode string. More...

int32_t u_vsprintf_u (UChar *buffer, const char *locale, const UChar *patternSpecification, va_list ap)
 Write formatted data to a Unicode string. More...

int32_t u_vsnprintf_u (UChar *buffer, int32_t count, const char *locale, const UChar *patternSpecification, va_list ap)
 Write formatted data to a Unicode string. More...

int32_t u_sscanf (const UChar *buffer, const char *locale, const char *patternSpecification,...)
 Read formatted data from a Unicode string. More...

int32_t u_vsscanf (const UChar *buffer, const char *locale, const char *patternSpecification, va_list ap)
 Read formatted data from a Unicode string. More...

int32_t u_sscanf_u (const UChar *buffer, const char *locale, const UChar *patternSpecification,...)
 Read formatted data from a Unicode string. More...

int32_t u_vsscanf_u (const UChar *buffer, const char *locale, const UChar *patternSpecification, va_list ap)
 Read formatted data from a Unicode string. More...


Define Documentation

#define U_EOF   0xFFFF
 

When an end of file is encountered, this value can be returned.

See also:
u_fgetc
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

Definition at line 104 of file ustdio.h.


Typedef Documentation

typedef struct UFILE UFILE
 

Forward declaration of a Unicode-aware file.

Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

Definition at line 107 of file ustdio.h.


Enumeration Type Documentation

enum UFileDirection
 

Enum for which direction of stream a transliterator applies to.

See also:
u_fsettransliterator
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.
Enumeration values:
U_READ 
U_WRITE 
U_READWRITE 

Definition at line 114 of file ustdio.h.


Function Documentation

void u_fclose UFILE   file
 

Close a UFILE.

Parameters:
file  The UFILE to close.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

void u_fflush UFILE   file
 

Flush output of a UFILE.

Implies a flush of converter/transliterator state. (That is, a logical break is made in the output stream - for example if a different type of output is desired.) The underlying OS level file is also flushed.

Parameters:
file  The UFILE to flush.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

UConverter* u_fgetConverter UFILE   f
 

Returns an alias to the converter being used for this file.

Parameters:
file  The UFILE to set.
Returns:
alias to the converter
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

UChar u_fgetc UFILE   f
 

Read a UChar from a UFILE.

Parameters:
f  The UFILE from which to read.
Returns:
The UChar value read, or U+FFFF if no character was available.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

const char* u_fgetcodepage UFILE   file
 

Get the codepage in which data is written to and read from the UFILE.

This is the same codepage passed in the preceding call to u_fsetcodepage or u_fopen.

Parameters:
file  The UFILE to query.
Returns:
The codepage in which data is written to and read from the UFILE, or NULL if an error occurred.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

UChar32 u_fgetcx UFILE   f
 

Read a UChar32 from a UFILE.

Parameters:
f  The UFILE from which to read.
Returns:
The UChar32 value read, or U_EOF if no character was available, or U+FFFFFFFF if an ill-formed character was encountered.
See also:
u_unescape()
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

FILE* u_fgetfile UFILE   f
 

Get the FILE* associated with a UFILE.

Parameters:
f  The UFILE
Returns:
A FILE*, owned by the UFILE. The FILE must not be closed.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

const char* u_fgetlocale UFILE   file
 

Get the locale whose conventions are used to format and parse output.

This is the same locale passed in the preceding call tou_fsetlocale or u_fopen.

Parameters:
file  The UFILE to set.
Returns:
The locale whose conventions are used to format and parse output.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

UChar* u_fgets UChar *    s,
int32_t    n,
UFILE   f
 

Read one line of text into a UChar* string from a UFILE.

The newline at the end of the line is read into the string. The string is always null terminated

Parameters:
f  The UFILE from which to read.
n  The maximum number of characters - 1 to read.
s  The UChar* to receive the read data. Characters will be stored successively in s until a newline or EOF is reached. A null character (U+0000) will be appended to s.
Returns:
A pointer to s, or NULL if no characters were available.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_file_read UChar *    chars,
int32_t    count,
UFILE   f
 

Read Unicode from a UFILE.

Bytes will be converted from the UFILE's underlying codepage, with subsequent conversion to Unicode. The data will not be NULL terminated.

Parameters:
chars  A pointer to receive the Unicode data.
count  The number of Unicode characters to read.
f  The UFILE from which to read.
Returns:
The number of Unicode characters read.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_file_write const UChar *    ustring,
int32_t    count,
UFILE   f
 

Write Unicode to a UFILE.

The ustring passed in will be converted to the UFILE's underlying codepage before it is written.

Parameters:
ustring  A pointer to the Unicode data to write.
count  The number of Unicode characters to write
f  The UFILE to which to write.
Returns:
The number of Unicode characters written.
See also:
u_fputs
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

UFILE* u_finit FILE *    f,
const char *    locale,
const char *    codepage
 

Open a UFILE on top of an existing FILE* stream.

Parameters:
f  The FILE* to which this UFILE will attach.
locale  The locale whose conventions will be used to format and parse output. If this parameter is NULL, the default locale will be used.
codepage  The codepage in which data will be written to and read from the file. If this paramter is NULL, data will be written and read using the default codepage for locale, unless locale is NULL, in which case the system default codepage will be used.
Returns:
A new UFILE, or NULL if an error occurred.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

UFILE* u_fopen const char *    filename,
const char *    perm,
const char *    locale,
const char *    codepage
 

Open a UFILE.

A UFILE is a wrapper around a FILE* that is locale and codepage aware. That is, data written to a UFILE will be formatted using the conventions specified by that UFILE's Locale; this data will be in the character set specified by that UFILE's codepage.

Parameters:
filename  The name of the file to open.
perm  The read/write permission for the UFILE; one of "r", "w", "rw"
locale  The locale whose conventions will be used to format and parse output. If this parameter is NULL, the default locale will be used.
codepage  The codepage in which data will be written to and read from the file. If this paramter is NULL, data will be written and read using the default codepage for locale, unless locale is NULL, in which case the system default codepage will be used.
Returns:
A new UFILE, or NULL if an error occurred.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_fprintf UFILE   f,
const char *    patternSpecification,
...   
 

Write formatted data to a UFILE.

Parameters:
f  The UFILE to which to write.
patternSpecification  A pattern specifying how u_fprintf will interpret the variable arguments received and format the data.
Returns:
The number of Unicode characters written to f.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_fprintf_u UFILE   f,
const UChar *    patternSpecification,
...   
 

Write formatted data to a UFILE.

Parameters:
f  The UFILE to which to write.
patternSpecification  A pattern specifying how u_fprintf will interpret the variable arguments received and format the data.
Returns:
The number of Unicode characters written to f.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_fputc UChar    uc,
UFILE   f
 

Write a UChar to a UFILE.

Parameters:
uc  The UChar to write.
f  The UFILE to which to write.
Returns:
The character written if successful, EOF otherwise.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_fputs const UChar *    s,
UFILE   f
 

Write a Unicode to a UFILE.

The null (U+0000) terminated UChar* s will be written to f, excluding the NULL terminator. A newline will be added to f.

Parameters:
s  The UChar* to write.
f  The UFILE to which to write.
Returns:
A non-negative number if successful, EOF otherwise.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

void u_frewind UFILE   file
 

Rewind the file pointer to the beginning of the file.

Parameters:
file  The UFILE to rewind.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_fscanf UFILE   f,
const char *    patternSpecification,
...   
 

Read formatted data from a UFILE.

Parameters:
f  The UFILE from which to read.
patternSpecification  A pattern specifying how u_fscanf will interpret the variable arguments received and parse the data.
Returns:
The number of items successfully converted and assigned, or EOF if an error occurred.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_fscanf_u UFILE   f,
const UChar *    patternSpecification,
...   
 

Read formatted data from a UFILE.

Parameters:
f  The UFILE from which to read.
patternSpecification  A pattern specifying how u_fscanf will interpret the variable arguments received and parse the data.
Returns:
The number of items successfully converted and assigned, or EOF if an error occurred.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_fsetcodepage const char *    codepage,
UFILE   file
 

Set the codepage in which data will be written to and read from the UFILE.

All Unicode data written to the UFILE will be converted to this codepage before it is written to the underlying FILE*. It it generally a bad idea to mix codepages within a file. This should only be called right after opening the UFile, or after calling u_frewind.

Parameters:
codepage  The codepage in which data will be written to and read from the file. For example "latin-1" or "ibm-943. A value of NULL means the default codepage for the UFILE's current locale will be used.
file  The UFILE to set.
Returns:
0 if successful, otherwise a negative number.
See also:
u_frewind
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_fsetlocale const char *    locale,
UFILE   file
 

Set the locale whose conventions will be used to format and parse output.

Parameters:
locale  The locale whose conventions will be used to format and parse output.
file  The UFILE to query.
Returns:
NULL if successful, otherwise a negative number.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

UTransliterator* u_fsettransliterator UFILE   file,
UFileDirection    direction,
UTransliterator   adopt,
UErrorCode   status
 

Set a transliterator on the UFILE.

The transliterator will be owned by the UFILE.

Parameters:
file  The UFILE to set transliteration on
adopt  The UTransliterator to set. Can be NULL, which will mean that no transliteration is used.
direction  either U_READ, U_WRITE, or U_READWRITE - sets which direction the transliterator is to be applied to. If U_READWRITE, the "Read" transliteration will be in the inverse direction.
status  ICU error code.
Returns:
The previously set transliterator, owned by the caller. If U_READWRITE is specified, only the WRITE transliterator is returned. In most cases, the caller should call utrans_close() on the result of this function.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

UChar32 u_fungetc UChar32    c,
UFILE   f
 

Unget a UChar from a UFILE.

If this function is not the first to operate on f after a call to u_fgetc, the results are undefined.

Parameters:
c  The UChar to put back on the stream.
f  The UFILE to receive c.
Returns:
The UChar32 value put back if successful, U_EOF otherwise.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_snprintf UChar *    buffer,
int32_t    count,
const char *    locale,
const char *    patternSpecification,
...   
 

Write formatted data to a Unicode string.

When the number of code units required to store the data exceeds count, then count code units of data are stored in buffer and a negative value is returned. When the number of code units required to store the data equals count, the string is not null terminated and count is returned.

Parameters:
buffer  The Unicode String to which to write.
count  The number of code units to read.
locale  The locale to use for formatting the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sprintf will interpret the variable arguments received and format the data.
Returns:
The number of Unicode code units written to buffer. This does not include the terminating null character.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_snprintf_u UChar *    buffer,
int32_t    count,
const char *    locale,
const UChar *    patternSpecification,
...   
 

Write formatted data to a Unicode string.

When the number of code units required to store the data exceeds count, then count code units of data are stored in buffer and a negative value is returned. When the number of code units required to store the data equals count, the string is not null terminated and count is returned.

Parameters:
buffer  The Unicode string to which to write.
count  The number of code units to read.
locale  The locale to use for formatting the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sprintf will interpret the variable arguments received and format the data.
Returns:
The number of Unicode characters written to buffer.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_sprintf UChar *    buffer,
const char *    locale,
const char *    patternSpecification,
...   
 

Write formatted data to a Unicode string.

Parameters:
buffer  The Unicode String to which to write.
locale  The locale to use for formatting the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sprintf will interpret the variable arguments received and format the data.
Returns:
The number of Unicode code units written to buffer. This does not include the terminating null character.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_sprintf_u UChar *    buffer,
const char *    locale,
const UChar *    patternSpecification,
...   
 

Write formatted data to a Unicode string.

Parameters:
buffer  The Unicode string to which to write.
locale  The locale to use for formatting the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sprintf will interpret the variable arguments received and format the data.
Returns:
The number of Unicode characters written to buffer.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_sscanf const UChar *    buffer,
const char *    locale,
const char *    patternSpecification,
...   
 

Read formatted data from a Unicode string.

Parameters:
buffer  The Unicode string from which to read.
locale  The locale to use for parsing the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sscanf will interpret the variable arguments received and parse the data.
Returns:
The number of items successfully converted and assigned, or EOF if an error occurred.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_sscanf_u const UChar *    buffer,
const char *    locale,
const UChar *    patternSpecification,
...   
 

Read formatted data from a Unicode string.

Parameters:
buffer  The Unicode string from which to read.
locale  The locale to use for parsing the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sscanf will interpret the variable arguments received and parse the data.
Returns:
The number of items successfully converted and assigned, or EOF if an error occurred.
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vfprintf UFILE   f,
const char *    patternSpecification,
va_list    ap
 

Write formatted data to a UFILE.

This is identical to u_fprintf, except that it will not call va_start/TT> and va_end.

Parameters:
f  The UFILE to which to write.
patternSpecification  A pattern specifying how u_fprintf will interpret the variable arguments received and format the data.
ap  The argument list to use.
Returns:
The number of Unicode characters written to f.
See also:
u_fprintf
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vfprintf_u UFILE   f,
const UChar *    patternSpecification,
va_list    ap
 

Write formatted data to a UFILE.

This is identical to u_fprintf_u, except that it will not call va_start/TT> and va_end.

Parameters:
f  The UFILE to which to write.
patternSpecification  A pattern specifying how u_fprintf will interpret the variable arguments received and format the data.
ap  The argument list to use.
Returns:
The number of Unicode characters written to f.
See also:
u_fprintf_u
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vfscanf UFILE   f,
const char *    patternSpecification,
va_list    ap
 

Read formatted data from a UFILE.

This is identical to u_fscanf, except that it will not call va_start/TT> and va_end.

Parameters:
f  The UFILE from which to read.
patternSpecification  A pattern specifying how u_fscanf will interpret the variable arguments received and parse the data.
ap  The argument list to use.
Returns:
The number of items successfully converted and assigned, or EOF if an error occurred.
See also:
u_fscanf
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vfscanf_u UFILE   f,
const UChar *    patternSpecification,
va_list    ap
 

Read formatted data from a UFILE.

This is identical to u_fscanf_u, except that it will not call va_start/TT> and va_end.

Parameters:
f  The UFILE from which to read.
patternSpecification  A pattern specifying how u_fscanf will interpret the variable arguments received and parse the data.
ap  The argument list to use.
Returns:
The number of items successfully converted and assigned, or EOF if an error occurred.
See also:
u_fscanf_u
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vsnprintf UChar *    buffer,
int32_t    count,
const char *    locale,
const char *    patternSpecification,
va_list    ap
 

Write formatted data to a Unicode string.

This is identical to u_snprintf, except that it will not call va_start/TT> and va_end.

When the number of code units required to store the data exceeds count, then count code units of data are stored in buffer and a negative value is returned. When the number of code units required to store the data equals count, the string is not null terminated and count is returned.

Parameters:
buffer  The Unicode string to which to write.
count  The number of code units to read.
locale  The locale to use for formatting the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sprintf will interpret the variable arguments received and format the data.
ap  The argument list to use.
Returns:
The number of Unicode characters written to buffer.
See also:
u_sprintf
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vsnprintf_u UChar *    buffer,
int32_t    count,
const char *    locale,
const UChar *    patternSpecification,
va_list    ap
 

Write formatted data to a Unicode string.

This is identical to u_snprintf_u, except that it will not call va_start/TT> and va_end. When the number of code units required to store the data exceeds count, then count code units of data are stored in buffer and a negative value is returned. When the number of code units required to store the data equals count, the string is not null terminated and count is returned.

Parameters:
buffer  The Unicode string to which to write.
locale  The locale to use for formatting the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sprintf will interpret the variable arguments received and format the data.
ap  The argument list to use.
Returns:
The number of Unicode characters written to f.
See also:
u_sprintf_u
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vsprintf UChar *    buffer,
const char *    locale,
const char *    patternSpecification,
va_list    ap
 

Write formatted data to a Unicode string.

This is identical to u_sprintf, except that it will not call va_start/TT> and va_end.

Parameters:
buffer  The Unicode string to which to write.
locale  The locale to use for formatting the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sprintf will interpret the variable arguments received and format the data.
ap  The argument list to use.
Returns:
The number of Unicode characters written to buffer.
See also:
u_sprintf
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vsprintf_u UChar *    buffer,
const char *    locale,
const UChar *    patternSpecification,
va_list    ap
 

Write formatted data to a Unicode string.

This is identical to u_sprintf_u, except that it will not call va_start/TT> and va_end.

Parameters:
buffer  The Unicode string to which to write.
count  The number of code units to read.
locale  The locale to use for formatting the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sprintf will interpret the variable arguments received and format the data.
ap  The argument list to use.
Returns:
The number of Unicode characters written to f.
See also:
u_sprintf_u
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vsscanf const UChar *    buffer,
const char *    locale,
const char *    patternSpecification,
va_list    ap
 

Read formatted data from a Unicode string.

This is identical to u_sscanf, except that it will not call va_start/TT> and va_end.

Parameters:
buffer  The Unicode string from which to read.
locale  The locale to use for parsing the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sscanf will interpret the variable arguments received and parse the data.
ap  The argument list to use.
Returns:
The number of items successfully converted and assigned, or EOF if an error occurred.
See also:
u_sscanf
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.

int32_t u_vsscanf_u const UChar *    buffer,
const char *    locale,
const UChar *    patternSpecification,
va_list    ap
 

Read formatted data from a Unicode string.

This is identical to u_sscanf_u, except that it will not call va_start/TT> and va_end.

Parameters:
buffer  The UFILE from which to read.
locale  The locale to use for parsing the numbers, dates and other locale specific information.
patternSpecification  A pattern specifying how u_sscanf will interpret the variable arguments received and parse the data.
ap  The argument list to use.
Returns:
The number of items successfully converted and assigned, or EOF if an error occurred.
See also:
u_sscanf_u
Draft:
This API has been introduced in . It is still in draft state and may be modified in a future release.


Generated on Mon Nov 24 14:36:07 2003 for ICU 2.8 by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001