[ Index ]

WordPress 5.4.1

[ Index ]     [ Classes ]     [ Functions ]     [ Variables ]     [ Constants ]     [ Statistics ]    




/wp-includes/pomo/ -> plural-forms.php (summary)

(no description)

File Size: 344 lines (7 kb)
Included or required: 1 time
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

Plural_Forms:: (4 methods):

Class: Plural_Forms  - X-Ref

A gettext Plural-Forms parser.

__construct( $str )   X-Ref

param: string $str Plural function (just the bit after `plural=` from Plural-Forms)

parse( $str )   X-Ref
Parse a Plural-Forms string into tokens.

Uses the shunting-yard algorithm to convert the string to Reverse Polish
Notation tokens.

param: string $str String to parse.

get( $num )   X-Ref
Get the plural form for a number.

Caches the value for repeated calls.

param: int $num Number to get plural form for.
return: int Plural form value.

execute( $n )   X-Ref
Execute the plural form function.

param: int $n Variable "n" to substitute.
return: int Plural form value.

Generated: Tue May 19 15:51:04 2020 Cross-referenced by PHPXref 0.7.1