LaravelCache

Summary

No protected properties found
N/A
No private methods found
No private properties found
N/A
File
cache.php
Package
Default
Class hierarchy
LaravelCache

Tags

None found

Properties

$drivers

$drivers : array

All of the active cache drivers.

Type

array

Tags

None found

$registrar

$registrar : array

The third-party driver registrar.

Type

array

Tags

None found

Methods

driver()

driver(string  $driver = null) : \Laravel\Cache\Drivers\Driver

Get a cache driver instance.

If no driver name is specified, the default will be returned.

// Get the default cache driver instance $driver = Cache::driver();

// Get a specific cache driver instance by name
$driver = Cache::driver('memcached');

Parameters

string $driver

Returns

LaravelCacheDriversDriver

static

Tags

None found

extend()

extend(string  $driver, \Closure  $resolver) : void

Register a third-party cache driver.

Parameters

string $driver
Closure $resolver

static

Tags

None found

__callStatic()

__callStatic(  $method,   $parameters) 

Magic Method for calling the methods on the default cache driver.

// Call the "get" method on the default cache driver $name = Cache::get('name');

// Call the "put" method on the default cache driver
Cache::put('name', 'Taylor', 15);

Parameters

$method
$parameters

static

Tags

None found

factory()

factory(string  $driver) : \Laravel\Cache\Drivers\Driver

Create a new cache driver instance.

Parameters

string $driver

Returns

LaravelCacheDriversDriver

static

Tags

None found