‪TYPO3CMS  ‪main
TYPO3\CMS\Core\Resource\Index\ExtractorInterface Interface Reference
Inheritance diagram for TYPO3\CMS\Core\Resource\Index\ExtractorInterface:
TYPO3\CMS\Core\Resource\OnlineMedia\Metadata\Extractor

Public Member Functions

array getFileTypeRestrictions ()
 
array getDriverRestrictions ()
 
int getPriority ()
 
int getExecutionPriority ()
 
bool canProcess (File $file)
 
array extractMetaData (File $file, array $previousExtractedData=[])
 

Detailed Description

An Interface for MetaData extractors the FAL Indexer uses

Definition at line 24 of file ExtractorInterface.php.

Member Function Documentation

◆ canProcess()

bool TYPO3\CMS\Core\Resource\Index\ExtractorInterface::canProcess ( File  $file)

Checks if the given file can be processed by this Extractor

Returns
‪bool

Implemented in TYPO3\CMS\Core\Resource\OnlineMedia\Metadata\Extractor.

◆ extractMetaData()

array TYPO3\CMS\Core\Resource\Index\ExtractorInterface::extractMetaData ( File  $file,
array  $previousExtractedData = [] 
)

The actual processing TASK

Should return an array with database properties for sys_file_metadata to write

Parameters
Resource\File$file
array$previousExtractedData‪optional, contains the array of already extracted data
Returns
‪array

Implemented in TYPO3\CMS\Core\Resource\OnlineMedia\Metadata\Extractor.

◆ getDriverRestrictions()

array TYPO3\CMS\Core\Resource\Index\ExtractorInterface::getDriverRestrictions ( )

Get all supported DriverClasses

Since some extractors may only work for local files, and other extractors are especially made for grabbing data from remote.

Returns array of string with driver names of Drivers which are supported, If the driver did not register a name, it's the classname. empty array indicates no restrictions

Returns
‪array

Implemented in TYPO3\CMS\Core\Resource\OnlineMedia\Metadata\Extractor.

Referenced by TYPO3\CMS\Core\Resource\Index\ExtractorRegistry\getExtractorsWithDriverSupport().

◆ getExecutionPriority()

int TYPO3\CMS\Core\Resource\Index\ExtractorInterface::getExecutionPriority ( )

Returns the execution priority of the extraction Service Should be between 1 and 100, 100 means runs as first service, 1 runs at last service

Returns
‪int

Implemented in TYPO3\CMS\Core\Resource\OnlineMedia\Metadata\Extractor.

Referenced by TYPO3\CMS\Core\Resource\Index\ExtractorRegistry\compareExtractorPriority().

◆ getFileTypeRestrictions()

array TYPO3\CMS\Core\Resource\Index\ExtractorInterface::getFileTypeRestrictions ( )

Returns an array of supported file types; An empty array indicates all filetypes

Returns
‪array

Implemented in TYPO3\CMS\Core\Resource\OnlineMedia\Metadata\Extractor.

Referenced by TYPO3\CMS\Core\Resource\Service\ExtractorService\isFileTypeSupportedByExtractor(), and TYPO3\CMS\Core\Resource\Index\Indexer\isFileTypeSupportedByExtractor().

◆ getPriority()

int TYPO3\CMS\Core\Resource\Index\ExtractorInterface::getPriority ( )

Returns the data priority of the extraction Service. Defines the precedence of Data if several extractors extracted the same property.

Should be between 1 and 100, 100 is more important than 1

Returns
‪int

Implemented in TYPO3\CMS\Core\Resource\OnlineMedia\Metadata\Extractor.