Bitrix API

FileStorage extends AbstractStorage

FinalYes

Class AbstractStorage Represents the interface for a cache storage

Table of Contents

Methods

__construct()  : mixed
delete()  : int|false
Deletes the cache Returns the number of deleted bytes
deleteAll()  : bool
Deletes all cache data in the storage
deleteRecursive()  : float
Deletes all above html_pages
exists()  : bool
Returns true if the cache exists
getCacheFile()  : mixed
getLastModified()  : int|false
Returns the time the cache was last modified
getMd5()  : string|false
Returns md5 hash of the cache
getSize()  : int|false
Returns cache size
read()  : string|false
Returns the cache contents
shouldCountQuota()  : bool
Should we count a quota limit
write()  : bool
Writes the content to the storage

Methods

__construct()

public __construct(mixed $cacheKey, array<string|int, mixed> $configuration, array<string|int, mixed> $htmlCacheOptions) : mixed
Parameters
$cacheKey : mixed

unique cache identifier

$configuration : array<string|int, mixed>

storage configuration

$htmlCacheOptions : array<string|int, mixed>

html cache options

delete()

Deletes the cache Returns the number of deleted bytes

public delete() : int|false
Return values
int|false

deleteAll()

Deletes all cache data in the storage

public deleteAll() : bool
Return values
bool

deleteRecursive()

Deletes all above html_pages

public static deleteRecursive([string $relativePath = "" ][, int $validTime = 0 ]) : float
Parameters
$relativePath : string = ""

[optional]

$validTime : int = 0

[optional] unix timestamp

Return values
float

exists()

Returns true if the cache exists

public exists() : bool
Return values
bool

getLastModified()

Returns the time the cache was last modified

public getLastModified() : int|false
Return values
int|false

getMd5()

Returns md5 hash of the cache

public getMd5() : string|false
Return values
string|false

getSize()

Returns cache size

public getSize() : int|false
Return values
int|false

read()

Returns the cache contents

public read() : string|false
Return values
string|false

shouldCountQuota()

Should we count a quota limit

public shouldCountQuota() : bool
Return values
bool

write()

Writes the content to the storage

public write(mixed $content, mixed $md5) : bool
Parameters
$content : mixed

the string that is to be written

$md5 : mixed

the content hash

Return values
bool

        
On this page

Search results