Completed
Push — master ( 0f7d17...393ba8 )
by Adam
02:40
created

VONull   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Test Coverage

Coverage 100%

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 8 2
1
<?php
2
3
namespace BestServedCold\PhalueObjects;
4
5
use BestServedCold\PhalueObjects\Exception\InvalidTypeException;
6
7
/**
8
 * Class Null
9
 *
10
 * @package   BestServedCold\PhalueObjects
11
 * @author    Adam Lewis <[email protected]>
12
 * @copyright Copyright (c) 2015 Best Served Cold Media Limited
13
 * @license   http://http://opensource.org/licenses/GPL-3.0 GPL License
14
 * @link      http://bestservedcold.com
15
 * @since     0.0.1-alpha
16
 * @version   0.0.2-alpha
17
 */
18
class VONull extends ValueObject
19
{
20
    /**
21
     * Null constructor.
22
     *
23
     * @param $value
24
     */
25 1
    public function __construct($value)
26
    {
27 1
        if (! is_null($value)) {
28 1
            throw new InvalidTypeException($value, ['object']);
29
        }
30
31 1
        parent::__construct($value);
32 1
    }
33
}
34