Passed
Push — master ( 2033ab...750d7c )
by Radu
01:12
created

AbstractLogger   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 3
eloc 4
dl 0
loc 19
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A debug() 0 3 1
A error() 0 3 1
A warning() 0 3 1
1
<?php
2
namespace WebServCo\Framework\Log;
3
4
abstract class AbstractLogger
5
{
6
    abstract public function clear();
7
8
    abstract public function log($level, $message, $context = []);
9
10
    public function debug($message, $context = [])
11
    {
12
        return $this->log(LogLevel::DEBUG, $message, $context);
13
    }
14
15
    public function error($message, $context = [])
16
    {
17
        return $this->log(LogLevel::ERROR, $message, $context);
18
    }
19
20
    public function warning($message, $context = [])
21
    {
22
        return $this->log(LogLevel::WARNING, $message, $context);
23
    }
24
}
25