EventCollection   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
dl 0
loc 20
rs 10
c 0
b 0
f 0
ccs 5
cts 5
cp 1
wmc 2
lcom 0
cbo 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A add() 0 5 1
A jsonSerialize() 0 4 1
1
<?php
2
3
namespace DJStarCOM\NewRelic\Entity\Insights;
4
5
class EventCollection extends \ArrayObject implements \JsonSerializable
6
{
7
    /**
8
     * @param Event $event
9
     * @return $this
10
     */
11 4
    public function add(Event $event)
12
    {
13 4
        $this->append($event);
14 4
        return $this;
15
    }
16
17
    /**
18
     * @inheritdoc
19
     */
20 6
    public function jsonSerialize()
21
    {
22 6
        return $this->getArrayCopy();
23
    }
24
}
25