PHP Interface Sonata\Component\Currency\CurrencyPriceCalculatorInterface

Author: Hugo Briand ([email protected])
Show file Open project: sonata-project/ecommerce Interface Usage Examples

Public Methods

Method Description
getPrice ( Sonata\Component\Product\ProductInterface $product, Sonata\Component\Currency\CurrencyInterface $currency, boolean $vat = false ) : float Returns the price of $product for given $currency.

Method Details

getPrice() public method

Returns the price of $product for given $currency.
public getPrice ( Sonata\Component\Product\ProductInterface $product, Sonata\Component\Currency\CurrencyInterface $currency, boolean $vat = false ) : float
$product Sonata\Component\Product\ProductInterface A product instance
$currency Sonata\Component\Currency\CurrencyInterface A currency instance
$vat boolean Return price including VAT?
return float