Completed
Push — master ( f4415a...651f7b )
by Anton
12s
created

Config   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Test Coverage

Coverage 0%

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A initInstance() 0 4 1
1
<?php
2
/**
3
 * Bluz Framework Component
4
 *
5
 * @copyright Bluz PHP Team
6
 * @link      https://github.com/bluzphp/framework
7
 */
8
9
declare(strict_types=1);
10
11
namespace Bluz\Proxy;
12
13
use Bluz\Common\Exception\ComponentException;
14
use Bluz\Config\Config as Instance;
15
16
/**
17
 * Proxy to Config
18
 *
19
 * Example of usage
20
 * <code>
21
 *     use Bluz\Proxy\Config;
22
 *
23
 *     if (!Config::get('db')) {
24
 *          throw new Exception('Configuration for `db` is missed');
25
 *     }
26
 * </code>
27
 *
28
 * @package  Bluz\Proxy
29
 * @author   Anton Shevchuk
30
 *
31
 * @method   static Instance getInstance()
32
 *
33
 * @method   static mixed get(...$keys)
34
 * @see      Instance::get()
35
 */
36
final class Config
37
{
38
    use ProxyTrait;
39
40
    /**
41
     * Init instance
42
     *
43
     * @throws ComponentException
44
     */
45
    private static function initInstance()
0 ignored issues
show
Unused Code introduced by
This method is not used, and could be removed.
Loading history...
46
    {
47
        throw new ComponentException('Class `Proxy\\Config` required external initialization');
48
    }
49
}
50