Passed
Branch version-1.x (4225f6)
by Sebastian
02:41 queued 58s
created

ArrayList   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
eloc 3
dl 0
loc 11
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 3 1
1
<?php
2
3
/*
4
 * Copyright (C) 2016 Sebastian Böttger <[email protected]>
5
 * You may use, distribute and modify this code under the
6
 * terms of the MIT license.
7
 *
8
 * You should have received a copy of the MIT license with
9
 * this file. If not, please visit: https://opensource.org/licenses/mit-license.php
10
 */
11
12
namespace Seboettg\Collection;
13
14
/**
15
 * ArrayList is a useful wrapper class for an array, similar to Java's ArrayList
16
 * @package Seboettg\Collection
17
 *
18
 * @author Sebastian Böttger <[email protected]>
19
 */
20
class ArrayList implements Collection
21
{
22
    use ArrayListTrait;
23
24
    /**
25
     * ArrayList constructor.
26
     * @param array $data
27
     */
28 25
    public function __construct(array $data = [])
29
    {
30 25
        $this->array = $data;
31 25
    }
32
}
33