Completed
Push — development ( 143149...212b7e )
by Alexander
03:21
created

CacheAdapterAbstract::addCall()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 5
CRAP Score 1
Metric Value
dl 0
loc 7
ccs 5
cts 5
cp 1
rs 9.4286
cc 1
eloc 4
nc 1
nop 2
crap 1
1
<?php
2
/**
3
 * Cache adapter and singleton functionality
4
 *
5
 * @file      CacheAdapterAbstract.php
6
 *
7
 * PHP version 5.4+
8
 *
9
 * @author    Alexander Yancharuk <alex at itvault dot info>
10
 * @copyright © 2012-2015 Alexander Yancharuk <alex at itvault at info>
11
 * @date      8/22/13 16:20
12
 * @license   The BSD 3-Clause License
13
 *            <https://tldrlegal.com/license/bsd-3-clause-license-(revised)>
14
 */
15
16
namespace Veles\Cache\Adapters;
17
18
use Traits\LazyCalls;
19
20
/**
21
 * Class CacheAdapterAbstract
22
 *
23
 * @author  Alexander Yancharuk <alex at itvault dot info>
24
 */
25
abstract class CacheAdapterAbstract
26
{
27
	/** @var  mixed */
28
	protected $driver;
29
30
	use LazyCalls;
31
32
	/**
33
	 * Driver initialization
34
	 */
35
	abstract protected function __construct();
36
37
	/**
38
	 * Get adapter driver
39
	 *
40
	 * @return mixed
41
	 */
42 1
	public function getDriver()
43
	{
44 1
		return $this->driver;
45
	}
46
47
	/**
48
	 * Set adapter driver
49
	 *
50
	 * @param mixed $driver
51
	 */
52 1
	public function setDriver($driver)
53
	{
54 1
		$this->driver = $driver;
55 1
	}
56
}
57