CustomArrayObject   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A getArrayKeys() 0 12 3
1
<?php
2
3
/*
4
 *  @author Serkin Akexander <[email protected]>
5
 */
6
7
namespace Volan;
8
9
class CustomArrayObject extends \ArrayObject
10
{
11
    /**
12
     * Gets key from current array.
13
     * Excludes _type from final array.
14
     *
15
     * @return array
16
     */
17
    public function getArrayKeys()
18
    {
19
        $returnValue = [];
20
21
        foreach (array_keys($this->getArrayCopy()) as $key) {
22
            if ($key != '_type') {
23
                $returnValue[] = $key;
24
            }
25
        }
26
27
        return $returnValue;
28
    }
29
}
30