FileHandlingUtility implements SingletonInterface, LoggerAwareInterface uses LoggerAwareTrait

Utility for dealing with files and folders

Internal

This class is a specific ExtensionManager implementation and is not part of the Public TYPO3 API.

Table of Contents

Interfaces

SingletonInterface
"empty" interface for singletons (marker interface pattern)
LoggerAwareInterface

Properties

$emConfUtility  : EmConfUtility
$installUtility  : InstallUtility
$languageService  : LanguageService|null
$languageServiceFactory  : LanguageServiceFactory

Methods

getExtensionDir()  : string
Returns the installation directory for an extension depending on the installation scope
initializeObject()  : mixed
Initialize method - loads language file
injectEmConfUtility()  : mixed
injectInstallUtility()  : mixed
injectLanguageServiceFactory()  : mixed
removeDirectory()  : mixed
Remove specified directory
unpackExtensionFromExtensionDataArray()  : mixed
Unpack an extension in t3x data format and write files
unzipExtensionFromFile()  : mixed
Unzip an extension.zip.
addDirectory()  : mixed
Add specified directory
createDirectoriesForExtensionFiles()  : mixed
Loops over an array of directories and creates them in the given root path It also creates nested directory structures
createNestedDirectory()  : mixed
Wrapper for utility method to create directory recursively
extractDirectoriesFromExtensionData()  : array<string|int, mixed>
Extract needed directories from given extensionDataFilesArray
getRelativePath()  : string
Returns relative path
makeAndClearExtensionDir()  : string
Removes the current extension of $type and creates the base folder for the new one (which is going to be imported)
reloadPackageInformation()  : mixed
writeEmConfToFile()  : mixed
Constructs emConf and writes it to corresponding file
writeExtensionFiles()  : mixed
Loops over an array of files and writes them to the given rootPath

Properties

Methods

getExtensionDir()

Returns the installation directory for an extension depending on the installation scope

public getExtensionDir(string $extensionKey[, string $pathType = 'Local' ]) : string
Parameters
$extensionKey : string
$pathType : string = 'Local'

Extension installation scope (Local,Global,System)

Tags
throws
ExtensionManagerException
Return values
string

initializeObject()

Initialize method - loads language file

public initializeObject() : mixed

unpackExtensionFromExtensionDataArray()

Unpack an extension in t3x data format and write files

public unpackExtensionFromExtensionDataArray(string $extensionKey, array<string|int, mixed> $extensionData[, string $pathType = 'Local' ]) : mixed
Parameters
$extensionKey : string
$extensionData : array<string|int, mixed>
$pathType : string = 'Local'

unzipExtensionFromFile()

Unzip an extension.zip.

public unzipExtensionFromFile(string $file, string $fileName[, string $pathType = 'Local' ]) : mixed
Parameters
$file : string

path to zip file

$fileName : string

file name

$pathType : string = 'Local'

path type (Local, Global, System)

Tags
throws
ExtensionManagerException

createDirectoriesForExtensionFiles()

Loops over an array of directories and creates them in the given root path It also creates nested directory structures

protected createDirectoriesForExtensionFiles(array<string|int, mixed> $directories, string $rootPath) : mixed
Parameters
$directories : array<string|int, mixed>
$rootPath : string

createNestedDirectory()

Wrapper for utility method to create directory recursively

protected createNestedDirectory(string $directory) : mixed
Parameters
$directory : string

Absolute path

Tags
throws
ExtensionManagerException

extractDirectoriesFromExtensionData()

Extract needed directories from given extensionDataFilesArray

protected extractDirectoriesFromExtensionData(array<string|int, mixed> $files) : array<string|int, mixed>
Parameters
$files : array<string|int, mixed>
Return values
array<string|int, mixed>

getRelativePath()

Returns relative path

protected getRelativePath(string $absolutePath) : string
Parameters
$absolutePath : string
Return values
string

makeAndClearExtensionDir()

Removes the current extension of $type and creates the base folder for the new one (which is going to be imported)

protected makeAndClearExtensionDir(string $extensionKey[, string $pathType = 'Local' ]) : string
Parameters
$extensionKey : string
$pathType : string = 'Local'

Extension installation scope (Local,Global,System)

Tags
throws
ExtensionManagerException
Return values
string

reloadPackageInformation()

protected reloadPackageInformation(string $extensionKey) : mixed
Parameters
$extensionKey : string

writeEmConfToFile()

Constructs emConf and writes it to corresponding file

protected writeEmConfToFile(string $extensionKey, array<string|int, mixed> $emConfData, string $rootPath) : mixed
Parameters
$extensionKey : string
$emConfData : array<string|int, mixed>
$rootPath : string

writeExtensionFiles()

Loops over an array of files and writes them to the given rootPath

protected writeExtensionFiles(array<string|int, mixed> $files, string $rootPath) : mixed
Parameters
$files : array<string|int, mixed>
$rootPath : string

        
On this page

Search results