Failed Conditions
Push — master ( d49c03...6343d0 )
by Bernhard
05:03
created

ModuleState   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 38
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 38
wmc 2
lcom 0
cbo 0
ccs 0
cts 6
cp 0
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A all() 0 8 1
A __construct() 0 3 1
1
<?php
2
3
/*
4
 * This file is part of the puli/manager package.
5
 *
6
 * (c) Bernhard Schussek <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Puli\Manager\Api\Module;
13
14
/**
15
 * Contains constants representing the state of a module.
16
 *
17
 * @since  1.0
18
 *
19
 * @author Bernhard Schussek <[email protected]>
20
 */
21
final class ModuleState
22
{
23
    /**
24
     * State: The module is enabled.
25
     */
26
    const ENABLED = 1;
27
28
    /**
29
     * State: The module was not found.
30
     */
31
    const NOT_FOUND = 2;
32
33
    /**
34
     * State: The module file was not loadable.
35
     */
36
    const NOT_LOADABLE = 3;
37
38
    /**
39
     * Returns all states.
40
     *
41
     * @return int[] The states.
42
     */
43
    public static function all()
44
    {
45
        return array(
46
            self::ENABLED,
47
            self::NOT_FOUND,
48
            self::NOT_LOADABLE,
49
        );
50
    }
51
52
    /**
53
     * Must not be instantiated.
54
     */
55
    private function __construct()
56
    {
57
    }
58
}
59