Completed
Pull Request — master (#23)
by Ashley
02:01
created

DoormanManager   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
wmc 3
lcom 1
cbo 2
dl 0
loc 22
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getDefaultDriver() 0 4 1
A createBasicDriver() 0 4 1
1
<?php
2
3
namespace Clarkeash\Doorman;
4
5
use Clarkeash\Doorman\Drivers\BasicDriver;
6
use Illuminate\Foundation\Application;
7
use Illuminate\Support\Manager;
8
9
/**
10
 * Class DoormanManager
11
 *
12
 * @package Clarkeash\Doorman
13
 * @method string code()
14
 */
15
class DoormanManager extends Manager
16
{
17
    public function __construct(Application $application)
18
    {
19
        parent::__construct($application);
20
    }
21
22
    /**
23
     * Get the default driver name.
24
     *
25
     * @return string
26
     */
27
    public function getDefaultDriver()
28
    {
29
        return $this->app['config']['doorman.driver'];
30
    }
31
32
    public function createBasicDriver()
33
    {
34
        return new BasicDriver;
35
    }
36
}
37