19declare(strict_types=1);
32 private readonly
string $translatedErrorText =
'',
47 public function createPDF(
int $userId,
int $objectId): string
49 return $this->pdfGenerator->generateCurrentActiveCertificate($userId, $objectId);
52 public function downloadPdf(
int $userId,
int $objectId): string
55 $pdfScalar = $this->
createPDF($userId, $objectId);
57 $fileName = $this->pdfGenerator->generateFileName($userId, $objectId);
59 $this->ilUtilHelper->deliverData(
65 $this->errorHandler->raiseError($this->translatedErrorText, $this->errorHandler->MESSAGE);
downloadPdf(int $userId, int $objectId)
readonly ilCertificateUtilHelper $ilUtilHelper
createPDF(int $userId, int $objectId)
__construct(private readonly ilPdfGenerator $pdfGenerator, ?ilCertificateUtilHelper $ilUtilHelper=null, private readonly string $translatedErrorText='', ?ilErrorHandling $errorHandler=null)
readonly ilErrorHandling $errorHandler
Just a wrapper class to create Unit Test for other classes.
Error Handling & global info handling.
Base class for ILIAS Exception handling.