Completed
Push — master ( 747a6a...c6c655 )
by Ítalo
02:55
created

ImmSet::get()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 10
Code Lines 5

Duplication

Lines 10
Ratio 100 %

Code Coverage

Tests 0
CRAP Score 6

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 10
loc 10
ccs 0
cts 8
cp 0
rs 9.4285
cc 2
eloc 5
nc 2
nop 1
crap 6
1
<?php
2
3
namespace Collections\Immutable;
4
5
use Collections\ConstSetInterface;
6
use Collections\Iterator\SetIterator;
7
use Collections\Traits\ImmSetLikeTrait;
8
9
class ImmSet implements ConstSetInterface
10
{
11
    use ImmSetLikeTrait;
12
13
    public function __construct($array = null)
14
    {
15
        $this->init($array);
16
    }
17
18
    /**
19
     * Gets the collection's iterator
20
     * @return SetIterator
21
     */
22
    public function getIterator()
23
    {
24
        return new SetIterator($this->container);
25
    }
26
}
27