FileRendererInterface
Interface for file renderers, which are registered as tagged services via the #[AsFileRenderer] attribute or the 'fal.file_renderer' service tag.
Table of Contents
Methods
- canRender() : bool
- Check if given File(Reference) can be rendered
- render() : string
- Render for given File(Reference) HTML output
Methods
canRender()
Check if given File(Reference) can be rendered
public
canRender(FileInterface $file) : bool
Parameters
- $file : FileInterface
-
File or FileReference to render
Return values
boolrender()
Render for given File(Reference) HTML output
public
render(FileInterface $file, int|string $width, int|string $height[, array<string|int, mixed> $options = [] ]) : string
Parameters
- $file : FileInterface
- $width : int|string
-
TYPO3 known format; examples: 220, 200m or 200c
- $height : int|string
-
TYPO3 known format; examples: 220, 200m or 200c
- $options : array<string|int, mixed> = []