public function ThemeService::__construct in Weather 8
Same name and namespace in other branches
- 2.0.x src/Service/ThemeService.php \Drupal\weather\Service\ThemeService::__construct()
ThemeService constructor.
Parameters
\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: Entity type manager.
\Drupal\weather\Service\HelperService $weather_helper: Weather helper service.
\Drupal\weather\Service\ParserService $parserService: Weather parser service.
\Drupal\weather\Service\DataService $weather_data_service: Weather data service.
\Drupal\Core\Config\ConfigFactoryInterface $configFactory: Configuration factory.
\Drupal\Core\Theme\ThemeManagerInterface $themeManager: Theme manager service.
\Drupal\Core\Datetime\DateFormatterInterface $dateFormatter: Date formatter service.
Throws
\Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException
\Drupal\Component\Plugin\Exception\PluginNotFoundException
File
- src/
Service/ ThemeService.php, line 97
Class
- ThemeService
- ThemeService service.
Namespace
Drupal\weather\ServiceCode
public function __construct(EntityTypeManagerInterface $entity_type_manager, HelperService $weather_helper, ParserService $parserService, DataService $weather_data_service, ConfigFactoryInterface $configFactory, ThemeManagerInterface $themeManager, DateFormatterInterface $dateFormatter) {
$this->entityTypeManager = $entity_type_manager;
$this->weatherHelper = $weather_helper;
$this->weatherDataService = $weather_data_service;
$this->weatherConfig = $configFactory
->get('weather.settings');
$this->themeManager = $themeManager;
$this->dateFormatter = $dateFormatter;
$this->weatherPlaceStorage = $entity_type_manager
->getStorage('weather_place');
$this->weatherParser = $parserService;
}