Class AddressValidatorService
- Namespace
- Dynamicweb.Ecommerce.Orders.AddressValidation
- Assembly
- Dynamicweb.Ecommerce.dll
public class AddressValidatorService : ICacheStorage<int, AddressValidator>, ICacheStorage<int>, ICacheStorage
- Inheritance
-
AddressValidatorService
- Implements
- Inherited Members
Methods
ClearCache()
Clears the cache.
public void ClearCache()
ClearCache(IEnumerable<int>)
Resets the specified keys to the default value for objects stored in the object cache
public void ClearCache(IEnumerable<int> keys)
Parameters
keys
IEnumerable<int>Keys to reset
ClearCache(int)
Resets the specified key to the default value for objects stored in the object cache
public void ClearCache(int key)
Parameters
key
intKey to reset
Delete(int)
Deletes this instance.
public void Delete(int addressValidatorId)
Parameters
addressValidatorId
intThe address validator id.
GetActiveAddressValidators(Order, string)
Gets active AddressValidators for an order.
public IEnumerable<AddressValidator> GetActiveAddressValidators(Order order, string defaultCountryCode)
Parameters
Returns
GetAddressValidatorById(int)
Gets the Address validator by id.
public AddressValidator GetAddressValidatorById(int addressValidatorId)
Parameters
addressValidatorId
intThe address validator id.
Returns
GetAddressValidators()
Gets address validators.
public IEnumerable<AddressValidator> GetAddressValidators()
Returns
GetAddressValidatorsByCountryCode(string)
Gets address validators with the suitable country code.
public IEnumerable<AddressValidator> GetAddressValidatorsByCountryCode(string countryCode)
Parameters
countryCode
stringThe country code.
Returns
Save(AddressValidator)
Saves this settings instance.
public void Save(AddressValidator addressValidator)
Parameters
addressValidator
AddressValidatorThe address validator.
Validate(Order, string)
Validate the addresses.
public bool Validate(Order order, string defaultCountryCode)
Parameters
Returns
Validate(UserAddress, string)
Validate the addresses.
public bool Validate(UserAddress address, string languageId)
Parameters
address
UserAddressThe order.
languageId
stringThe language ID.