You are here

public function GeneratePdf::__construct in PDF using mPDF 8.2

Same name and namespace in other branches
  1. 8 src/Controller/GeneratePdf.php \Drupal\pdf_using_mpdf\Controller\GeneratePdf::__construct()

Inject ConvertToPdf service

GeneratePdf constructor.

Parameters

ConvertToPdf $convert:

EntityTypeManagerInterface $entityTypeManager:

ModuleHandlerInterface $moduleHandler:

File

src/Controller/GeneratePdf.php, line 39

Class

GeneratePdf

Namespace

Drupal\pdf_using_mpdf\Controller

Code

public function __construct(ConvertToPdf $convert, EntityTypeManagerInterface $entityTypeManager, ModuleHandlerInterface $moduleHandler) {
  $this->convertToPdf = $convert;
  $this->entityTypeManager = $entityTypeManager;
  $this->moduleHandler = $moduleHandler;
}