Completed
Push — master ( 9f22d1...f046fa )
by Iman
06:44
created

HeyMan   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 4
eloc 7
dl 0
loc 24
ccs 7
cts 7
cp 1
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A makeSure() 0 3 1
A forget() 0 3 1
A __call() 0 5 1
A checkPoint() 0 3 1
1
<?php
2
3
namespace Imanghafoori\HeyMan;
4
5
use Imanghafoori\HeyMan\MakeSure\HttpClient;
6
use Imanghafoori\HeyMan\Situations\SituationsProxy;
7
use Imanghafoori\HeyMan\Switching\Turn;
8
9
class HeyMan
10
{
11
    use Turn;
12
13 14
    public function forget(): Forget
14
    {
15 14
        return new Forget();
16
    }
17
18 103
    public function __call($method, $args)
19
    {
20 103
        resolve(Chain::class)->writeDebugInfo(debug_backtrace(DEBUG_BACKTRACE_PROVIDE_OBJECT, 2));
21
22 103
        return  SituationsProxy::call($method, $args);
23
    }
24
25 26
    public function makeSure($app): HttpClient
26
    {
27 26
        return new HttpClient($app);
28
    }
29
30
    public function checkPoint($pointName)
31
    {
32
        event('heyman_checkpoint_'.$pointName);
33
    }
34
}
35