php-internal-docs 8.4.8
Unofficial docs for php/php-src
Loading...
Searching...
No Matches
formatter.stub.php
Go to the documentation of this file.
1<?php
2
4
7{
8 /* UNumberFormatStyle constants */
9
11 public const int PATTERN_DECIMAL = UNKNOWN;
13 public const int DECIMAL = UNKNOWN;
15 public const int CURRENCY = UNKNOWN;
17 public const int PERCENT = UNKNOWN;
19 public const int SCIENTIFIC = UNKNOWN;
21 public const int SPELLOUT = UNKNOWN;
23 public const int ORDINAL = UNKNOWN;
25 public const int DURATION = UNKNOWN;
27 public const int PATTERN_RULEBASED = UNKNOWN;
29 public const int IGNORE = UNKNOWN;
30#if U_ICU_VERSION_MAJOR_NUM >= 53
32 public const int CURRENCY_ACCOUNTING = UNKNOWN;
33#endif
35 public const int DEFAULT_STYLE = UNKNOWN;
36
37 /* UNumberFormatRoundingMode */
38
40 public const int ROUND_CEILING = UNKNOWN;
42 public const int ROUND_FLOOR = UNKNOWN;
44 public const int ROUND_DOWN = UNKNOWN;
46 public const int ROUND_UP = UNKNOWN;
48 public const int ROUND_TOWARD_ZERO = UNKNOWN;
50 public const int ROUND_AWAY_FROM_ZERO = UNKNOWN;
52 public const int ROUND_HALFEVEN = UNKNOWN;
53#if U_ICU_VERSION_MAJOR_NUM >= 69
55 public const int ROUND_HALFODD = UNKNOWN;
56#endif
58 public const int ROUND_HALFDOWN = UNKNOWN;
60 public const int ROUND_HALFUP = UNKNOWN;
61
62 /* UNumberFormatPadPosition */
63
65 public const int PAD_BEFORE_PREFIX = UNKNOWN;
67 public const int PAD_AFTER_PREFIX = UNKNOWN;
69 public const int PAD_BEFORE_SUFFIX = UNKNOWN;
71 public const int PAD_AFTER_SUFFIX = UNKNOWN;
72
73 /* UNumberFormatAttribute */
74
76 public const int PARSE_INT_ONLY = UNKNOWN;
78 public const int GROUPING_USED = UNKNOWN;
80 public const int DECIMAL_ALWAYS_SHOWN = UNKNOWN;
82 public const int MAX_INTEGER_DIGITS = UNKNOWN;
84 public const int MIN_INTEGER_DIGITS = UNKNOWN;
86 public const int INTEGER_DIGITS = UNKNOWN;
88 public const int MAX_FRACTION_DIGITS = UNKNOWN;
90 public const int MIN_FRACTION_DIGITS = UNKNOWN;
92 public const int FRACTION_DIGITS = UNKNOWN;
94 public const int MULTIPLIER = UNKNOWN;
96 public const int GROUPING_SIZE = UNKNOWN;
98 public const int ROUNDING_MODE = UNKNOWN;
100 public const int ROUNDING_INCREMENT = UNKNOWN;
102 public const int FORMAT_WIDTH = UNKNOWN;
104 public const int PADDING_POSITION = UNKNOWN;
106 public const int SECONDARY_GROUPING_SIZE = UNKNOWN;
108 public const int SIGNIFICANT_DIGITS_USED = UNKNOWN;
110 public const int MIN_SIGNIFICANT_DIGITS = UNKNOWN;
112 public const int MAX_SIGNIFICANT_DIGITS = UNKNOWN;
114 public const int LENIENT_PARSE = UNKNOWN;
115
116 /* UNumberFormatTextAttribute */
117
119 public const int POSITIVE_PREFIX = UNKNOWN;
121 public const int POSITIVE_SUFFIX = UNKNOWN;
123 public const int NEGATIVE_PREFIX = UNKNOWN;
125 public const int NEGATIVE_SUFFIX = UNKNOWN;
127 public const int PADDING_CHARACTER = UNKNOWN;
129 public const int CURRENCY_CODE = UNKNOWN;
131 public const int DEFAULT_RULESET = UNKNOWN;
133 public const int PUBLIC_RULESETS = UNKNOWN;
134
135 /* UNumberFormatSymbol */
136
138 public const int DECIMAL_SEPARATOR_SYMBOL = UNKNOWN;
140 public const int GROUPING_SEPARATOR_SYMBOL = UNKNOWN;
142 public const int PATTERN_SEPARATOR_SYMBOL = UNKNOWN;
144 public const int PERCENT_SYMBOL = UNKNOWN;
146 public const int ZERO_DIGIT_SYMBOL = UNKNOWN;
148 public const int DIGIT_SYMBOL = UNKNOWN;
150 public const int MINUS_SIGN_SYMBOL = UNKNOWN;
152 public const int PLUS_SIGN_SYMBOL = UNKNOWN;
154 public const int CURRENCY_SYMBOL = UNKNOWN;
156 public const int INTL_CURRENCY_SYMBOL = UNKNOWN;
158 public const int MONETARY_SEPARATOR_SYMBOL = UNKNOWN;
160 public const int EXPONENTIAL_SYMBOL = UNKNOWN;
162 public const int PERMILL_SYMBOL = UNKNOWN;
164 public const int PAD_ESCAPE_SYMBOL = UNKNOWN;
166 public const int INFINITY_SYMBOL = UNKNOWN;
168 public const int NAN_SYMBOL = UNKNOWN;
170 public const int SIGNIFICANT_DIGIT_SYMBOL = UNKNOWN;
172 public const int MONETARY_GROUPING_SEPARATOR_SYMBOL = UNKNOWN;
173
175 public const int TYPE_DEFAULT = UNKNOWN;
177 public const int TYPE_INT32 = UNKNOWN;
179 public const int TYPE_INT64 = UNKNOWN;
181 public const int TYPE_DOUBLE = UNKNOWN;
185 #[\Deprecated(since: '8.3')]
186 public const int TYPE_CURRENCY = UNKNOWN;
187
188 public function __construct(string $locale, int $style, ?string $pattern = null) {}
189
194 public static function create(string $locale, int $style, ?string $pattern = null): ?NumberFormatter {}
195
200 public function format(int|float $num, int $type = NumberFormatter::TYPE_DEFAULT): string|false {}
201
207 public function parse(string $string, int $type = NumberFormatter::TYPE_DOUBLE, &$offset = null): int|float|false {}
208
213 public function formatCurrency(float $amount, string $currency): string|false {}
214
221 public function parseCurrency(string $string, &$currency, &$offset = null): float|false {}
222
227 public function setAttribute(int $attribute, int|float $value): bool {}
228
233 public function getAttribute(int $attribute): int|float|false {}
234
239 public function setTextAttribute(int $attribute, string $value): bool {}
240
245 public function getTextAttribute(int $attribute): string|false {}
246
251 public function setSymbol(int $symbol, string $value): bool {}
252
257 public function getSymbol(int $symbol): string|false {}
258
263 public function setPattern(string $pattern): bool {}
264
269 public function getPattern(): string|false {}
270
275 public function getLocale(int $type = ULOC_ACTUAL_LOCALE): string|false {}
276
281 public function getErrorCode(): int {}
282
287 public function getErrorMessage(): string {}
288}
const int ROUND_HALFDOWN
setPattern(string $pattern)
const int ROUND_HALFODD
parse(string $string, int $type=NumberFormatter::TYPE_DOUBLE, &$offset=null)
const int DECIMAL_SEPARATOR_SYMBOL
const int PADDING_CHARACTER
const int PAD_ESCAPE_SYMBOL
const int SECONDARY_GROUPING_SIZE
const int CURRENCY_ACCOUNTING
const int PATTERN_RULEBASED
const int ZERO_DIGIT_SYMBOL
const int PAD_BEFORE_SUFFIX
const int INTL_CURRENCY_SYMBOL
const int SIGNIFICANT_DIGIT_SYMBOL
const int SIGNIFICANT_DIGITS_USED
const int PAD_AFTER_SUFFIX
static create(string $locale, int $style, ?string $pattern=null)
format(int|float $num, int $type=NumberFormatter::TYPE_DEFAULT)
setTextAttribute(int $attribute, string $value)
const int MONETARY_GROUPING_SEPARATOR_SYMBOL
const int POSITIVE_PREFIX
getAttribute(int $attribute)
const int ROUND_AWAY_FROM_ZERO
const int PATTERN_DECIMAL
__construct(string $locale, int $style, ?string $pattern=null)
const int MAX_INTEGER_DIGITS
const int MAX_SIGNIFICANT_DIGITS
const int ROUND_CEILING
const int NEGATIVE_PREFIX
const int PARSE_INT_ONLY
const int EXPONENTIAL_SYMBOL
setSymbol(int $symbol, string $value)
const int NEGATIVE_SUFFIX
setAttribute(int $attribute, int|float $value)
const int MIN_FRACTION_DIGITS
const int ROUND_TOWARD_ZERO
const int GROUPING_SEPARATOR_SYMBOL
const int DECIMAL_ALWAYS_SHOWN
const int ROUND_FLOOR
const int DEFAULT_STYLE
const int MIN_INTEGER_DIGITS
getSymbol(int $symbol)
const int DEFAULT_RULESET
const int MAX_FRACTION_DIGITS
getLocale(int $type=ULOC_ACTUAL_LOCALE)
const int PLUS_SIGN_SYMBOL
const int ROUND_HALFEVEN
const int PUBLIC_RULESETS
const int CURRENCY_SYMBOL
const int GROUPING_USED
const int ROUNDING_INCREMENT
getTextAttribute(int $attribute)
const int INFINITY_SYMBOL
const int PAD_AFTER_PREFIX
const int LENIENT_PARSE
const int PATTERN_SEPARATOR_SYMBOL
const int GROUPING_SIZE
formatCurrency(float $amount, string $currency)
const int TYPE_CURRENCY
const int POSITIVE_SUFFIX
const int FRACTION_DIGITS
const int MINUS_SIGN_SYMBOL
const int MIN_SIGNIFICANT_DIGITS
const int PADDING_POSITION
const int ROUNDING_MODE
const int INTEGER_DIGITS
const int PERMILL_SYMBOL
const int PAD_BEFORE_PREFIX
parseCurrency(string $string, &$currency, &$offset=null)
const int PERCENT_SYMBOL
const int CURRENCY_CODE
const int ROUND_HALFUP
const int MONETARY_SEPARATOR_SYMBOL
const ULOC_ACTUAL_LOCALE
function(EX_VAR(opline->result.var))