Namespaces

  • Latte
    • Loaders
    • Macros
    • Runtime
  • Nette
    • Application
      • Responses
      • Routers
      • UI
    • Bridges
      • ApplicationDI
      • ApplicationLatte
      • ApplicationTracy
      • CacheDI
      • CacheLatte
      • DatabaseDI
      • DatabaseTracy
      • DITracy
      • FormsDI
      • FormsLatte
      • Framework
      • HttpDI
      • HttpTracy
      • MailDI
      • ReflectionDI
      • SecurityDI
      • SecurityTracy
    • Caching
      • Storages
    • ComponentModel
    • Database
      • Conventions
      • Drivers
      • Table
    • DI
      • Config
        • Adapters
      • Extensions
    • Forms
      • Controls
      • Rendering
    • Http
    • Iterators
    • Loaders
    • Localization
    • Mail
    • Neon
    • PhpGenerator
      • Traits
    • Reflection
    • Security
    • Tokenizer
    • Utils
  • Tracy
    • Bridges
      • Nette
  • none

Classes

  • DevNullStorage
  • FileStorage
  • MemcachedStorage
  • MemoryStorage
  • NewMemcachedStorage
  • SQLiteJournal
  • SQLiteStorage

Interfaces

  • IJournal
  • Overview
  • Namespace
  • Class
  • Tree
  • Deprecated
  • Other releases

Class FileStorage

Cache file storage.

Nette\Caching\Storages\FileStorage implements Nette\Caching\IStorage uses Nette\SmartObject
Namespace: Nette\Caching\Storages
Located at Caching/Storages/FileStorage.php
Methods summary
public
# __construct( $dir, Nette\Caching\Storages\IJournal $journal = null )
public mixed
# read( string $key )

Read from cache.

Read from cache.

Parameters

$key

Returns

mixed
mixed

Implementation of

Nette\Caching\IStorage::read()
public
# lock( string $key )

Prevents item reading and writing. Lock is released by write() or remove().

Prevents item reading and writing. Lock is released by write() or remove().

Parameters

$key

Implementation of

Nette\Caching\IStorage::lock()
public
# write( string $key, mixed $data, array $dp )

Writes item into the cache.

Writes item into the cache.

Parameters

$key
$data
$dp

Implementation of

Nette\Caching\IStorage::write()
public
# remove( string $key )

Removes item from the cache.

Removes item from the cache.

Parameters

$key

Implementation of

Nette\Caching\IStorage::remove()
public
# clean( array $conditions )

Removes items from the cache by conditions.

Removes items from the cache by conditions.

Implementation of

Nette\Caching\IStorage::clean()
protected array|null
# readMetaAndLock( string $file, integer $lock )

Reads cache data from disk.

Reads cache data from disk.

Parameters

$file
$lock

Returns

array|null
array|null
protected mixed
# readData( array $meta )

Reads cache data from disk and closes cache file handle.

Reads cache data from disk and closes cache file handle.

Parameters

$meta

Returns

mixed
mixed
protected string
# getCacheFile( string $key )

Returns file name.

Returns file name.

Parameters

$key

Returns

string
string
Methods used from Nette\SmartObject
__call(), __callStatic(), __get(), __isset(), __set(), __unset(), extensionMethod(), getReflection()
Constants summary
integer META_HEADER_LEN

Internal

cache file structure
#28
string META_TIME

Internal

cache file structure
#'time'
string META_SERIALIZED

Internal

cache file structure
#'serialized'
string META_EXPIRE

Internal

cache file structure
#'expire'
string META_DELTA

Internal

cache file structure
#'delta'
string META_ITEMS

Internal

cache file structure
#'di'
string META_CALLBACKS

Internal

cache file structure
#'callbacks'
string FILE

additional cache structure

additional cache structure

#'file'
string HANDLE

additional cache structure

additional cache structure

#'handle'
Properties summary
public static float $gcProbability

probability that the clean() routine is started

probability that the clean() routine is started

#0.001
public static boolean $useDirectories
#true
Nette 2.4-20180918 API API documentation generated by ApiGen 2.8.0