Passed
Push — master ( ad1515...9a224a )
by Sebastian
01:48
created

ArrayList   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

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

1 Method

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