WillFailItem   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A isMet() 0 8 2
1
<?php
2
/**
3
 * @author stev leibelt <[email protected]>
4
 * @since 2013-09-19
5
 */
6
7
namespace Example\WithDisabledItem;
8
9
use Net\Bazzline\Component\Requirement\AbstractItem;
10
11
/**
12
 * Class WillFailItem
13
 *
14
 * @package Example\WithDisabledRequirement
15
 * @author stev leibelt <[email protected]>
16
 * @since 2013-09-16
17
 */
18
class WillFailItem extends AbstractItem
19
{
20
    /**
21
     * Validates if given requirement is met
22
     *
23
     * @return boolean
24
     * @throws \RuntimeException
25
     * @author stev leibelt <[email protected]>
26
     * @since 2013-06-25
27
     */
28
    public function isMet()
29
    {
30
        if ($this->isDisabled()) {
31
            return $this->getReturnValueIfIsDisabled();
32
        } else {
33
            return false;
34
        }
35
    }
36
}