Commit 3cc34bc3 authored by bojanz's avatar bojanz

Introduce a more specific Currency interface.

parent edfd0289
......@@ -23,7 +23,7 @@ interface CurrencyImporterInterface {
* @param string $fallback
* The fallback language code.
*
* @return \CommerceGuys\Intl\Currency\CurrencyInterface[]
* @return \Drupal\commerce_price\CurrencyInterface[]
* Array of importable currencies.
*/
public function getImportableCurrencies($fallback = self::FALLBACK_LANGUAGE);
......
<?php
/**
* @file
* Contains \Drupal\commerce_price\CurrencyInterface.
*/
namespace Drupal\commerce_price;
use CommerceGuys\Intl\Currency\CurrencyInterface as ExternalCurrencyInterface;
use Drupal\Core\Config\Entity\ConfigEntityInterface;
/**
* Defines the interface for currencies.
*/
interface CurrencyInterface extends ExternalCurrencyInterface, ConfigEntityInterface {
}
......@@ -7,7 +7,7 @@
namespace Drupal\commerce_price\Entity;
use CommerceGuys\Intl\Currency\CurrencyInterface;
use Drupal\commerce_price\CurrencyInterface;
use Drupal\Core\Config\Entity\ConfigEntityBase;
/**
......
......@@ -7,7 +7,6 @@
namespace Drupal\commerce_price\Form;
use CommerceGuys\Intl\Currency\CurrencyInterface;
use Drupal\Core\Form\FormBase;
use Drupal\Core\Form\FormStateInterface;
......@@ -72,7 +71,7 @@ class CurrencyImporterForm extends FormBase {
/**
* Gets an options list for currencies.
*
* @param CurrencyInterface[] $currencies
* @param \Drupal\commerce_price\CurrencyInterface[] $currencies
* An array of currencies.
*
* @return array
......
......@@ -8,14 +8,14 @@
namespace Drupal\commerce_store\Entity;
use CommerceGuys\Addressing\Enum\AddressField;
use CommerceGuys\Intl\Currency\CurrencyInterface;
use Drupal\address\AddressInterface;
use Drupal\commerce_price\CurrencyInterface;
use Drupal\commerce_store\StoreInterface;
use Drupal\user\UserInterface;
use Drupal\Core\Entity\EntityStorageInterface;
use Drupal\Core\Field\BaseFieldDefinition;
use Drupal\Core\Entity\ContentEntityBase;
use Drupal\commerce_store\StoreInterface;
use Drupal\Core\Entity\EntityTypeInterface;
use Drupal\user\UserInterface;
/**
* Defines the Commerce Store entity type.
......
......@@ -7,7 +7,7 @@
namespace Drupal\commerce_store;
use CommerceGuys\Intl\Currency\CurrencyInterface;
use Drupal\commerce_price\CurrencyInterface;
use Drupal\address\AddressInterface;
use Drupal\Core\Entity\EntityInterface;
use Drupal\user\EntityOwnerInterface;
......@@ -58,7 +58,7 @@ interface StoreInterface extends EntityInterface, EntityOwnerInterface {
/**
* Gets the default store currency.
*
* @return \CommerceGuys\Intl\Currency\CurrencyInterface
* @return \Drupal\commerce_price\CurrencyInterface
* The default store currency.
*/
public function getDefaultCurrency();
......@@ -66,7 +66,7 @@ interface StoreInterface extends EntityInterface, EntityOwnerInterface {
/**
* Sets the default store currency.
*
* @param \CommerceGuys\Intl\Currency\CurrencyInterface $currency
* @param \Drupal\commerce_price\CurrencyInterface $currency
* The default store currency.
*
* @return \Drupal\commerce_store\StoreInterface
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment