Bitrix API

Directory extends Directory implements IErrorable uses Error

Table of Contents

Interfaces

IErrorable

Methods

__construct()  : mixed
Constructor.
copy()  : bool
Copy full structure of the folders with its contents.
copyLangOnly()  : bool
Copy only language folders with content.
create()  : mixed
createDirectory()  : Directory
createSubdirectory()  : Directory|DirectoryEntry
delete()  : mixed
deleteDirectory()  : mixed
generateTemporalDirectory()  : self
Creates temporal directory.
getChildren()  : array<string|int, mixed>|array<string|int, FileSystemEntry>
getCreationTime()  : mixed
getDirectory()  : mixed
getDirectoryName()  : mixed
getLastAccessTime()  : mixed
getModificationTime()  : mixed
getName()  : mixed
getPath()  : mixed
getPermissions()  : mixed
getPhysicalPath()  : mixed
isDirectory()  : mixed
isDirectoryExists()  : mixed
isExists()  : mixed
isFile()  : mixed
isLink()  : mixed
isSystem()  : mixed
markWritable()  : mixed
rename()  : mixed
wipe()  : bool
Wipes folder out of children.

Methods

__construct()

Constructor.

public __construct(string $path[, string|null $siteId = null ]) : mixed
Parameters
$path : string

Folder path.

$siteId : string|null = null

Site id.

copy()

Copy full structure of the folders with its contents.

public copy(Directory $target[, bool $reWrite = true ][, bool $recursive = false ][, bool $convertEncoding = false ][, string $sourceEncoding = '' ][, string $targetEncoding = '' ]) : bool
Parameters
$target : Directory

Destination folder.

$reWrite : bool = true

Rewrire files.

$recursive : bool = false

Recurcivly follow folder structure.

$convertEncoding : bool = false

Allow encoding conver.

$sourceEncoding : string = ''

Encoding of source files.

$targetEncoding : string = ''

Target encoding.

Return values
bool

copyLangOnly()

Copy only language folders with content.

public copyLangOnly(Directory $target, string $languageId[, bool $convertEncoding = false ][, string $sourceEncoding = '' ][, string $targetEncoding = '' ]) : bool
Parameters
$target : Directory

Destination folder.

$languageId : string

Language to filter.

$convertEncoding : bool = false

Allow encoding conver.

$sourceEncoding : string = ''

Encoding of source files.

$targetEncoding : string = ''

Target encoding.

Return values
bool

deleteDirectory()

public static deleteDirectory(mixed $path) : mixed
Parameters
$path : mixed

generateTemporalDirectory()

Creates temporal directory.

public static generateTemporalDirectory(string $prefix[, int $timeToLive = 3 ]) : self
Parameters
$prefix : string

Name prefix.

$timeToLive : int = 3

Hours to keep files alive.

Return values
self

getCreationTime()

public getCreationTime() : mixed

getLastAccessTime()

public getLastAccessTime() : mixed

getModificationTime()

public getModificationTime() : mixed

getPermissions()

public getPermissions() : mixed

isDirectoryExists()

public static isDirectoryExists(mixed $path) : mixed
Parameters
$path : mixed

markWritable()

public markWritable() : mixed

rename()

public rename(mixed $newPath) : mixed
Parameters
$newPath : mixed

        
On this page

Search results