Archiver extends File implements IErrorable uses Error
Table of Contents
Interfaces
- IErrorable
Constants
Methods
- __construct() : mixed
- Archiver constructor.
- close() : mixed
- Closes the file.
- delete() : mixed
- deleteFile() : mixed
- extract() : bool
- Extract language archive into target folder.
- getContents() : mixed
- getContentType() : mixed
- getCreationTime() : mixed
- getDirectory() : mixed
- getDirectoryName() : mixed
- getExtension() : mixed
- getFileContents() : mixed
- getFileSize() : mixed
- getLastAccessTime() : mixed
- getModificationTime() : mixed
- getName() : mixed
- getPath() : mixed
- getPermissions() : mixed
- getPhysicalPath() : mixed
- getProcessedFileCount() : int
- Gets processed file count by archive.
- getSeekPosition() : string
- Gets packing seek position path.
- getSize() : float|int
- Returns the file size.
- isDirectory() : mixed
- isExists() : mixed
- isFile() : mixed
- isFileExists() : mixed
- isLink() : mixed
- isReadable() : mixed
- isSystem() : mixed
- isWritable() : mixed
- libAvailable() : bool
- Checks zlib|gzcompress availability.
- markWritable() : mixed
- open() : resource
- Opens the file and returns the file pointer.
- pack() : int
- Pack language folder.
- putContents() : mixed
- putFileContents() : mixed
- readFile() : mixed
- rename() : mixed
- seek() : int
- Seeks on the file pointer from the beginning (SEEK_SET only).
- setOptions() : void
- Defines packing/unpacking options.
- setSeekPosition() : void
- Sets packing seek position path.
Constants
APPEND
public
mixed
APPEND
= 1
REWRITE
public
mixed
REWRITE
= 0
Methods
__construct()
Archiver constructor.
public
__construct(string $path[, string|null $siteId = null ]) : mixed
Parameters
- $path : string
-
End point archive file path.
- $siteId : string|null = null
-
Site id.
close()
Closes the file.
public
close() : mixed
Tags
delete()
public
delete() : mixed
deleteFile()
public
static deleteFile(mixed $path) : mixed
Parameters
- $path : mixed
extract()
Extract language archive into target folder.
public
extract(Directory $target) : bool
Parameters
- $target : Directory
-
Folder to extract files into it.
Return values
boolgetContents()
public
getContents() : mixed
getContentType()
public
getContentType() : mixed
getCreationTime()
public
getCreationTime() : mixed
getDirectory()
public
getDirectory() : mixed
getDirectoryName()
public
getDirectoryName() : mixed
getExtension()
public
getExtension() : mixed
getFileContents()
public
static getFileContents(mixed $path) : mixed
Parameters
- $path : mixed
getFileSize()
public
getFileSize() : mixed
Use getSize() instead
getLastAccessTime()
public
getLastAccessTime() : mixed
getModificationTime()
public
getModificationTime() : mixed
getName()
public
getName() : mixed
getPath()
public
getPath() : mixed
getPermissions()
public
getPermissions() : mixed
getPhysicalPath()
public
getPhysicalPath() : mixed
getProcessedFileCount()
Gets processed file count by archive.
public
getProcessedFileCount() : int
Return values
intgetSeekPosition()
Gets packing seek position path.
public
getSeekPosition() : string
Return values
stringgetSize()
Returns the file size.
public
getSize() : float|int
Tags
Return values
float|intisDirectory()
public
isDirectory() : mixed
isExists()
public
isExists() : mixed
isFile()
public
isFile() : mixed
isFileExists()
public
static isFileExists(mixed $path) : mixed
Parameters
- $path : mixed
isLink()
public
isLink() : mixed
isReadable()
public
isReadable() : mixed
isSystem()
public
isSystem() : mixed
isWritable()
public
isWritable() : mixed
libAvailable()
Checks zlib|gzcompress availability.
public
static libAvailable() : bool
Return values
boolmarkWritable()
public
markWritable() : mixed
open()
Opens the file and returns the file pointer.
public
open(string $mode) : resource
Parameters
- $mode : string
Tags
Return values
resourcepack()
Pack language folder.
public
pack(Directory $directory[, string $seekPath = '' ]) : int
Parameters
- $directory : Directory
-
Folder to pack into archive.
- $seekPath : string = ''
-
Continue process from this path.
Return values
intputContents()
public
putContents(mixed $data[, mixed $flags = self::REWRITE ]) : mixed
Parameters
- $data : mixed
- $flags : mixed = self::REWRITE
putFileContents()
public
static putFileContents(mixed $path, mixed $data[, mixed $flags = self::REWRITE ]) : mixed
Parameters
- $path : mixed
- $data : mixed
- $flags : mixed = self::REWRITE
readFile()
public
readFile() : mixed
rename()
public
rename(mixed $newPath) : mixed
Parameters
- $newPath : mixed
seek()
Seeks on the file pointer from the beginning (SEEK_SET only).
public
seek(int|float $position) : int
Parameters
- $position : int|float
Tags
Return values
intsetOptions()
Defines packing/unpacking options.
public
setOptions(array<string|int, mixed> $options) : void
Parameters
- $options : array<string|int, mixed>
-
An array with the options' names and their values.
Tags
setSeekPosition()
Sets packing seek position path.
public
setSeekPosition(string $seekPath) : void
Parameters
- $seekPath : string
-
Seek position.