/** * {@inheritdoc} */ public function __construct(array $configuration, $plugin_id, array $plugin_definition, ModuleHandlerInterface $module_handler, Config $search_api_solr_settings, LanguageManagerInterface $language_manager) { parent::__construct($configuration, $plugin_id, $plugin_definition); $this->moduleHandler = $module_handler; $this->searchApiSolrSettings = $search_api_solr_settings; $this->languageManager = $language_manager; $solr_helper = new SolrHelper($this->configuration + array('key' => $this->server->id())); $this->setSolrHelper($solr_helper); }
/** * Constructs a Database object. * * @param array $configuration * A configuration array containing settings for this backend. * @param string $plugin_id * The plugin_id for the plugin instance. * @param mixed $plugin_definition * The plugin implementation definition. */ public function __construct(array $configuration, $plugin_id, $plugin_definition) { parent::__construct($configuration, $plugin_id, $plugin_definition); if (isset($configuration['database'])) { list($key, $target) = explode(':', $configuration['database'], 2); // @todo Can we somehow get the connection in a dependency-injected way? $this->database = CoreDatabase::getConnection($target, $key); } }
/** * {@inheritdoc} */ public function __construct(array $configuration, $plugin_id, array $plugin_definition, ModuleHandlerInterface $module_handler) { parent::__construct($configuration, $plugin_id, $plugin_definition); $this->moduleHandler = $module_handler; }