00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef USTDIO_H
00023 #define USTDIO_H
00024
00025 #include <stdio.h>
00026 #include <stdarg.h>
00027
00028 #include "unicode/utypes.h"
00029 #include "unicode/ucnv.h"
00030 #include "unicode/utrans.h"
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00104 #define U_EOF 0xFFFF
00105
00107 typedef struct UFILE UFILE;
00108
00114 typedef enum {
00115 U_READ = 1,
00116 U_WRITE = 2,
00117 U_READWRITE =3
00118 } UFileDirection;
00119
00138 U_CAPI UFILE* U_EXPORT2
00139 u_fopen(const char *filename,
00140 const char *perm,
00141 const char *locale,
00142 const char *codepage);
00143
00157 U_CAPI UFILE* U_EXPORT2
00158 u_finit(FILE *f,
00159 const char *locale,
00160 const char *codepage);
00161
00167 U_CAPI void U_EXPORT2
00168 u_fclose(UFILE *file);
00169
00178 U_CAPI void U_EXPORT2
00179 u_fflush(UFILE *file);
00180
00186 U_CAPI void
00187 u_frewind(UFILE *file);
00188
00195 U_CAPI FILE* U_EXPORT2
00196 u_fgetfile(UFILE *f);
00197
00198 #if !UCONFIG_NO_FORMATTING
00199
00208 U_CAPI const char* U_EXPORT2
00209 u_fgetlocale(UFILE *file);
00210
00219 U_CAPI int32_t U_EXPORT2
00220 u_fsetlocale(const char *locale,
00221 UFILE *file);
00222
00223 #endif
00224
00234 U_CAPI const char* U_EXPORT2
00235 u_fgetcodepage(UFILE *file);
00236
00252 U_CAPI int32_t U_EXPORT2
00253 u_fsetcodepage(const char *codepage,
00254 UFILE *file);
00255
00256
00263 U_CAPI UConverter* U_EXPORT2 u_fgetConverter(UFILE *f);
00264
00265
00266
00275 U_CAPI int32_t U_EXPORT2
00276 u_fprintf(UFILE *f,
00277 const char *patternSpecification,
00278 ... );
00279
00292 U_CAPI int32_t U_EXPORT2
00293 u_vfprintf(UFILE *f,
00294 const char *patternSpecification,
00295 va_list ap);
00296
00305 U_CAPI int32_t U_EXPORT2
00306 u_fprintf_u(UFILE *f,
00307 const UChar *patternSpecification,
00308 ... );
00309
00322 U_CAPI int32_t U_EXPORT2
00323 u_vfprintf_u(UFILE *f,
00324 const UChar *patternSpecification,
00325 va_list ap);
00326
00336 U_CAPI int32_t U_EXPORT2
00337 u_fputs(const UChar *s,
00338 UFILE *f);
00339
00347 U_CAPI int32_t U_EXPORT2
00348 u_fputc(UChar uc,
00349 UFILE *f);
00350
00362 U_CAPI int32_t U_EXPORT2
00363 u_file_write(const UChar *ustring,
00364 int32_t count,
00365 UFILE *f);
00366
00367
00368
00369
00379 U_CAPI int32_t U_EXPORT2
00380 u_fscanf(UFILE *f,
00381 const char *patternSpecification,
00382 ... );
00383
00397 U_CAPI int32_t U_EXPORT2
00398 u_vfscanf(UFILE *f,
00399 const char *patternSpecification,
00400 va_list ap);
00401
00411 U_CAPI int32_t U_EXPORT2
00412 u_fscanf_u(UFILE *f,
00413 const UChar *patternSpecification,
00414 ... );
00415
00429 U_CAPI int32_t U_EXPORT2
00430 u_vfscanf_u(UFILE *f,
00431 const UChar *patternSpecification,
00432 va_list ap);
00433
00446 U_CAPI UChar* U_EXPORT2
00447 u_fgets(UChar *s,
00448 int32_t n,
00449 UFILE *f);
00450
00457 U_CAPI UChar U_EXPORT2
00458 u_fgetc(UFILE *f);
00459
00470 U_CAPI UChar32 U_EXPORT2
00471 u_fgetcx(UFILE *f);
00472
00482 U_CAPI UChar32 U_EXPORT2
00483 u_fungetc(UChar32 c,
00484 UFILE *f);
00485
00496 U_CAPI int32_t U_EXPORT2
00497 u_file_read(UChar *chars,
00498 int32_t count,
00499 UFILE *f);
00500
00501 #if !UCONFIG_NO_TRANSLITERATION
00502
00520 U_CAPI UTransliterator* U_EXPORT2
00521 u_fsettransliterator(UFILE *file, UFileDirection direction,
00522 UTransliterator *adopt, UErrorCode *status);
00523
00524 #endif
00525
00526
00527
00528
00529
00542 U_CAPI int32_t U_EXPORT2
00543 u_sprintf(UChar *buffer,
00544 const char *locale,
00545 const char *patternSpecification,
00546 ... );
00547
00566 U_CAPI int32_t U_EXPORT2
00567 u_snprintf(UChar *buffer,
00568 int32_t count,
00569 const char *locale,
00570 const char *patternSpecification,
00571 ... );
00572
00588 U_CAPI int32_t U_EXPORT2
00589 u_vsprintf(UChar *buffer,
00590 const char *locale,
00591 const char *patternSpecification,
00592 va_list ap);
00593
00615 U_CAPI int32_t U_EXPORT2
00616 u_vsnprintf(UChar *buffer,
00617 int32_t count,
00618 const char *locale,
00619 const char *patternSpecification,
00620 va_list ap);
00621
00633 U_CAPI int32_t U_EXPORT2
00634 u_sprintf_u(UChar *buffer,
00635 const char *locale,
00636 const UChar *patternSpecification,
00637 ... );
00638
00656 U_CAPI int32_t U_EXPORT2
00657 u_snprintf_u(UChar *buffer,
00658 int32_t count,
00659 const char *locale,
00660 const UChar *patternSpecification,
00661 ... );
00662
00679 U_CAPI int32_t U_EXPORT2
00680 u_vsprintf_u(UChar *buffer,
00681 const char *locale,
00682 const UChar *patternSpecification,
00683 va_list ap);
00684
00705 U_CAPI int32_t U_EXPORT2
00706 u_vsnprintf_u(UChar *buffer,
00707 int32_t count,
00708 const char *locale,
00709 const UChar *patternSpecification,
00710 va_list ap);
00711
00712
00713
00726 U_CAPI int32_t U_EXPORT2
00727 u_sscanf(const UChar *buffer,
00728 const char *locale,
00729 const char *patternSpecification,
00730 ... );
00731
00748 U_CAPI int32_t U_EXPORT2
00749 u_vsscanf(const UChar *buffer,
00750 const char *locale,
00751 const char *patternSpecification,
00752 va_list ap);
00753
00766 U_CAPI int32_t U_EXPORT2
00767 u_sscanf_u(const UChar *buffer,
00768 const char *locale,
00769 const UChar *patternSpecification,
00770 ... );
00771
00788 U_CAPI int32_t U_EXPORT2
00789 u_vsscanf_u(const UChar *buffer,
00790 const char *locale,
00791 const UChar *patternSpecification,
00792 va_list ap);
00793
00794
00795 #endif
00796
00797