Lesson numeric page helper.
More...
|
static | lesson_format_numeric_value ($value) |
| Helper function to format a given value into locale specific values with n:n signifying ranges. More...
|
|
static | lesson_unformat_numeric_value (string $value) |
| Helper function to unformat a given numeric value from locale specific values with n:n signifying ranges to standards with decimal point numbers/ranges. More...
|
|
Lesson numeric page helper.
- Copyright
- 2020 Peter Diaspeter.nosp@m.@moo.nosp@m.dle.c.nosp@m.om
◆ lesson_format_numeric_value()
static mod_lesson\local\numeric\helper::lesson_format_numeric_value |
( |
|
$value | ) |
|
|
static |
Helper function to format a given value into locale specific values with n:n signifying ranges.
- Parameters
-
string | number | $value | The value to be formatted |
- Return values
-
string::$formattedvalue | Formatted value OR $value if not numeric |
◆ lesson_unformat_numeric_value()
static mod_lesson\local\numeric\helper::lesson_unformat_numeric_value |
( |
string |
$value | ) |
|
|
static |
Helper function to unformat a given numeric value from locale specific values with n:n signifying ranges to standards with decimal point numbers/ranges.
- Parameters
-
string | $value | The value to be formatted |
- Return values
-
string|float|bool::$formattedvalue | unformatted value String - If it is a range it will return a value e.g. 2:4 Float - if it's a properly formatted float Null - If empty and could not be converted |
The documentation for this class was generated from the following file: