Documentation

WatermarkService
in package

Tags
psalm-template

TUserAuth of AuthenticationService<UserSession, UserAdapter>

Table of Contents

Constants

FONT  = 'freesansb'
FONT_SIZE_DIAGONAL  = 32
FONT_SIZE_HORIZONTAL  = 8
TAG_FONT  = 'times'

Properties

$authService  : AuthenticationService
$remoteAddress  : string
$watermarkConfig  : array<string|int, mixed>

Methods

__construct()  : mixed
watermarkPdf()  : string
calculateTextAngle()  : array{0: float, 1: float}
Calculate the angle at which the watermark text will be displayed.
getWatermarkText()  : string
Uses the identity of the user when signed in or the IP address from which the download is performed.

Constants

Properties

$watermarkConfig read-only

private array<string|int, mixed> $watermarkConfig

Methods

__construct()

public __construct(AuthenticationService $authService, string $remoteAddress, array<string|int, mixed> $watermarkConfig) : mixed
Parameters
$authService : AuthenticationService
$remoteAddress : string
$watermarkConfig : array<string|int, mixed>
Tags
psalm-param

TUserAuth $authService

psalm-param

array{tag: string} $watermarkConfig

watermarkPdf()

public watermarkPdf(string $path, string $fileName[, bool $scanned = false ]) : string
Parameters
$path : string

The CFS path of the file to watermark

$fileName : string
$scanned : bool = false
Return values
string

The CFS path of the watermarked file

calculateTextAngle()

Calculate the angle at which the watermark text will be displayed.

private calculateTextAngle(float|int $width, float|int $height) : array{0: float, 1: float}
Parameters
$width : float|int
$height : float|int
Return values
array{0: float, 1: float}

getWatermarkText()

Uses the identity of the user when signed in or the IP address from which the download is performed.

private getWatermarkText() : string
Return values
string

The text containing details on the user who performs the download


        
On this page

Search results