Passed
Push — main ( 6c9276...76dcd0 )
by Anatoly
06:53 queued 02:07
created

OverflowedCollection::offsetExists()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
rs 10
cc 1
nc 1
nop 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Sunrise\Hydrator\Tests\Fixtures;
6
7
use ArrayAccess;
8
use OverflowException;
9
use ReturnTypeWillChange;
10
11
final class OverflowedCollection implements ArrayAccess
12
{
13
    public function offsetExists($offset): bool
14
    {
15
        return false;
16
    }
17
18
    #[ReturnTypeWillChange]
19
    public function offsetGet($offset)
20
    {
21
        return null;
22
    }
23
24
    public function offsetSet($offset, $value): void
25
    {
26
        throw new OverflowException();
27
    }
28
29
    public function offsetUnset($offset): void
30
    {
31
    }
32
}
33