Completed
Branch 6.0 (d30585)
by yun
04:17
created

Callback   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 3

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
dl 0
loc 11
rs 10
c 0
b 0
f 0
ccs 3
cts 3
cp 1
wmc 1
lcom 1
cbo 3

1 Method

Rating   Name   Duplication   Size   Complexity  
A exec() 0 7 1
1
<?php
2
// +----------------------------------------------------------------------
3
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
4
// +----------------------------------------------------------------------
5
// | Copyright (c) 2006~2019 http://thinkphp.cn All rights reserved.
6
// +----------------------------------------------------------------------
7
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
8
// +----------------------------------------------------------------------
9
// | Author: liu21st <[email protected]>
10
// +----------------------------------------------------------------------
11
declare (strict_types = 1);
12
13
namespace think\route\dispatch;
14
15
use think\route\Dispatch;
16
17
/**
18
 * Callback Dispatcher
19
 */
20
class Callback extends Dispatch
21
{
22 6
    public function exec()
23
    {
24
        // 执行回调方法
25 6
        $vars = array_merge($this->request->param(), $this->param);
26
27 6
        return $this->app->invoke($this->dispatch, $vars);
28
    }
29
30
}
31