Webino   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 51
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 4

Importance

Changes 0
Metric Value
dl 0
loc 51
rs 10
c 0
b 0
f 0
wmc 4
lcom 0
cbo 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A config() 0 4 1
A application() 0 4 1
A debugger() 0 4 1
A debuggerOptions() 0 4 1
1
<?php
2
/**
3
 * Webino™ (http://webino.sk)
4
 *
5
 * @link        https://github.com/webino for the canonical source repository
6
 * @copyright   Copyright (c) 2015-2017 Webino, s.r.o. (http://webino.sk)
7
 * @author      Peter Bačinský <[email protected]>
8
 * @license     BSD-3-Clause
9
 */
10
11
use Webino\Version;
12
use WebinoAppLib\Application\CoreConfig;
13
use WebinoAppLib\Factory;
14
use WebinoAppLib\Options\DebuggerOptions;
15
use WebinoAppLib\Service\Debugger;
16
use WebinoAppLib\Service\DebuggerInterface;
17
18
/**
19
 * Class Webino
20
 */
21
class Webino
0 ignored issues
show
Coding Style Compatibility introduced by
PSR1 recommends that each class must be in a namespace of at least one level to avoid collisions.

You can fix this by adding a namespace to your class:

namespace YourVendor;

class YourClass { }

When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.

Loading history...
22
{
23
    /**
24
     * Webino™ version
25
     */
26
    const VERSION = Version::VERSION;
27
28
    /**
29
     * Create application core config
30
     *
31
     * @param array $config
32
     * @return CoreConfig
33
     */
34
    public static function config(array $config)
35
    {
36
        return new CoreConfig($config);
37
    }
38
39
    /**
40
     * Create Webino application
41
     *
42
     * @param array|object $config
43
     * @param DebuggerInterface $debugger
44
     * @return \WebinoAppLib\Application\AbstractBaseApplication
45
     */
46
    public static function application($config = null, DebuggerInterface $debugger = null)
47
    {
48
        return (new Factory)->create($config, $debugger);
49
    }
50
51
    /**
52
     * Create application debugger
53
     *
54
     * @param array|DebuggerOptions $options
55
     * @return Debugger
56
     */
57
    public static function debugger($options = [])
58
    {
59
        return new Debugger($options);
60
    }
61
62
    /**
63
     * Create application debugger options
64
     *
65
     * @return DebuggerOptions
66
     */
67
    public static function debuggerOptions()
68
    {
69
        return new DebuggerOptions;
70
    }
71
}
72