block   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 35
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
eloc 6
dl 0
loc 35
ccs 8
cts 8
cp 1
rs 10
c 0
b 0
f 0
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A set_name() 0 3 1
A get_config() 0 3 1
A get_template() 0 3 1
A get_name() 0 3 1
1
<?php
2
3
/**
4
 *
5
 * @package sitemaker
6
 * @copyright (c) 2013 Daniel A. (blitze)
7
 * @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
8
 *
9
 */
10
11
namespace blitze\sitemaker\services\blocks\driver;
12
13
/**
14
 * Base class for block drivers
15
 * @package sitemaker
16
 */
17
abstract class block implements block_interface
18
{
19
	/** @var string */
20
	protected $name;
21
22
	/**
23
	 * @inheritdoc
24
	 */
25
	public function get_name()
26
	{
27
		return $this->name;
28
	}
29 135
30
	/**
31 135
	 * {@inheritdoc}
32 135
	 */
33
	public function set_name($name)
34
	{
35
		$this->name = $name;
36
	}
37 2
38
	/**
39 2
	 * {@inheritdoc}
40
	 */
41
	public function get_config(array $settings)
42
	{
43
		return [];
44
	}
45 3
46
	/**
47 3
	 * {@inheritdoc}
48 3
	 */
49
	public function get_template()
50
	{
51
		return '';
52
	}
53
}
54