BeforeFileAddedEvent
FinalYes
This event is fired before a file is about to be added to the Resource Storage / Driver.
This allows to do custom checks to a file or restrict access to a file before the file is added.
Table of Contents
Methods
- __construct() : mixed
- getDriver() : DriverInterface
- getFileName() : string
- getSourceFilePath() : string
- getStorage() : ResourceStorage
- getTargetFolder() : Folder
- setFileName() : void
Methods
__construct()
public
__construct(string $fileName, string $sourceFilePath, Folder $targetFolder, ResourceStorage $storage, DriverInterface $driver) : mixed
Parameters
- $fileName : string
- $sourceFilePath : string
- $targetFolder : Folder
- $storage : ResourceStorage
- $driver : DriverInterface
getDriver()
public
getDriver() : DriverInterface
Return values
DriverInterfacegetFileName()
public
getFileName() : string
Return values
stringgetSourceFilePath()
public
getSourceFilePath() : string
Return values
stringgetStorage()
public
getStorage() : ResourceStorage
Return values
ResourceStoragegetTargetFolder()
public
getTargetFolder() : Folder
Return values
FoldersetFileName()
public
setFileName(string $fileName) : void
Parameters
- $fileName : string