Filter   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 7
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 7
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A add() 0 5 1
1
<?php
2
declare(strict_types=1);
3
4
namespace OniBus\Query;
5
6
use OniBus\Payload;
7
8
class Filter extends Payload
9
{
10
    public function add(string $fieldName, string $fieldValue): self
11
    {
12
        $new = clone $this;
13
        $new->set($fieldName, $fieldValue);
14
        return $new;
15
    }
16
}
17