Class FeeService
- Namespace
- Dynamicweb.Ecommerce.Orders
- Assembly
- Dynamicweb.Ecommerce.dll
public class FeeService : ICacheStorage<string, Fee>, ICacheStorage<string>, ICacheStorage
- Inheritance
-
FeeService
- Implements
- Inherited Members
Fields
MethodTypeAddressValidator
public const string MethodTypeAddressValidator = "ADDRESSVALIDATOR"
Field Value
MethodTypePayment
public const string MethodTypePayment = "PAY"
Field Value
MethodTypeShipment
public const string MethodTypeShipment = "SHIP"
Field Value
Methods
ClearCache()
Resets all keys to the default value for objects stored in the object cache
public void ClearCache()
Delete(Fee)
Deletes a given fee.
public void Delete(Fee fee)
Parameters
fee
FeeFee to delete.
DeleteByMethod(string, string)
Deletes all fees associated with a given method.
public void DeleteByMethod(string method, string methodId)
Parameters
method
stringMethod type, e.g "PAY" or "SHIP".
methodId
stringMethod identifier, e.g. "PAY1" or "SHIP1".
GetAllFees()
Get all fees
public IEnumerable<Fee> GetAllFees()
Returns
- IEnumerable<Fee>
All existing fees regardless of method.
GetFeeById(string)
Gets a fee by id.
public Fee GetFeeById(string id)
Parameters
id
stringId of the fee.
Returns
GetFeesByMethod(string, string)
Gets all fees for a given method.
public IEnumerable<Fee> GetFeesByMethod(string method, string methodId)
Parameters
method
stringMethod type, e.g "PAY" or "SHIP".
methodId
stringMethod identifier, e.g. "PAY1" or "SHIP1".
Returns
- IEnumerable<Fee>
All fees associated with the specified method.
GetFeesByMethodAndCountryRegion(string, string, string, string)
Gets all fees for a given method, country and region.
public IEnumerable<Fee> GetFeesByMethodAndCountryRegion(string method, string methodId, string countryCode, string regionCode)
Parameters
method
stringMethod type, e.g "PAY" or "SHIP".
methodId
stringMethod identifier, e.g. "PAY1" or "SHIP1".
countryCode
stringCountry code, e.g. "US".
regionCode
stringRegion code, e.g. "CA".
Returns
- IEnumerable<Fee>
ll fees associated with the specified method, country and region.
Save(Fee)
Saves a given fee.
public void Save(Fee fee)
Parameters
fee
FeeFee to save.