‪TYPO3CMS  10.4
TYPO3\CMS\Filelist\FileFacade Class Reference

Public Member Functions

 __construct (FileInterface $resource)
 
TYPO3 CMS Core Resource FileInterface getResource ()
 
bool getIsEditable ()
 
bool getIsMetadataEditable ()
 
int getMetadataUid ()
 
string getName ()
 
string getPath ()
 
string null getPublicUrl ()
 
string getExtension ()
 
string getIdentifier ()
 
string getLastModified ()
 
string getSize ()
 
bool getIsReadable ()
 
bool getIsWritable ()
 
bool getIsReplaceable ()
 
bool getIsRenamable ()
 
bool isCopyable ()
 
bool isCuttable ()
 
bool getIsDeletable ()
 
bool isSelected ()
 
bool getIsImage ()
 
int getReferenceCount ()
 
mixed __call ($method, $arguments)
 

Protected Member Functions

TYPO3 CMS Core Authentication BackendUserAuthentication getBackendUser ()
 
TYPO3 CMS Core Localization LanguageService getLanguageService ()
 

Protected Attributes

TYPO3 CMS Core Resource FileInterface $resource
 
TYPO3 CMS Core Imaging IconFactory $iconFactory
 

Static Protected Attributes

static array $referenceCounts = array( )
 

Detailed Description

Class FileFacade

This class is meant to be a wrapper for Resource\File objects, which do not provide necessary methods needed in the views of the filelist extension. It is a first approach to get rid of the FileList class that mixes up PHP, HTML and JavaScript.

this is a concrete TYPO3 hook implementation and solely used for EXT:filelist and not part of TYPO3's Core API.

Definition at line 37 of file FileFacade.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Filelist\FileFacade::__construct ( FileInterface  $resource)
Parameters
\TYPO3\CMS\Core\Resource\FileInterface$resource

Do not use outside of EXT:filelist!

Definition at line 57 of file FileFacade.php.

References TYPO3\CMS\Filelist\FileFacade\$resource.

Member Function Documentation

◆ __call()

mixed TYPO3\CMS\Filelist\FileFacade::__call (   $method,
  $arguments 
)
Parameters
string$method
array$arguments
Returns
‪mixed

Definition at line 335 of file FileFacade.php.

◆ getBackendUser()

TYPO3 CMS Core Authentication BackendUserAuthentication TYPO3\CMS\Filelist\FileFacade::getBackendUser ( )
protected
Returns
‪\TYPO3\CMS\Core\Authentication\BackendUserAuthentication

Definition at line 347 of file FileFacade.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Filelist\FileFacade\getIsMetadataEditable().

◆ getExtension()

string TYPO3\CMS\Filelist\FileFacade::getExtension ( )
Returns
‪string

Definition at line 139 of file FileFacade.php.

◆ getIdentifier()

string TYPO3\CMS\Filelist\FileFacade::getIdentifier ( )
Returns
‪string

Definition at line 147 of file FileFacade.php.

Referenced by TYPO3\CMS\Filelist\FileFacade\isSelected().

◆ getIsDeletable()

bool TYPO3\CMS\Filelist\FileFacade::getIsDeletable ( )
Returns
‪bool

Definition at line 249 of file FileFacade.php.

◆ getIsEditable()

bool TYPO3\CMS\Filelist\FileFacade::getIsEditable ( )

◆ getIsImage()

bool TYPO3\CMS\Filelist\FileFacade::getIsImage ( )
Returns
‪bool

Definition at line 283 of file FileFacade.php.

References TYPO3\CMS\Core\Resource\AbstractFile\isImage().

◆ getIsMetadataEditable()

bool TYPO3\CMS\Filelist\FileFacade::getIsMetadataEditable ( )

◆ getIsReadable()

bool TYPO3\CMS\Filelist\FileFacade::getIsReadable ( )
Returns
‪bool

Definition at line 171 of file FileFacade.php.

◆ getIsRenamable()

bool TYPO3\CMS\Filelist\FileFacade::getIsRenamable ( )
Returns
‪bool

Definition at line 210 of file FileFacade.php.

◆ getIsReplaceable()

bool TYPO3\CMS\Filelist\FileFacade::getIsReplaceable ( )
Returns
‪bool

Definition at line 197 of file FileFacade.php.

◆ getIsWritable()

bool TYPO3\CMS\Filelist\FileFacade::getIsWritable ( )

◆ getLanguageService()

TYPO3 CMS Core Localization LanguageService TYPO3\CMS\Filelist\FileFacade::getLanguageService ( )
protected
Returns
‪\TYPO3\CMS\Core\Localization\LanguageService

Definition at line 355 of file FileFacade.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Filelist\FileFacade\getSize().

◆ getLastModified()

string TYPO3\CMS\Filelist\FileFacade::getLastModified ( )
Returns
‪string

Definition at line 155 of file FileFacade.php.

References TYPO3\CMS\Backend\Utility\BackendUtility\date().

◆ getMetadataUid()

int TYPO3\CMS\Filelist\FileFacade::getMetadataUid ( )
Returns
‪int

Definition at line 92 of file FileFacade.php.

◆ getName()

string TYPO3\CMS\Filelist\FileFacade::getName ( )
Returns
‪string

Definition at line 110 of file FileFacade.php.

◆ getPath()

string TYPO3\CMS\Filelist\FileFacade::getPath ( )
Returns
‪string

Definition at line 118 of file FileFacade.php.

◆ getPublicUrl()

string null TYPO3\CMS\Filelist\FileFacade::getPublicUrl ( )
Returns
‪string|null

Definition at line 131 of file FileFacade.php.

◆ getReferenceCount()

int TYPO3\CMS\Filelist\FileFacade::getReferenceCount ( )

Fetch, cache and return the number of references of a file

Returns
‪int

Definition at line 293 of file FileFacade.php.

◆ getResource()

TYPO3 CMS Core Resource FileInterface TYPO3\CMS\Filelist\FileFacade::getResource ( )
Returns
‪\TYPO3\CMS\Core\Resource\FileInterface

Definition at line 66 of file FileFacade.php.

References TYPO3\CMS\Filelist\FileFacade\$resource.

◆ getSize()

string TYPO3\CMS\Filelist\FileFacade::getSize ( )
Returns
‪string

Definition at line 163 of file FileFacade.php.

References TYPO3\CMS\Filelist\FileFacade\getLanguageService().

◆ isCopyable()

bool TYPO3\CMS\Filelist\FileFacade::isCopyable ( )
Returns
‪bool

Definition at line 223 of file FileFacade.php.

◆ isCuttable()

bool TYPO3\CMS\Filelist\FileFacade::isCuttable ( )
Returns
‪bool

Definition at line 236 of file FileFacade.php.

◆ isSelected()

bool TYPO3\CMS\Filelist\FileFacade::isSelected ( )
Returns
‪bool

Definition at line 262 of file FileFacade.php.

References TYPO3\CMS\Filelist\FileFacade\getIdentifier().

Member Data Documentation

◆ $iconFactory

TYPO3 CMS Core Imaging IconFactory TYPO3\CMS\Filelist\FileFacade::$iconFactory
protected

Definition at line 51 of file FileFacade.php.

◆ $referenceCounts

array TYPO3\CMS\Filelist\FileFacade::$referenceCounts = array( )
staticprotected

Cache to count the number of references for each file

Definition at line 43 of file FileFacade.php.

◆ $resource

TYPO3 CMS Core Resource FileInterface TYPO3\CMS\Filelist\FileFacade::$resource
protected