PHP Trait CommerceGuys\Tax\Resolver\TaxType\StoreRegistrationCheckerTrait

Afficher le fichier Open project: commerceguys/tax

Protected Properties

Свойство Type Description
$emptyAddresses CommerceGuys\Addressing\Address[] The empty addresses constructed for checking store registrations.

Méthodes protégées

Méthode Description
checkStoreRegistration ( CommerceGuys\Zone\Model\ZoneInterface $zone, Context $context ) : boolean Checks whether the store is registered to collect taxes in the given zone.
filterByStoreRegistration ( array $taxTypes, Context $context ) : CommerceGuys\Tax\Model\TaxTypeInterface[] Filters out tax types not matching the store registration.

Method Details

checkStoreRegistration() protected méthode

Checks whether the store is registered to collect taxes in the given zone.
protected checkStoreRegistration ( CommerceGuys\Zone\Model\ZoneInterface $zone, Context $context ) : boolean
$zone CommerceGuys\Zone\Model\ZoneInterface The zone.
$context CommerceGuys\Tax\Resolver\Context The context containing store information.
Résultat boolean True if the store is registered to collect taxes in the given zone, false otherwise.

filterByStoreRegistration() protected méthode

Filters out tax types not matching the store registration.
protected filterByStoreRegistration ( array $taxTypes, Context $context ) : CommerceGuys\Tax\Model\TaxTypeInterface[]
$taxTypes array The tax types to filter.
$context CommerceGuys\Tax\Resolver\Context The context containing store information.
Résultat CommerceGuys\Tax\Model\TaxTypeInterface[] An array of additional tax types the store is registered to collect.

Property Details

$emptyAddresses protected_oe property

The empty addresses constructed for checking store registrations.
protected Address[],CommerceGuys\Addressing $emptyAddresses
Résultat CommerceGuys\Addressing\Address[]