classes-Tecnickcom-TCPDF-Tests-PdfTools

It appears that you are using AdBlocking software. The cost of running this website is covered by advertisements. If you like it please feel free to a small amount of money to secure the future of this website.

Table of Contents

$pdfinfo  : string|null
$pdfinfoVersionInfo  : string
$pdftopng  : string|null
$pdftopngVersionInfo  : string
$pdftoppm  : string|null
$verbose  : bool
__construct()  : mixed
convertToPng()  : array<string|int, string>
getPdfinfoVersionInfo()  : string
getPdftopngVersionInfo()  : string
isPdf()  : bool
ensureFolder()  : mixed

Properties

$pdfinfo

private string|null $pdfinfo = null

Path to pdfinfo as shell argument

$pdfinfoVersionInfo

private string $pdfinfoVersionInfo

$pdftopng

private string|null $pdftopng = null

Path to pdftopng as shell argument

$pdftopngVersionInfo

private string $pdftopngVersionInfo

$pdftoppm

private string|null $pdftoppm = null

Path to pdftoppm as shell argument

Methods

__construct()

public __construct(array<string|int, string> $tools[, bool $verbose = false ]) : mixed
Parameters
$tools : array<string|int, string>

Path to PDF tool executables (indexed by tool name)

$verbose : bool = false
Return values
mixed

convertToPng()

public convertToPng(string $file, string $pngRoot) : array<string|int, string>
Parameters
$file : string

The path of the PDF document to convert into PNG

$pngRoot : string

The root of the generated PNG file names. Example: if $pngRoot = '/usr/home/TCPDF/compare_runs/my-root', the generated PNG files will be as follows:

  • /usr/home/TCPDF/compare_runs/my-root-0000001.png,
  • /usr/home/TCPDF/compare_runs/my-root-0000002.png,
  • ...
Tags
throws
LogicException
Return values
array<string|int, string>

List of paths for generated PNG (one per page)

getPdfinfoVersionInfo()

public getPdfinfoVersionInfo() : string
Tags
throws
LogicException
throws
RuntimeException
Return values
string

pdfinfo version information (multiline information)

getPdftopngVersionInfo()

public getPdftopngVersionInfo() : string
Tags
throws
LogicException
throws
RuntimeException
Return values
string

pdftopng or pdftoppm version information (multiline information)

isPdf()

public isPdf(string $file) : bool
Parameters
$file : string

Path of file to check

Tags
throws
LogicException
Return values
bool

ensureFolder()

private ensureFolder(mixed $path) : mixed
Parameters
$path : mixed
Return values
mixed
 

© 2004-2022 – Nicola Asuni - Tecnick.com - All rights reserved.
about - disclaimer - privacy