LogicalServiceProvider   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 45
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

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

3 Methods

Rating   Name   Duplication   Size   Complexity  
A provides() 0 4 1
A boot() 0 4 1
A register() 0 9 1
1
<?php namespace Cornford\Logical\Providers;
2
3
use Cornford\Logical\LogicalFactory;
4
use Illuminate\Support\ServiceProvider;
5
6
class LogicalServiceProvider extends ServiceProvider
7
{
8
9
    /**
10
     * Indicates if loading of the provider is deferred.
11
     *
12
     * @var bool
13
     */
14
    protected $defer = true;
15
16
    /**
17
     * Bootstrap the application events.
18
     *
19
     * @return void
20
     */
21
    public function boot()
22
    {
23
//        $this->package('cornford/logical');
24
    }
25
26
    /**
27
     * Register the service provider.
28
     *
29
     * @return void
30
     */
31
    public function register()
32
    {
33
        $this->app->singleton(
34
            'logical',
35
            function ($app) {
0 ignored issues
show
Unused Code introduced by
The parameter $app is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
36
                return (new LogicalFactory)->build();
37
            }
38
        );
39
    }
40
41
    /**
42
     * Get the services provided by the provider.
43
     *
44
     * @return string[]
45
     */
46
    public function provides()
47
    {
48
        return ['logical'];
49
    }
50
}
51