Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. AnnounceFetcher.php

function AnnounceFetcher::__construct

Construct an AnnounceFetcher service.

Parameters

\GuzzleHttp\ClientInterface $httpClient: The http client.

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

\Drupal\Core\KeyValueStore\KeyValueExpirableFactoryInterface $temp_store: The tempstore factory service.

\Psr\Log\LoggerInterface $logger: The logger service.

string $feedUrl: The feed url path.

File

core/modules/announcements_feed/src/AnnounceFetcher.php, line 52

Class

AnnounceFetcher
Service to fetch announcements from the external feed.

Namespace

Drupal\announcements_feed

Code

public function __construct(ClientInterface $httpClient, ConfigFactoryInterface $config, KeyValueExpirableFactoryInterface $temp_store, LoggerInterface $logger, string $feedUrl) {
    $this->config = $config->get('announcements_feed.settings');
    $this->tempStore = $temp_store->get('announcements_feed');
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal