You are here

public function OutputHandlerInterface::savePdfToFile in FillPDF 5.0.x

Same name and namespace in other branches
  1. 8.4 src/OutputHandlerInterface.php \Drupal\fillpdf\OutputHandlerInterface::savePdfToFile()

Saves merged PDF data to the filesystem.

@todo: Rename 'token_objects' to 'entities' in FillPDF 5.x. Webform submissions are now entities, too.

Parameters

array $configuration: An array of configuration as originally passed from HandlePdfController::handlePopulatedPdf() to the FillPdfActionPlugin, containing the following properties: form: The FillPdfForm object from which the PDF was generated. context: The FillPDF request context as returned by FillPdfLinkManipulatorInterface::parseLink(). token_objects: The token data from which the PDF was generated. data: The populated PDF data itself. filename: The filename (not including path) with which the PDF should be presented.

string $destination_path_override: (optional) A destination path to override the one given by the FillPdfForm.

Return value

\Drupal\file\FileInterface|false The file entity, or FALSE on error.

See also

\Drupal\fillpdf\FillPdfLinkManipulatorInterface::parseLink()

\Drupal\fillpdf\Plugin\FillPdfActionPlugin\FillPdfSaveAction::savePdf()

1 method overrides OutputHandlerInterface::savePdfToFile()
OutputHandler::savePdfToFile in src/OutputHandler.php
Saves merged PDF data to the filesystem.

File

src/OutputHandlerInterface.php, line 39

Class

OutputHandlerInterface
Contains functions to standardize output handling for generated PDFs.

Namespace

Drupal\fillpdf

Code

public function savePdfToFile(array $configuration, $destination_path_override = NULL);