You are here

public function Avatax::__construct in Drupal Commerce Connector for AvaTax 8

Constructs a new AvaTax object.

Parameters

array $configuration: A configuration array containing information about the plugin instance.

string $plugin_id: The plugin_id for the plugin instance.

mixed $plugin_definition: The plugin implementation definition.

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager.

\Symfony\Component\EventDispatcher\EventDispatcherInterface $event_dispatcher: The event dispatcher.

\Drupal\commerce_avatax\AvataxLibInterface $avatax_lib: The AvaTax library.

\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The config factory.

Overrides TaxTypeBase::__construct

File

src/Plugin/Commerce/TaxType/Avatax.php, line 58

Class

Avatax
Provides the AvaTax remote tax type.

Namespace

Drupal\commerce_avatax\Plugin\Commerce\TaxType

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityTypeManagerInterface $entity_type_manager, EventDispatcherInterface $event_dispatcher, AvataxLibInterface $avatax_lib, ConfigFactoryInterface $config_factory) {
  parent::__construct($configuration, $plugin_id, $plugin_definition, $entity_type_manager, $event_dispatcher);
  $this->avataxLib = $avatax_lib;
  $this->configFactory = $config_factory;
}