Table of Contents

Class PriceCalculated

Namespace
Dynamicweb.Ecommerce.Prices
Assembly
Dynamicweb.Ecommerce.dll

Represents information about calculated price.

[Serializable]
public class PriceCalculated : PriceInfo, IPriceReferenceInfo, IInformativePriceInfo, IPriceInfo, IPriceSourceInfo
Inheritance
PriceCalculated
Implements
Inherited Members

Properties

IgnoreVat

Gets or sets a value indicating whether to bypass VAT calculations.

public bool IgnoreVat { get; set; }

Property Value

bool

true if VAT calculations should be bypassed; otherwise, false.

RemoveVat

Gets or sets a value indicating whether to remove VAT from the current price.

public bool RemoveVat { get; set; }

Property Value

bool

true if price calculation should remove VAT from the current price; otherwise, false.

Remarks

The VAT is only removed if prices in the database include VAT. Otherwise, price calculation does not change with the value of this property.

VATPercent

Gets or sets the VAT percent.

public override double VATPercent { get; set; }

Property Value

double

Methods

Calculate()

public void Calculate()

Create(Currency, Country, PriceRaw)

Creates a new instance of the PriceCalculated class.

public static PriceCalculated Create(Currency currency, Country country, PriceRaw priceRaw)

Parameters

currency Currency
country Country
priceRaw PriceRaw

Returns

PriceCalculated

Create(PriceContext, PriceRaw)

Creates a new instance of the PriceCalculated class.

public static PriceCalculated Create(PriceContext context, PriceRaw priceRaw)

Parameters

context PriceContext
priceRaw PriceRaw

Returns

PriceCalculated

Create(PriceContext, PriceRaw, Product)

Creates a new instance of the PriceCalculated class.

public static PriceCalculated Create(PriceContext context, PriceRaw priceRaw, Product product)

Parameters

context PriceContext
priceRaw PriceRaw
product Product

Returns

PriceCalculated

FindVatPercent(Country)

Finds the VAT percent for the given Country.

public static double FindVatPercent(Country country)

Parameters

country Country

The country used to determine VAT percent.

Returns

double

FindVatPercent(Country, Product, bool)

Finds the VAT percent for the given Country and Product.

public static double FindVatPercent(Country country, Product product, bool reverseChargeForVatEnabled)

Parameters

country Country

The country used to determine VAT percent.

product Product

The product to get the VAT percent for.

reverseChargeForVatEnabled bool

Returns

double

ToString()

Returns a string that represents this instance.

public override string ToString()

Returns

string

A string that represents this instance.

To top