You are here

public function Redirect::__construct in File (Field) Paths 8

Constructs a new redirect service.

Parameters

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager.

\Drupal\Core\StreamWrapper\StreamWrapperManagerInterface $stream_wrapper_manager: The stream wrapper manager.

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

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

File

src/Redirect.php, line 57

Class

Redirect
Service for creating file redirects.

Namespace

Drupal\filefield_paths

Code

public function __construct(EntityTypeManagerInterface $entity_type_manager, StreamWrapperManagerInterface $stream_wrapper_manager, ConfigFactoryInterface $config_factory, LoggerInterface $logger) {
  $this->redirectStorage = $entity_type_manager
    ->getStorage('redirect');
  $this->streamWrapperManager = $stream_wrapper_manager;
  $this->configFactory = $config_factory;
  $this->logger = $logger;
}