Commit 932e4d9e authored by alexpott's avatar alexpott

Issue #2184231 by jibran, dawehner, Xano: Use ConfigFactoryInterface to type hint ConfigFactory.

parent 7009167f
......@@ -266,7 +266,7 @@ public static function config($name) {
* factory. For example, changing the language, or turning all overrides on
* or off.
*
* @return \Drupal\Core\Config\ConfigFactory
* @return \Drupal\Core\Config\ConfigFactoryInterface
*/
public static function configFactory() {
return static::$container->get('config.factory');
......
......@@ -26,8 +26,7 @@ interface ConfigFactoryInterface {
* @param bool $state
* TRUE if overrides should be applied, FALSE otherwise.
*
* @return \Drupal\Core\Config\ConfigFactory
* The config factory object.
* @return $this
*/
public function setOverrideState($state);
......@@ -71,8 +70,7 @@ public function loadMultiple(array $names);
* (optional) The name of the configuration object to reset. If omitted, all
* configuration objects are reset.
*
* @return \Drupal\Core\Config\ConfigFactory
* The config factory object.
* @return $this
*/
public function reset($name = NULL);
......@@ -114,8 +112,7 @@ public function getCacheKeys($name);
/**
* Clears the config factory static cache.
*
* @return \Drupal\Core\Config\ConfigFactory
* The config factory object.
* @return $this
*/
public function clearStaticCache();
......@@ -126,8 +123,7 @@ public function clearStaticCache();
* The language object to be set on the config factory. Used to override
* configuration by language.
*
* @return \Drupal\Core\Config\ConfigFactory
* The config factory object.
* @return $this
*/
public function setLanguage(Language $language = NULL);
......@@ -139,8 +135,7 @@ public function setLanguage(Language $language = NULL);
* config factory to the site's default. The language can be used to
* override configuration data if language overrides are available.
*
* @return \Drupal\Core\Config\ConfigFactory
* The config factory object.
* @return $this
*/
public function setLanguageFromDefault(LanguageDefault $language_default);
......
......@@ -15,7 +15,7 @@ class ConfigInstaller implements ConfigInstallerInterface {
/**
* The configuration factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -50,7 +50,7 @@ class ConfigInstaller implements ConfigInstallerInterface {
/**
* Constructs the configuration installer.
*
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The configuration factory.
* @param \Drupal\Core\Config\StorageInterface $active_storage
* The active configuration storage.
......@@ -61,7 +61,7 @@ class ConfigInstaller implements ConfigInstallerInterface {
* @param \Symfony\Component\EventDispatcher\EventDispatcherInterface $event_dispatcher
* The event dispatcher.
*/
public function __construct(ConfigFactory $config_factory, StorageInterface $active_storage, TypedConfigManagerInterface $typed_config, ConfigManagerInterface $config_manager, EventDispatcherInterface $event_dispatcher) {
public function __construct(ConfigFactoryInterface $config_factory, StorageInterface $active_storage, TypedConfigManagerInterface $typed_config, ConfigManagerInterface $config_manager, EventDispatcherInterface $event_dispatcher) {
$this->configFactory = $config_factory;
$this->activeStorage = $active_storage;
$this->typedConfig = $typed_config;
......
......@@ -8,11 +8,11 @@
namespace Drupal\Core\Config\Entity;
use Drupal\Component\Utility\String;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Entity\EntityInterface;
use Drupal\Core\Entity\EntityMalformedException;
use Drupal\Core\Entity\EntityStorageControllerBase;
use Drupal\Core\Config\Config;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\StorageInterface;
use Drupal\Core\Entity\EntityTypeInterface;
use Drupal\Core\Entity\EntityStorageException;
......@@ -61,7 +61,7 @@ class ConfigStorageController extends EntityStorageControllerBase implements Con
/**
* The config factory service.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -84,7 +84,7 @@ class ConfigStorageController extends EntityStorageControllerBase implements Con
*
* @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
* The entity type definition.
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory service.
* @param \Drupal\Core\Config\StorageInterface $config_storage
* The config storage service.
......@@ -93,7 +93,7 @@ class ConfigStorageController extends EntityStorageControllerBase implements Con
* @param \Drupal\Component\Uuid\UuidInterface $uuid_service
* The UUID service.
*/
public function __construct(EntityTypeInterface $entity_type, ConfigFactory $config_factory, StorageInterface $config_storage, QueryFactory $entity_query_factory, UuidInterface $uuid_service) {
public function __construct(EntityTypeInterface $entity_type, ConfigFactoryInterface $config_factory, StorageInterface $config_storage, QueryFactory $entity_query_factory, UuidInterface $uuid_service) {
parent::__construct($entity_type);
$this->idKey = $this->entityType->getKey('id');
......
......@@ -7,7 +7,7 @@
namespace Drupal\Core\Config\Entity\Query;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Config\StorageInterface;
use Drupal\Core\Entity\EntityManagerInterface;
use Drupal\Core\Entity\Query\QueryBase;
......@@ -35,7 +35,7 @@ class Query extends QueryBase implements QueryInterface {
/**
* The config factory used by the config entity query.
*
* @var \Drupal\Core\Config\ConfigFactory;
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -51,10 +51,12 @@ class Query extends QueryBase implements QueryInterface {
* The entity manager that stores all meta information.
* @param \Drupal\Core\Config\StorageInterface $config_storage
* The actual config storage which is used to list all config items.
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory.
* @param array $namespaces
* List of potential namespaces of the classes belonging to this query.
*/
function __construct($entity_type, $conjunction, EntityManagerInterface $entity_manager, StorageInterface $config_storage, ConfigFactory $config_factory, array $namespaces) {
function __construct($entity_type, $conjunction, EntityManagerInterface $entity_manager, StorageInterface $config_storage, ConfigFactoryInterface $config_factory, array $namespaces) {
parent::__construct($entity_type, $conjunction, $namespaces);
$this->entityManager = $entity_manager;
$this->configStorage = $config_storage;
......
......@@ -7,7 +7,7 @@
namespace Drupal\Core\Config\Entity\Query;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Config\StorageInterface;
use Drupal\Core\Entity\EntityManagerInterface;
use Drupal\Core\Entity\Query\QueryBase;
......@@ -29,7 +29,7 @@ class QueryFactory implements QueryFactoryInterface {
/**
* The config factory used by the config entity query.
*
* @var \Drupal\Core\Config\ConfigFactory;
* @var \Drupal\Core\Config\ConfigFactoryInterface;
*/
protected $configFactory;
......@@ -45,10 +45,10 @@ class QueryFactory implements QueryFactoryInterface {
*
* @param \Drupal\Core\Config\StorageInterface $config_storage
* The config storage used by the config entity query.
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config storage used by the config entity query.
*/
public function __construct(StorageInterface $config_storage, ConfigFactory $config_factory) {
public function __construct(StorageInterface $config_storage, ConfigFactoryInterface $config_factory) {
$this->configStorage = $config_storage;
$this->configFactory = $config_factory;
$this->namespaces = QueryBase::getNamespaces($this);
......
......@@ -8,7 +8,7 @@
namespace Drupal\Core\Datetime;
use Drupal\Component\Utility\Xss;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Datetime\DrupalDateTime;
use Drupal\Core\Entity\EntityManagerInterface;
use Drupal\Core\Language\Language;
......@@ -44,7 +44,7 @@ class Date {
/**
* The configuration factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -79,10 +79,10 @@ class Date {
* The language manager.
* @param \Drupal\Core\StringTranslation\TranslationInterface $translation
* The string translation.
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The configuration factory.
*/
public function __construct(EntityManagerInterface $entity_manager, LanguageManagerInterface $language_manager, TranslationInterface $translation, ConfigFactory $config_factory) {
public function __construct(EntityManagerInterface $entity_manager, LanguageManagerInterface $language_manager, TranslationInterface $translation, ConfigFactoryInterface $config_factory) {
$this->dateFormatStorage = $entity_manager->getStorageController('date_format');
$this->languageManager = $language_manager;
$this->stringTranslation = $translation;
......
......@@ -10,7 +10,7 @@
use Drupal\Component\Utility\String;
use Drupal\Core\Cache\Cache;
use Drupal\Core\Cache\CacheBackendInterface;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Config\ConfigInstallerInterface;
use Drupal\Core\Routing\RouteBuilder;
use Drupal\Core\SystemListingInfo;
......@@ -47,7 +47,7 @@ class ThemeHandler implements ThemeHandlerInterface {
/**
* The config factory to get the enabled themes.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -96,7 +96,7 @@ class ThemeHandler implements ThemeHandlerInterface {
/**
* Constructs a new ThemeHandler.
*
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory to get the enabled themes.
* @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
* The module handler to fire themes_enabled/themes_disabled hooks.
......@@ -113,7 +113,7 @@ class ThemeHandler implements ThemeHandlerInterface {
* @param \Drupal\Core\SystemListingInfo $system_list_info
* (optional) The system listing info.
*/
public function __construct(ConfigFactory $config_factory, ModuleHandlerInterface $module_handler, CacheBackendInterface $cache_backend, InfoParserInterface $info_parser, ConfigInstallerInterface $config_installer = NULL, RouteBuilder $route_builder = NULL, SystemListingInfo $system_list_info = NULL) {
public function __construct(ConfigFactoryInterface $config_factory, ModuleHandlerInterface $module_handler, CacheBackendInterface $cache_backend, InfoParserInterface $info_parser, ConfigInstallerInterface $config_installer = NULL, RouteBuilder $route_builder = NULL, SystemListingInfo $system_list_info = NULL) {
$this->configFactory = $config_factory;
$this->moduleHandler = $module_handler;
$this->cacheBackend = $cache_backend;
......
......@@ -7,7 +7,7 @@
namespace Drupal\Core\Form;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Form\FormBase;
use Symfony\Component\DependencyInjection\ContainerInterface;
......@@ -19,17 +19,17 @@ abstract class ConfigFormBase extends FormBase {
/**
* Stores the configuration factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
/**
* Constructs a \Drupal\system\ConfigFormBase object.
*
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
*/
public function __construct(ConfigFactory $config_factory) {
public function __construct(ConfigFactoryInterface $config_factory) {
$this->configFactory = $config_factory;
}
......
......@@ -7,7 +7,7 @@
namespace Drupal\Core\Form;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\DependencyInjection\ContainerInjectionInterface;
use Drupal\Core\DependencyInjection\DependencySerialization;
use Drupal\Core\Routing\UrlGeneratorInterface;
......@@ -44,7 +44,7 @@ abstract class FormBase extends DependencySerialization implements FormInterface
/**
* The config factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -143,12 +143,12 @@ public function setTranslationManager(TranslationInterface $translation_manager)
/**
* Sets the config factory for this form.
*
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory.
*
* @return $this
*/
public function setConfigFactory(ConfigFactory $config_factory) {
public function setConfigFactory(ConfigFactoryInterface $config_factory) {
$this->configFactory = $config_factory;
return $this;
}
......
......@@ -8,7 +8,7 @@
namespace Drupal\Core\ImageToolkit;
use Drupal\Core\Cache\CacheBackendInterface;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Language\LanguageManager;
use Drupal\Core\Plugin\DefaultPluginManager;
......@@ -20,7 +20,7 @@ class ImageToolkitManager extends DefaultPluginManager {
/**
* The config factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -34,10 +34,10 @@ class ImageToolkitManager extends DefaultPluginManager {
* Cache backend instance to use.
* @param \Drupal\Core\Language\LanguageManager $language_manager
* The language manager.
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory.
*/
public function __construct(\Traversable $namespaces, CacheBackendInterface $cache_backend, LanguageManager $language_manager, ConfigFactory $config_factory) {
public function __construct(\Traversable $namespaces, CacheBackendInterface $cache_backend, LanguageManager $language_manager, ConfigFactoryInterface $config_factory) {
parent::__construct('Plugin/ImageToolkit', $namespaces, 'Drupal\Core\ImageToolkit\Annotation\ImageToolkit');
$this->setCacheBackend($cache_backend, $language_manager, 'image_toolkit_plugins');
......
......@@ -7,7 +7,7 @@
namespace Drupal\Core\Mail;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Component\Utility\String;
/**
......@@ -32,10 +32,10 @@ class MailFactory {
/**
* Constructs a MailFActory object.
*
* @param \Drupal\Core\Config\ConfigFactory $configFactory
* @param \Drupal\Core\Config\ConfigFactoryInterface $configFactory
* The configuration factory.
*/
public function __construct(ConfigFactory $configFactory) {
public function __construct(ConfigFactoryInterface $configFactory) {
$this->mailConfig = $configFactory->get('system.mail');
}
......
......@@ -7,7 +7,6 @@
namespace Drupal\Core\PathProcessor;
use Drupal\Core\Config\ConfigFactory;
use Symfony\Component\HttpFoundation\Request;
/**
......
......@@ -7,7 +7,7 @@
namespace Drupal\Core\PathProcessor;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Symfony\Component\HttpFoundation\Request;
/**
......@@ -18,17 +18,17 @@ class PathProcessorFront implements InboundPathProcessorInterface, OutboundPathP
/**
* A config factory for retrieving required config settings.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $config;
/**
* Constructs a PathProcessorFront object.
*
* @param \Drupal\Core\Config\ConfigFactory $config
* @param \Drupal\Core\Config\ConfigFactoryInterface $config
* A config factory for retrieving the site front page configuration.
*/
public function __construct(ConfigFactory $config) {
public function __construct(ConfigFactoryInterface $config) {
$this->config = $config;
}
......
......@@ -17,7 +17,7 @@
use Drupal\Component\Utility\Settings;
use Drupal\Component\Utility\Url;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\PathProcessor\OutboundPathProcessorInterface;
use Drupal\Core\RouteProcessor\OutboundRouteProcessorInterface;
......@@ -43,7 +43,7 @@ class UrlGenerator extends ProviderBasedGenerator implements UrlGeneratorInterfa
/**
* The route processor.
*
* @var \Drupal\Tests\Core\RouteProcessor\OutboundRouteProcessorInterface
* @var \Drupal\Core\RouteProcessor\OutboundRouteProcessorInterface
*/
protected $routeProcessor;
......@@ -80,12 +80,18 @@ class UrlGenerator extends ProviderBasedGenerator implements UrlGeneratorInterfa
*
* @param \Drupal\Core\Routing\RouteProviderInterface $provider
* The route provider to be searched for routes.
* @param \Drupal\Core\Path\AliasManagerInterface $alias_manager
* The alias manager responsible for path aliasing.
* @param \Drupal\Core\PathProcessor\OutboundPathProcessorInterface $path_processor
* The path processor to convert the system path to one suitable for urls.
* @param \Drupal\Core\RouteProcessor\OutboundRouteProcessorInterface $route_processor
* The route processor.
* @param \Drupal\Core\Config\ConfigFactoryInterface $config
* The config factory.
* @param \Drupal\Component\Utility\Settings $settings
* The read only settings.
* @param \Symfony\Component\HttpKernel\Log\LoggerInterface $logger
* An optional logger for recording errors.
*/
public function __construct(RouteProviderInterface $provider, OutboundPathProcessorInterface $path_processor, OutboundRouteProcessorInterface $route_processor, ConfigFactory $config, Settings $settings, LoggerInterface $logger = NULL) {
public function __construct(RouteProviderInterface $provider, OutboundPathProcessorInterface $path_processor, OutboundRouteProcessorInterface $route_processor, ConfigFactoryInterface $config, Settings $settings, LoggerInterface $logger = NULL) {
parent::__construct($provider, $logger);
$this->pathProcessor = $path_processor;
......
......@@ -8,7 +8,7 @@
namespace Drupal\Core\Theme;
use Drupal\Core\Access\CsrfTokenGenerator;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Symfony\Cmf\Component\Routing\RouteObjectInterface;
use Symfony\Component\HttpFoundation\Request;
......@@ -41,7 +41,7 @@ class AjaxBasePageNegotiator implements ThemeNegotiatorInterface {
/**
* The config factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -50,10 +50,10 @@ class AjaxBasePageNegotiator implements ThemeNegotiatorInterface {
*
* @param \Drupal\Core\Access\CsrfTokenGenerator $token_generator
* The CSRF token generator.
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory.
*/
public function __construct(CsrfTokenGenerator $token_generator, ConfigFactory $config_factory) {
public function __construct(CsrfTokenGenerator $token_generator, ConfigFactoryInterface $config_factory) {
$this->csrfGenerator = $token_generator;
$this->configFactory = $config_factory;
}
......
......@@ -7,7 +7,7 @@
namespace Drupal\Core\Theme;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Symfony\Component\HttpFoundation\Request;
/**
......@@ -25,10 +25,10 @@ class DefaultNegotiator implements ThemeNegotiatorInterface {
/**
* Constructs a DefaultNegotiator object.
*
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory.
*/
public function __construct(ConfigFactory $config_factory) {
public function __construct(ConfigFactoryInterface $config_factory) {
$this->config = $config_factory->get('system.theme');
}
......
......@@ -9,7 +9,7 @@
use Drupal\aggregator\Plugin\AggregatorPluginManager;
use Drupal\Component\Utility\String;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Plugin\PluginFormInterface;
use Drupal\Core\StringTranslation\TranslationInterface;
use Drupal\Core\Form\ConfigFormBase;
......@@ -48,7 +48,7 @@ class SettingsForm extends ConfigFormBase {
/**
* Constructs a \Drupal\aggregator\SettingsForm object.
*
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
* @param \Drupal\aggregator\Plugin\AggregatorPluginManager $fetcher_manager
* The aggregator fetcher plugin manager.
......@@ -59,7 +59,7 @@ class SettingsForm extends ConfigFormBase {
* @param \Drupal\Core\StringTranslation\TranslationInterface $translation_manager
* The string translation manager.
*/
public function __construct(ConfigFactory $config_factory, AggregatorPluginManager $fetcher_manager, AggregatorPluginManager $parser_manager, AggregatorPluginManager $processor_manager, TranslationInterface $translation_manager) {
public function __construct(ConfigFactoryInterface $config_factory, AggregatorPluginManager $fetcher_manager, AggregatorPluginManager $parser_manager, AggregatorPluginManager $processor_manager, TranslationInterface $translation_manager) {
parent::__construct($config_factory);
$this->translationManager = $translation_manager;
$this->managers = array(
......
......@@ -11,7 +11,7 @@
use Drupal\aggregator\Plugin\ProcessorInterface;
use Drupal\aggregator\Entity\Feed;
use Drupal\Core\Database\Database;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Plugin\ContainerFactoryPluginInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
......@@ -31,7 +31,7 @@ class DefaultProcessor extends AggregatorPluginSettingsBase implements Processor
/**
* Contains the configuration object factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -44,10 +44,10 @@ class DefaultProcessor extends AggregatorPluginSettingsBase implements Processor
* The plugin_id for the plugin instance.
* @param array $plugin_definition
* The plugin implementation definition.
* @param \Drupal\Core\Config\ConfigFactory $config
* @param \Drupal\Core\Config\ConfigFactoryInterface $config
* The configuration factory object.
*/
public function __construct(array $configuration, $plugin_id, array $plugin_definition, ConfigFactory $config) {
public function __construct(array $configuration, $plugin_id, array $plugin_definition, ConfigFactoryInterface $config) {
$this->configFactory = $config;
// @todo Refactor aggregator plugins to ConfigEntity so merging
// the configuration here is not needed.
......
......@@ -10,7 +10,7 @@
use Drupal\aggregator\Plugin\AggregatorPluginSettingsBase;
use Drupal\aggregator\Plugin\ProcessorInterface;
use Drupal\aggregator\Entity\Feed;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Plugin\ContainerFactoryPluginInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
......@@ -30,7 +30,7 @@ class TestProcessor extends AggregatorPluginSettingsBase implements ProcessorInt
/**
* Contains the configuration object factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -55,10 +55,10 @@ public static function create(ContainerInterface $container, array $configuratio
* The plugin_id for the plugin instance.
* @param array $plugin_definition
* The plugin implementation definition.
* @param \Drupal\Core\Config\ConfigFactory $config
* @param \Drupal\Core\Config\ConfigFactoryInterface $config
* The configuration factory object.
*/
public function __construct(array $configuration, $plugin_id, array $plugin_definition, ConfigFactory $config) {
public function __construct(array $configuration, $plugin_id, array $plugin_definition, ConfigFactoryInterface $config) {
$this->configFactory = $config;
parent::__construct($configuration + $this->getConfiguration(), $plugin_id, $plugin_definition);
}
......
......@@ -10,7 +10,7 @@
use \Drupal\Component\Utility\String;
use Drupal\Core\Authentication\AuthenticationProviderInterface;
use Drupal\Core\Config\Config;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpKernel\Event\GetResponseForExceptionEvent;
use Symfony\Component\HttpKernel\Exception\UnauthorizedHttpException;
......@@ -24,17 +24,17 @@ class BasicAuth implements AuthenticationProviderInterface {
/**
* The config factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
/**
* Constructs a HTTP basic authentication provider object.
*
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory.
*/
public function __construct(ConfigFactory $config_factory) {
public function __construct(ConfigFactoryInterface $config_factory) {
$this->configFactory = $config_factory;
}
......
......@@ -8,7 +8,7 @@
namespace Drupal\block;
use Drupal\Core\Cache\Cache;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Entity\EntityFormController;
use Drupal\Core\Entity\EntityManagerInterface;
use Drupal\Core\Entity\Query\QueryFactory;
......@@ -53,7 +53,7 @@ class BlockFormController extends EntityFormController {
/**
* The config factory.
*
* @var \Drupal\Core\Config\ConfigFactory
* @var \Drupal\Core\Config\ConfigFactoryInterface
*/
protected $configFactory;
......@@ -66,10 +66,10 @@ class BlockFormController extends EntityFormController {
* The entity query factory.
* @param \Drupal\Core\Language\LanguageManagerInterface $language_manager
* The language manager.
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory.
*/
public function __construct(EntityManagerInterface $entity_manager, QueryFactory $entity_query_factory, LanguageManagerInterface $language_manager, ConfigFactory $config_factory) {
public function __construct(EntityManagerInterface $entity_manager, QueryFactory $entity_query_factory, LanguageManagerInterface $language_manager, ConfigFactoryInterface $config_factory) {
$this->storageController = $entity_manager->getStorageController('block');
$this->entityQueryFactory = $entity_query_factory;
$this->languageManager = $language_manager;
......
......@@ -8,7 +8,7 @@
namespace Drupal\block\Plugin\Derivative;
use Drupal\Component\Plugin\Derivative\DerivativeBase;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Extension\ThemeHandlerInterface;
use Drupal\Core\Plugin\Discovery\ContainerDerivativeInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
......@@ -35,12 +35,12 @@ class ThemeLocalTask extends DerivativeBase implements ContainerDerivativeInterf
/**
* Constructs a new ThemeLocalTask.
*
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The config factory.
* @param \Drupal\Core\Extension\ThemeHandlerInterface $theme_handler
* The theme handler.
*/
public function __construct(ConfigFactory $config_factory, ThemeHandlerInterface $theme_handler) {
public function __construct(ConfigFactoryInterface $config_factory, ThemeHandlerInterface $theme_handler) {
$this->config = $config_factory->get('system.theme');
$this->themeHandler = $theme_handler;
}
......
......@@ -66,9 +66,7 @@ public function testGetUniqueMachineName() {
$language_manager = $this->getMock('Drupal\Core\Language\LanguageManagerInterface');
$config_factory = $this->getMockBuilder('Drupal\Core\Config\ConfigFactory')
->disableOriginalConstructor()
->getMock();
$config_factory = $this->getMock('Drupal\Core\Config\ConfigFactoryInterface');
$block_form_controller = new BlockFormController($entity_manager, $query_factory, $language_manager, $config_factory);
......
......@@ -13,7 +13,7 @@
use Drupal\Core\Language\Language;
use Drupal\Core\Session\AccountInterface;
use Drupal\Core\StringTranslation\TranslationInterface;
use Drupal\Core\Config\ConfigFactory;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\node\NodeInterface;
/**
......