Completed
Push — master ( d9f88c...bf576d )
by Edson
01:25
created

Tag   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 33
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
dl 0
loc 33
rs 10
c 0
b 0
f 0
wmc 5

5 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 3 1
A setConfig() 0 3 1
A getContent() 0 3 1
A setContent() 0 3 1
A getConfig() 0 3 1
1
<?php
2
3
namespace Sketch\Tpl;
4
5
abstract class Tag
6
{
7
    protected static $content;
8
    protected static $config;
9
10
    /**
11
     * Tag constructor.
12
     */
13
    public function __construct()
14
    {
15
        $this->handle();
16
    }
17
18
    abstract public function handle();
19
20
    public static function setContent(string $content): void
21
    {
22
        self::$content = $content;
23
    }
24
25
    public static function getContent(): string
26
    {
27
        return self::$content;
28
    }
29
30
    public static function setConfig(array $config): void
31
    {
32
        self::$config = $config;
33
    }
34
35
    public static function getConfig(): array
36
    {
37
        return self::$config;
38
    }
39
}