|
|
|
@ -85,137 +85,280 @@ ZEND_DECLARE_MODULE_GLOBALS( intl ) |
|
|
|
|
|
|
|
/* {{{ Arguments info */ |
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( collator_static_0_args, 0, 0, 0 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(collator_static_0_args, 0, 0, 0) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( collator_static_1_arg, 0, 0, 1 ) |
|
|
|
ZEND_ARG_INFO( 0, arg1 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(collator_static_1_arg, 0, 0, 1) |
|
|
|
ZEND_ARG_INFO(0, arg1) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( collator_static_2_args, 0, 0, 2 ) |
|
|
|
ZEND_ARG_INFO( 0, arg1 ) |
|
|
|
ZEND_ARG_INFO( 0, arg2 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(collator_static_2_args, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, arg1) |
|
|
|
ZEND_ARG_INFO(0, arg2) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( collator_0_args, 0, 0, 1 ) |
|
|
|
ZEND_ARG_OBJ_INFO( 0, object, Collator, 0 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(collator_0_args, 0, 0, 1) |
|
|
|
ZEND_ARG_OBJ_INFO(0, object, Collator, 0) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( collator_1_arg, 0, 0, 2 ) |
|
|
|
ZEND_ARG_OBJ_INFO( 0, object, Collator, 0 ) |
|
|
|
ZEND_ARG_INFO( 0, arg1 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(collator_1_arg, 0, 0, 2) |
|
|
|
ZEND_ARG_OBJ_INFO(0, object, Collator, 0) |
|
|
|
ZEND_ARG_INFO(0, arg1) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( collator_2_args, 0, 0, 3 ) |
|
|
|
ZEND_ARG_OBJ_INFO( 0, object, Collator, 0 ) |
|
|
|
ZEND_ARG_INFO( 0, arg1 ) |
|
|
|
ZEND_ARG_INFO( 0, arg2 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(collator_2_args, 0, 0, 3) |
|
|
|
ZEND_ARG_OBJ_INFO(0, object, Collator, 0) |
|
|
|
ZEND_ARG_INFO(0, arg1) |
|
|
|
ZEND_ARG_INFO(0, arg2) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( collator_sort_args, 0, 0, 2 ) |
|
|
|
ZEND_ARG_OBJ_INFO( 0, object, Collator, 0 ) |
|
|
|
ZEND_ARG_ARRAY_INFO( 1, arr, 0 ) |
|
|
|
ZEND_ARG_INFO( 0, sort_flags ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(collator_sort_args, 0, 0, 2) |
|
|
|
ZEND_ARG_OBJ_INFO(0, object, Collator, 0) |
|
|
|
ZEND_ARG_ARRAY_INFO(1, arr, 0) |
|
|
|
ZEND_ARG_INFO(0, sort_flags) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
ZEND_BEGIN_ARG_INFO_EX( numfmt_parse_arginfo, 0, 0, 2 ) |
|
|
|
ZEND_ARG_INFO( 0, formatter ) |
|
|
|
ZEND_ARG_INFO( 0, string ) |
|
|
|
ZEND_ARG_INFO( 0, type ) |
|
|
|
ZEND_ARG_INFO( 1, position ) |
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(numfmt_parse_arginfo, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, formatter) |
|
|
|
ZEND_ARG_INFO(0, string) |
|
|
|
ZEND_ARG_INFO(0, type) |
|
|
|
ZEND_ARG_INFO(1, position) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
ZEND_BEGIN_ARG_INFO_EX( numfmt_parse_currency_arginfo, 0, 0, 3 ) |
|
|
|
ZEND_ARG_INFO( 0, formatter ) |
|
|
|
ZEND_ARG_INFO( 0, string ) |
|
|
|
ZEND_ARG_INFO( 1, currency ) |
|
|
|
ZEND_ARG_INFO( 1, position ) |
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(numfmt_parse_currency_arginfo, 0, 0, 3) |
|
|
|
ZEND_ARG_INFO(0, formatter) |
|
|
|
ZEND_ARG_INFO(0, string) |
|
|
|
ZEND_ARG_INFO(1, currency) |
|
|
|
ZEND_ARG_INFO(1, position) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( locale_0_args, 0, 0, 0 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(locale_0_args, 0, 0, 0) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( locale_1_arg, 0, 0, 1 ) |
|
|
|
ZEND_ARG_INFO( 0, arg1 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(locale_1_arg, 0, 0, 1) |
|
|
|
ZEND_ARG_INFO(0, arg1) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( locale_2_args, 0, 0, 2 ) |
|
|
|
ZEND_ARG_INFO( 0, arg1 ) |
|
|
|
ZEND_ARG_INFO( 0, arg2 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(locale_2_args, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, arg1) |
|
|
|
ZEND_ARG_INFO(0, arg2) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( locale_3_args, 0, 0, 3 ) |
|
|
|
ZEND_ARG_INFO( 0, arg1 ) |
|
|
|
ZEND_ARG_INFO( 0, arg2 ) |
|
|
|
ZEND_ARG_INFO( 0, arg3 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(locale_3_args, 0, 0, 3) |
|
|
|
ZEND_ARG_INFO(0, arg1) |
|
|
|
ZEND_ARG_INFO(0, arg2) |
|
|
|
ZEND_ARG_INFO(0, arg3) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( locale_4_args, 0, 0, 4 ) |
|
|
|
ZEND_ARG_INFO( 0, arg1 ) |
|
|
|
ZEND_ARG_INFO( 0, arg2 ) |
|
|
|
ZEND_ARG_INFO( 0, arg3 ) |
|
|
|
ZEND_ARG_INFO( 0, arg4 ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(locale_4_args, 0, 0, 4) |
|
|
|
ZEND_ARG_INFO(0, arg1) |
|
|
|
ZEND_ARG_INFO(0, arg2) |
|
|
|
ZEND_ARG_INFO(0, arg3) |
|
|
|
ZEND_ARG_INFO(0, arg4) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
#define intl_0_args collator_static_0_args |
|
|
|
#define intl_1_arg collator_static_1_arg |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( normalizer_args, 0, 0, 1 ) |
|
|
|
ZEND_ARG_INFO( 0, input ) |
|
|
|
ZEND_ARG_INFO( 0, form ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(normalizer_args, 0, 0, 1) |
|
|
|
ZEND_ARG_INFO(0, input) |
|
|
|
ZEND_ARG_INFO(0, form) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(grapheme_1_arg, 0, 0, 1) |
|
|
|
ZEND_ARG_INFO(0, string) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(grapheme_search_args, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, haystack) |
|
|
|
ZEND_ARG_INFO(0, needle) |
|
|
|
ZEND_ARG_INFO(0, offset) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(grapheme_substr_args, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, string) |
|
|
|
ZEND_ARG_INFO(0, start) |
|
|
|
ZEND_ARG_INFO(0, length) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(grapheme_strstr_args, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, haystack) |
|
|
|
ZEND_ARG_INFO(0, needle) |
|
|
|
ZEND_ARG_INFO(0, before_needle) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(grapheme_extract_args, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, arg1) |
|
|
|
ZEND_ARG_INFO(0, arg2) |
|
|
|
ZEND_ARG_INFO(0, arg3) |
|
|
|
ZEND_ARG_INFO(0, arg4) |
|
|
|
ZEND_ARG_INFO(1, arg5) /* 1 = pass by reference */ |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(datefmt_parse_args, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, formatter) |
|
|
|
ZEND_ARG_INFO(0, string) |
|
|
|
ZEND_ARG_INFO(1, position) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_create, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, locale) |
|
|
|
ZEND_ARG_INFO(0, style) |
|
|
|
ZEND_ARG_INFO(0, pattern) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_get_error_code, 0, 0, 1) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_format, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_ARG_INFO(0, num) |
|
|
|
ZEND_ARG_INFO(0, type) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_format_currency, 0, 0, 3) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_ARG_INFO(0, num) |
|
|
|
ZEND_ARG_INFO(0, currency) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_get_attribute, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_ARG_INFO(0, attr) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_set_attribute, 0, 0, 3) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_ARG_INFO(0, attr) |
|
|
|
ZEND_ARG_INFO(0, value) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_set_symbol, 0, 0, 3) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_ARG_INFO(0, attr) |
|
|
|
ZEND_ARG_INFO(0, symbol) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_set_pattern, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_ARG_INFO(0, pattern) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( grapheme_1_arg, 0, 0, 1 ) |
|
|
|
ZEND_ARG_INFO( 0, string ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_get_locale, 0, 0, 1) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_ARG_INFO(0, type) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( grapheme_search_args, 0, 0, 2 ) |
|
|
|
ZEND_ARG_INFO( 0, haystack ) |
|
|
|
ZEND_ARG_INFO( 0, needle ) |
|
|
|
ZEND_ARG_INFO( 0, offset ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_msgfmt_create, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, locale) |
|
|
|
ZEND_ARG_INFO(0, pattern) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( grapheme_substr_args, 0, 0, 2 ) |
|
|
|
ZEND_ARG_INFO( 0, string ) |
|
|
|
ZEND_ARG_INFO( 0, start ) |
|
|
|
ZEND_ARG_INFO( 0, length ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_msgfmt_get_error_code, 0, 0, 1) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX( grapheme_strstr_args, 0, 0, 2 ) |
|
|
|
ZEND_ARG_INFO( 0, haystack ) |
|
|
|
ZEND_ARG_INFO( 0, needle ) |
|
|
|
ZEND_ARG_INFO( 0, before_needle ) |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_msgfmt_get_error_message, 0, 0, 1) |
|
|
|
ZEND_ARG_INFO(0, coll) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
ZEND_BEGIN_ARG_INFO_EX( grapheme_extract_args, 0, 0, 2 ) |
|
|
|
ZEND_ARG_INFO( 0, arg1 ) |
|
|
|
ZEND_ARG_INFO( 0, arg2 ) |
|
|
|
ZEND_ARG_INFO( 0, arg3 ) |
|
|
|
ZEND_ARG_INFO( 0, arg4 ) |
|
|
|
ZEND_ARG_INFO( 1, arg5 ) /* 1 = pass by reference */ |
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_msgfmt_format, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_ARG_INFO(0, args) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_msgfmt_format_message, 0, 0, 3) |
|
|
|
ZEND_ARG_INFO(0, locale) |
|
|
|
ZEND_ARG_INFO(0, pattern) |
|
|
|
ZEND_ARG_INFO(0, args) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
ZEND_BEGIN_ARG_INFO_EX( datefmt_parse_args, 0, 0, 2 ) |
|
|
|
ZEND_ARG_INFO( 0, formatter ) |
|
|
|
ZEND_ARG_INFO( 0, string ) |
|
|
|
ZEND_ARG_INFO( 1, position ) |
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_msgfmt_parse, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, nf) |
|
|
|
ZEND_ARG_INFO(0, source) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_numfmt_parse_message, 0, 0, 3) |
|
|
|
ZEND_ARG_INFO(0, locale) |
|
|
|
ZEND_ARG_INFO(0, pattern) |
|
|
|
ZEND_ARG_INFO(0, source) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_msgfmt_set_pattern, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, mf) |
|
|
|
ZEND_ARG_INFO(0, pattern) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_msgfmt_get_locale, 0, 0, 1) |
|
|
|
ZEND_ARG_INFO(0, mf) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_datefmt_set_pattern, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, mf) |
|
|
|
ZEND_ARG_INFO(0, pattern) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_datefmt_set_calendar, 0, 0, 2) |
|
|
|
ZEND_ARG_INFO(0, mf) |
|
|
|
ZEND_ARG_INFO(0, calendar) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_datefmt_format, 0, 0, 0) |
|
|
|
ZEND_ARG_INFO(0, args) |
|
|
|
ZEND_ARG_INFO(0, array) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
|
|
|
|
static |
|
|
|
ZEND_BEGIN_ARG_INFO_EX(arginfo_datefmt_create, 0, 0, 3) |
|
|
|
ZEND_ARG_INFO(0, locale) |
|
|
|
ZEND_ARG_INFO(0, date_type) |
|
|
|
ZEND_ARG_INFO(0, time_type) |
|
|
|
ZEND_ARG_INFO(0, timezone_str) |
|
|
|
ZEND_ARG_INFO(0, calendar) |
|
|
|
ZEND_ARG_INFO(0, pattern) |
|
|
|
ZEND_END_ARG_INFO() |
|
|
|
/* }}} */ |
|
|
|
|
|
|
|
/* {{{ intl_functions |
|
|
|
@ -224,7 +367,7 @@ ZEND_END_ARG_INFO() |
|
|
|
*/ |
|
|
|
zend_function_entry intl_functions[] = { |
|
|
|
|
|
|
|
// collator functions |
|
|
|
/* collator functions */ |
|
|
|
PHP_FE( collator_create, collator_static_1_arg ) |
|
|
|
PHP_FE( collator_compare, collator_2_args ) |
|
|
|
PHP_FE( collator_get_attribute, collator_1_arg ) |
|
|
|
@ -238,29 +381,29 @@ zend_function_entry intl_functions[] = { |
|
|
|
PHP_FE( collator_get_error_code, collator_0_args ) |
|
|
|
PHP_FE( collator_get_error_message, collator_0_args ) |
|
|
|
|
|
|
|
// formatter functions |
|
|
|
PHP_FE( numfmt_create, NULL ) |
|
|
|
PHP_FE( numfmt_format, NULL ) |
|
|
|
/* formatter functions */ |
|
|
|
PHP_FE( numfmt_create, arginfo_numfmt_create ) |
|
|
|
PHP_FE( numfmt_format, arginfo_numfmt_format ) |
|
|
|
PHP_FE( numfmt_parse, numfmt_parse_arginfo ) |
|
|
|
PHP_FE( numfmt_format_currency, NULL ) |
|
|
|
PHP_FE( numfmt_format_currency, arginfo_numfmt_format_currency ) |
|
|
|
PHP_FE( numfmt_parse_currency, numfmt_parse_currency_arginfo ) |
|
|
|
PHP_FE( numfmt_set_attribute, NULL ) |
|
|
|
PHP_FE( numfmt_get_attribute, NULL ) |
|
|
|
PHP_FE( numfmt_set_text_attribute, NULL ) |
|
|
|
PHP_FE( numfmt_get_text_attribute, NULL ) |
|
|
|
PHP_FE( numfmt_set_symbol, NULL ) |
|
|
|
PHP_FE( numfmt_get_symbol, NULL ) |
|
|
|
PHP_FE( numfmt_set_pattern, NULL ) |
|
|
|
PHP_FE( numfmt_get_pattern, NULL ) |
|
|
|
PHP_FE( numfmt_get_locale, NULL ) |
|
|
|
PHP_FE( numfmt_get_error_code, NULL ) |
|
|
|
PHP_FE( numfmt_get_error_message, NULL ) |
|
|
|
|
|
|
|
// normalizer functions |
|
|
|
PHP_FE( numfmt_set_attribute, arginfo_numfmt_set_attribute ) |
|
|
|
PHP_FE( numfmt_get_attribute, arginfo_numfmt_get_attribute ) |
|
|
|
PHP_FE( numfmt_set_text_attribute, arginfo_numfmt_set_attribute ) |
|
|
|
PHP_FE( numfmt_get_text_attribute, arginfo_numfmt_get_attribute ) |
|
|
|
PHP_FE( numfmt_set_symbol, arginfo_numfmt_set_symbol ) |
|
|
|
PHP_FE( numfmt_get_symbol, arginfo_numfmt_get_attribute ) |
|
|
|
PHP_FE( numfmt_set_pattern, arginfo_numfmt_set_pattern ) |
|
|
|
PHP_FE( numfmt_get_pattern, arginfo_numfmt_get_error_code ) |
|
|
|
PHP_FE( numfmt_get_locale, arginfo_numfmt_get_locale ) |
|
|
|
PHP_FE( numfmt_get_error_code, arginfo_numfmt_get_error_code ) |
|
|
|
PHP_FE( numfmt_get_error_message, arginfo_numfmt_get_error_code ) |
|
|
|
|
|
|
|
/* normalizer functions */ |
|
|
|
PHP_FE( normalizer_normalize, normalizer_args ) |
|
|
|
PHP_FE( normalizer_is_normalized, normalizer_args ) |
|
|
|
|
|
|
|
//Locale functions |
|
|
|
/* Locale functions */ |
|
|
|
PHP_NAMED_FE( locale_get_default, zif_locale_get_default, locale_0_args ) |
|
|
|
PHP_NAMED_FE( locale_set_default, zif_locale_set_default, locale_1_arg ) |
|
|
|
PHP_FE( locale_get_primary_language, locale_1_arg ) |
|
|
|
@ -280,38 +423,38 @@ zend_function_entry intl_functions[] = { |
|
|
|
PHP_FE( locale_lookup, locale_4_args ) |
|
|
|
PHP_FE( locale_accept_from_http, locale_1_arg ) |
|
|
|
|
|
|
|
// MessageFormatter functions |
|
|
|
PHP_FE( msgfmt_create, NULL ) |
|
|
|
PHP_FE( msgfmt_format, NULL ) |
|
|
|
PHP_FE( msgfmt_format_message, NULL ) |
|
|
|
PHP_FE( msgfmt_parse, NULL ) |
|
|
|
PHP_FE( msgfmt_parse_message, NULL ) |
|
|
|
PHP_FE( msgfmt_set_pattern, NULL ) |
|
|
|
PHP_FE( msgfmt_get_pattern, NULL ) |
|
|
|
PHP_FE( msgfmt_get_locale, NULL ) |
|
|
|
PHP_FE( msgfmt_get_error_code, NULL ) |
|
|
|
PHP_FE( msgfmt_get_error_message, NULL ) |
|
|
|
|
|
|
|
// IntlDateFormatter functions |
|
|
|
PHP_FE( datefmt_create, NULL ) |
|
|
|
PHP_FE( datefmt_get_datetype, NULL ) |
|
|
|
PHP_FE( datefmt_get_timetype, NULL ) |
|
|
|
PHP_FE( datefmt_get_calendar, NULL ) |
|
|
|
PHP_FE( datefmt_set_calendar, NULL ) |
|
|
|
PHP_FE( datefmt_get_locale, NULL ) |
|
|
|
PHP_FE( datefmt_get_timezone_id, NULL ) |
|
|
|
PHP_FE( datefmt_set_timezone_id, NULL ) |
|
|
|
PHP_FE( datefmt_get_pattern, NULL ) |
|
|
|
PHP_FE( datefmt_set_pattern, NULL ) |
|
|
|
PHP_FE( datefmt_is_lenient, NULL ) |
|
|
|
PHP_FE( datefmt_set_lenient, NULL ) |
|
|
|
PHP_FE( datefmt_format, NULL ) |
|
|
|
/* MessageFormatter functions */ |
|
|
|
PHP_FE( msgfmt_create, arginfo_msgfmt_create ) |
|
|
|
PHP_FE( msgfmt_format, arginfo_msgfmt_format ) |
|
|
|
PHP_FE( msgfmt_format_message, arginfo_msgfmt_format_message ) |
|
|
|
PHP_FE( msgfmt_parse, arginfo_msgfmt_parse ) |
|
|
|
PHP_FE( msgfmt_parse_message, arginfo_numfmt_parse_message ) |
|
|
|
PHP_FE( msgfmt_set_pattern, arginfo_msgfmt_set_pattern ) |
|
|
|
PHP_FE( msgfmt_get_pattern, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( msgfmt_get_locale, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( msgfmt_get_error_code, arginfo_msgfmt_get_error_code ) |
|
|
|
PHP_FE( msgfmt_get_error_message, arginfo_msgfmt_get_error_message ) |
|
|
|
|
|
|
|
/* IntlDateFormatter functions */ |
|
|
|
PHP_FE( datefmt_create, arginfo_datefmt_create ) |
|
|
|
PHP_FE( datefmt_get_datetype, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( datefmt_get_timetype, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( datefmt_get_calendar, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( datefmt_set_calendar, arginfo_datefmt_set_calendar ) |
|
|
|
PHP_FE( datefmt_get_locale, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( datefmt_get_timezone_id, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( datefmt_set_timezone_id, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( datefmt_get_pattern, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( datefmt_set_pattern, arginfo_datefmt_set_pattern ) |
|
|
|
PHP_FE( datefmt_is_lenient, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( datefmt_set_lenient, arginfo_msgfmt_get_locale ) |
|
|
|
PHP_FE( datefmt_format, arginfo_datefmt_format ) |
|
|
|
PHP_FE( datefmt_parse, datefmt_parse_args ) |
|
|
|
PHP_FE( datefmt_localtime , datefmt_parse_args ) |
|
|
|
PHP_FE( datefmt_get_error_code, NULL ) |
|
|
|
PHP_FE( datefmt_get_error_message, NULL ) |
|
|
|
PHP_FE( datefmt_get_error_code, arginfo_msgfmt_get_error_code ) |
|
|
|
PHP_FE( datefmt_get_error_message, arginfo_msgfmt_get_error_message ) |
|
|
|
|
|
|
|
// grapheme functions |
|
|
|
/* grapheme functions */ |
|
|
|
PHP_FE( grapheme_strlen, grapheme_1_arg ) |
|
|
|
PHP_FE( grapheme_strpos, grapheme_search_args ) |
|
|
|
PHP_FE( grapheme_stripos, grapheme_search_args ) |
|
|
|
@ -322,7 +465,7 @@ zend_function_entry intl_functions[] = { |
|
|
|
PHP_FE( grapheme_stristr, grapheme_strstr_args ) |
|
|
|
PHP_FE( grapheme_extract, grapheme_extract_args ) |
|
|
|
|
|
|
|
// common functions |
|
|
|
/* common functions */ |
|
|
|
PHP_FE( intl_get_error_code, intl_0_args ) |
|
|
|
PHP_FE( intl_get_error_message, intl_0_args ) |
|
|
|
PHP_FE( intl_is_failure, intl_1_arg ) |
|
|
|
@ -379,52 +522,52 @@ static PHP_GINIT_FUNCTION(intl) |
|
|
|
*/ |
|
|
|
PHP_MINIT_FUNCTION( intl ) |
|
|
|
{ |
|
|
|
//For the default locale php.ini setting |
|
|
|
/* For the default locale php.ini setting */ |
|
|
|
REGISTER_INI_ENTRIES(); |
|
|
|
|
|
|
|
REGISTER_LONG_CONSTANT("INTL_MAX_LOCALE_LEN", INTL_MAX_LOCALE_LEN, CONST_CS); |
|
|
|
|
|
|
|
// Register 'Collator' PHP class |
|
|
|
/* Register 'Collator' PHP class */ |
|
|
|
collator_register_Collator_class( TSRMLS_C ); |
|
|
|
|
|
|
|
// Expose Collator constants to PHP scripts |
|
|
|
/* Expose Collator constants to PHP scripts */ |
|
|
|
collator_register_constants( INIT_FUNC_ARGS_PASSTHRU ); |
|
|
|
|
|
|
|
// Register 'NumberFormatter' PHP class |
|
|
|
/* Register 'NumberFormatter' PHP class */ |
|
|
|
formatter_register_class( TSRMLS_C ); |
|
|
|
|
|
|
|
// Expose NumberFormatter constants to PHP scripts |
|
|
|
/* Expose NumberFormatter constants to PHP scripts */ |
|
|
|
formatter_register_constants( INIT_FUNC_ARGS_PASSTHRU ); |
|
|
|
|
|
|
|
// Register 'Normalizer' PHP class |
|
|
|
/* Register 'Normalizer' PHP class */ |
|
|
|
normalizer_register_Normalizer_class( TSRMLS_C ); |
|
|
|
|
|
|
|
// Expose Normalizer constants to PHP scripts |
|
|
|
/* Expose Normalizer constants to PHP scripts */ |
|
|
|
normalizer_register_constants( INIT_FUNC_ARGS_PASSTHRU ); |
|
|
|
|
|
|
|
// Register 'Locale' PHP class |
|
|
|
/* Register 'Locale' PHP class */ |
|
|
|
locale_register_Locale_class( TSRMLS_C ); |
|
|
|
|
|
|
|
// Expose Locale constants to PHP scripts |
|
|
|
/* Expose Locale constants to PHP scripts */ |
|
|
|
locale_register_constants( INIT_FUNC_ARGS_PASSTHRU ); |
|
|
|
|
|
|
|
msgformat_register_class(TSRMLS_C); |
|
|
|
|
|
|
|
grapheme_register_constants( INIT_FUNC_ARGS_PASSTHRU ); |
|
|
|
|
|
|
|
// Register 'DateFormat' PHP class |
|
|
|
/* Register 'DateFormat' PHP class */ |
|
|
|
dateformat_register_IntlDateFormatter_class( TSRMLS_C ); |
|
|
|
|
|
|
|
// Expose DateFormat constants to PHP scripts |
|
|
|
/* Expose DateFormat constants to PHP scripts */ |
|
|
|
dateformat_register_constants( INIT_FUNC_ARGS_PASSTHRU ); |
|
|
|
|
|
|
|
// Expose ICU error codes to PHP scripts. |
|
|
|
/* Expose ICU error codes to PHP scripts. */ |
|
|
|
intl_expose_icu_error_codes( INIT_FUNC_ARGS_PASSTHRU ); |
|
|
|
|
|
|
|
// Global error handling. |
|
|
|
/* Global error handling. */ |
|
|
|
intl_error_init( NULL TSRMLS_CC ); |
|
|
|
|
|
|
|
//Set the default_locale value |
|
|
|
/* Set the default_locale value */ |
|
|
|
if( INTL_G(default_locale) == NULL ) { |
|
|
|
INTL_G(default_locale) = pestrdup(uloc_getDefault(), 1) ; |
|
|
|
} |
|
|
|
@ -437,7 +580,7 @@ PHP_MINIT_FUNCTION( intl ) |
|
|
|
*/ |
|
|
|
PHP_MSHUTDOWN_FUNCTION( intl ) |
|
|
|
{ |
|
|
|
//For the default locale php.ini setting |
|
|
|
/* For the default locale php.ini setting */ |
|
|
|
UNREGISTER_INI_ENTRIES(); |
|
|
|
|
|
|
|
return SUCCESS; |
|
|
|
@ -448,7 +591,7 @@ PHP_MSHUTDOWN_FUNCTION( intl ) |
|
|
|
*/ |
|
|
|
PHP_RINIT_FUNCTION( intl ) |
|
|
|
{ |
|
|
|
//Set the default_locale value |
|
|
|
/* Set the default_locale value */ |
|
|
|
if( INTL_G(default_locale) == NULL ) { |
|
|
|
INTL_G(default_locale) = pestrdup(uloc_getDefault(), 1) ; |
|
|
|
} |
|
|
|
@ -483,7 +626,7 @@ PHP_MINFO_FUNCTION( intl ) |
|
|
|
php_info_print_table_row( 2, "ICU version", U_ICU_VERSION ); |
|
|
|
php_info_print_table_end(); |
|
|
|
|
|
|
|
//For the default locale php.ini setting |
|
|
|
/* For the default locale php.ini setting */ |
|
|
|
DISPLAY_INI_ENTRIES() ; |
|
|
|
} |
|
|
|
/* }}} */ |
|
|
|
|