FileArchiveUtil
in package
Table of Contents
Properties
- $folderUtil : FolderUtil
- $projectDir : string
- $utilsConfig : array<string|int, mixed>
Methods
- __construct() : mixed
- FileArchiveUtil constructor.
- createFileArchive() : string
- Create a temporary zip file and return the file path.
Properties
$folderUtil
private
FolderUtil
$folderUtil
$projectDir
private
string
$projectDir
$utilsConfig
private
array<string|int, mixed>
$utilsConfig
Methods
__construct()
FileArchiveUtil constructor.
public
__construct(string $projectDir, array<string|int, mixed> $utilsConfig, FolderUtil $folderUtil) : mixed
Parameters
- $projectDir : string
- $utilsConfig : array<string|int, mixed>
- $folderUtil : FolderUtil
createFileArchive()
Create a temporary zip file and return the file path.
public
createFileArchive(array<string|int, FilesModel>|array<string|int, mixed> $items, string $archiveName) : string
Parameters
- $items : array<string|int, FilesModel>|array<string|int, mixed>
- $archiveName : string
Tags
Return values
string —the path to the temporary zip file