Open Monograph Press  3.3.0
Money\Parser\IntlLocalizedDecimalParser Class Reference
Inheritance diagram for Money\Parser\IntlLocalizedDecimalParser:
Money\MoneyParser

Public Member Functions

 __construct (\NumberFormatter $formatter, Currencies $currencies)
 
 parse ($money, $forceCurrency=null)
 

Detailed Description

Parses a string into a Money object using intl extension.

Author
Frederik Bosch f.bos.nosp@m.ch@g.nosp@m.enkgo.nosp@m..nl

Definition at line 17 of file IntlLocalizedDecimalParser.php.

Constructor & Destructor Documentation

◆ __construct()

Money\Parser\IntlLocalizedDecimalParser::__construct ( \NumberFormatter  $formatter,
Currencies  $currencies 
)
Parameters
\NumberFormatter$formatter
Currencies$currencies

Definition at line 39 of file IntlLocalizedDecimalParser.php.

Member Function Documentation

◆ parse()

Money\Parser\IntlLocalizedDecimalParser::parse (   $money,
  $forceCurrency = null 
)

{Parses a string into a Money object (including currency).

Parameters
string$money
Currency | string | null$forceCurrency
Returns
Money
Exceptions
Exception
}

Implements Money\MoneyParser.

Definition at line 48 of file IntlLocalizedDecimalParser.php.

References Money\Number\roundMoneyValue().


The documentation for this class was generated from the following file: