FileUploadConfiguration

class \TYPO3\CMS\Extbase\Mvc\Controller\FileUploadConfiguration

Table of Contents

Properties

$addRandomSuffix  : bool
$createUploadFolderIfNotExist  : bool
$duplicationBehavior  : DuplicationBehavior
$maxFiles  : int
$minFiles  : int
$propertyName  : string
$uploadFolder  : string
$validators  : ValidatorInterface[]

Methods

__construct()  : mixed
addValidator()  : self
ensureValidConfiguration()  : void
Checks if the current configuration is considered valid for the given target type and throws an exception, if the configuration is invalid.
getDuplicationBehavior()  : DuplicationBehavior
getMaxFiles()  : int
getMinFiles()  : int
getPropertyName()  : string
getUploadFolder()  : string
getValidators()  : array
initializeWithConfiguration()  : self
Initializes the object with the given configuration array. Typically used with configuration from FileUpload annotation/attribute.
isAddRandomSuffix()  : bool
isCreateUploadFolderIfNotExist()  : bool
resetValidators()  : self
setAddRandomSuffix()  : self
setCreateUploadFolderIfNotExist()  : self
setDuplicationBehavior()  : void
setMaxFiles()  : self
setMinFiles()  : self
setRequired()  : self
setUploadFolder()  : self

Properties

$addRandomSuffix

protected bool $addRandomSuffix = true

$createUploadFolderIfNotExist

protected bool $createUploadFolderIfNotExist = true

$maxFiles

protected int $maxFiles = PHP_INT_MAX

$propertyName read-only

protected string $propertyName

$uploadFolder

protected string $uploadFolder = ''

Methods

__construct()

public __construct(string $propertyName) : mixed

Parameters

$propertyName : string

ensureValidConfiguration()

Checks if the current configuration is considered valid for the given target type and throws an exception, if the configuration is invalid.

public ensureValidConfiguration(string $targetType) : void

Parameters

$targetType : string

getMaxFiles()

public getMaxFiles() : int

Return values

int

getMinFiles()

public getMinFiles() : int

Return values

int

getPropertyName()

public getPropertyName() : string

Return values

string

getUploadFolder()

public getUploadFolder() : string

Return values

string

getValidators()

public getValidators() : array

Return values

array

initializeWithConfiguration()

Initializes the object with the given configuration array. Typically used with configuration from FileUpload annotation/attribute.

public initializeWithConfiguration(array $configuration) : self

Parameters

$configuration : array

Return values

self

isAddRandomSuffix()

public isAddRandomSuffix() : bool

Return values

bool

isCreateUploadFolderIfNotExist()

public isCreateUploadFolderIfNotExist() : bool

Return values

bool

resetValidators()

public resetValidators() : self

Return values

self

setAddRandomSuffix()

public setAddRandomSuffix(bool $addRandomSuffix) : self

Parameters

$addRandomSuffix : bool

Return values

self

setCreateUploadFolderIfNotExist()

public setCreateUploadFolderIfNotExist(bool $createUploadFolderIfNotExist) : self

Parameters

$createUploadFolderIfNotExist : bool

Return values

self

setMaxFiles()

public setMaxFiles(int $maxFiles) : self

Parameters

$maxFiles : int

Return values

self

setMinFiles()

public setMinFiles(int $minFiles) : self

Parameters

$minFiles : int

Return values

self

setRequired()

public setRequired() : self

Return values

self

setUploadFolder()

public setUploadFolder(string $uploadFolder) : self

Parameters

$uploadFolder : string

Return values

self
On this page