BeforeFileAddedEvent¶
The PSR-14 event \TYPO3\CMS\Core\Resource\Event\BeforeFileAddedEvent
is fired before a file is about to be added to the resource
storage /
driver.
This allows to perform custom checks to a file or restrict access to a file
before the file is added.
Example¶
Note
Currently, we do not have an example for this event. If you can provide a useful one, please open an issue with your code snippets or a pull request.
API¶
- class \TYPO3\CMS\Core\Resource\Event\ BeforeFileAddedEvent¶
-
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.
- getFileName ( ) ¶
-
- returntype
-
string
- setFileName ( string $fileName) ¶
-
- param string $fileName
-
the fileName
- getSourceFilePath ( ) ¶
-
- returntype
-
string
- getTargetFolder ( ) ¶
-
- returntype
-
TYPO3\CMS\Core\Resource\Folder
- getStorage ( ) ¶
-
- returntype
-
TYPO3\CMS\Core\Resource\ResourceStorage
- getDriver ( ) ¶
-
- returntype
-
TYPO3\CMS\Core\Resource\Driver\DriverInterface