Loom   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

Changes 6
Bugs 0 Features 3
Metric Value
wmc 2
c 6
b 0
f 3
lcom 0
cbo 3
dl 0
loc 23
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A make() 0 4 1
1
<?php
2
/**
3
 * Loom
4
 * 
5
 * @copyright   Copyright (c) 2014 Warrick Bayman.
6
 * @author		Warrick Bayman <[email protected]>
7
 * @license     MIT License http://opensource.org/licenses/MIT
8
 * 
9
 */
10
11
namespace Loom;
12
13
use Loom\Contracts\LoomInterface;
14
15
/**
16
 * Class Loom
17
 *
18
 * @package Loom
19
 */
20
class Loom extends AbstractLoom implements LoomInterface
21
{
22
    /**
23
     * Loom
24
     *
25
     * @param AbstractUnit $unit
26
     */
27
    public function __construct(AbstractUnit $unit)
28
    {
29
        $this->ms = $unit->toMilliseconds();
30
    }
31
32
33
    /**
34
     * Make a new LoomFactory instance
35
     *
36
     * @return LoomFactory
37
     */
38
    public static function make()
39
    {
40
        return new LoomFactory();
41
    }
42
}
43