Pricing/Model/Price.php
public function getTotal($discounted = true)
    {
        $base = $this->base;

        if ($discounted && $this->hasDiscounts()) {
            foreach ($this->discounts as $discount) {
                $base -= $this->calculateAdjustment($discount, $base);
            }
        }

        $total = $base;

        if (!empty($this->taxes) && $this->mode === VatDisplayModes::MODE_ATI) {
            foreach ($this->taxes as $tax) {
                $total += $this->calculateAdjustment($tax, $base);
            }
        }

        return $total;
    }
public function getTotal($discounted = true)
    {
        $base = $this->base;

        if ($discounted && $this->hasDiscounts()) {
            foreach ($this->discounts as $discount) {
                $base -= $this->calculateAdjustment($discount, $base);
            }
        }

        $total = $base;

        if (!empty($this->taxes) && $this->mode === VatDisplayModes::MODE_ATI) {
            foreach ($this->taxes as $tax) {
                $total += $this->calculateAdjustment($tax, $base);
            }
        }

        return $total;
    }
Returns the total.

@param bool $discounted Whether to return the discounted price.

@return float