You are here

public function CurrencyImporter::__construct in Price 8

Same name and namespace in other branches
  1. 3.x src/CurrencyImporter.php \Drupal\price\CurrencyImporter::__construct()
  2. 2.0.x src/CurrencyImporter.php \Drupal\price\CurrencyImporter::__construct()
  3. 2.x src/CurrencyImporter.php \Drupal\price\CurrencyImporter::__construct()
  4. 3.0.x src/CurrencyImporter.php \Drupal\price\CurrencyImporter::__construct()

Creates a new CurrencyImporter object.

Parameters

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

\Drupal\Core\Language\LanguageManagerInterface $language_manager: The language manager.

File

src/CurrencyImporter.php, line 47

Class

CurrencyImporter
Default implementation of the currency importer.

Namespace

Drupal\price

Code

public function __construct(EntityTypeManagerInterface $entity_type_manager, LanguageManagerInterface $language_manager) {
  $this->storage = $entity_type_manager
    ->getStorage('price_currency');
  $this->languageManager = $language_manager;
  $this->externalRepository = new CurrencyRepository();
}