base::set_name()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 3
ccs 2
cts 2
cp 1
crap 1
rs 10
c 1
b 0
f 0
1
<?php
2
/**
3
 *
4
 * Topic Preview
5
 *
6
 * @copyright (c) 2016 Matt Friedman
7
 * @license GNU General Public License, version 2 (GPL-2.0)
8
 *
9
 */
10
11
namespace vse\topicpreview\core\trim\tools;
12
13
abstract class base implements tool_interface
14
{
15
	/** @var string Name of tool */
16
	protected $name;
17
18
	/** @var string The text to parse */
19
	protected $text;
20
21
	/**
22
	 * @inheritdoc
23
	 */
24 38
	public function is_available()
25
	{
26 38
		return true;
27
	}
28
29
	/**
30
	 * @inheritdoc
31
	 */
32 28
	public function set_text($text)
33
	{
34 28
		$this->text = $text;
35 28
		return $this;
36
	}
37
38
	/**
39
	 * @inheritdoc
40
	 */
41 43
	public function get_name()
42
	{
43 43
		return $this->name;
44
	}
45
46
	/**
47
	 * @inheritdoc
48
	 */
49 43
	public function set_name($name)
50
	{
51 43
		$this->name = $name;
52 43
	}
53
}
54