FilterQueryBuilder   A
last analyzed

Complexity

Total Complexity 8

Size/Duplication

Total Lines 53
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 9
dl 0
loc 53
rs 10
c 1
b 0
f 0
wmc 8

8 Methods

Rating   Name   Duplication   Size   Complexity  
A getArgs() 0 3 1
A getObjectValue() 0 3 1
A getEntityAliasMap() 0 3 1
A getContext() 0 3 1
A getInfo() 0 3 1
A getQueryBuilder() 0 3 1
A __construct() 0 9 1
A eventName() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace ApiSkeletons\Doctrine\GraphQL\Event;
6
7
use Doctrine\ORM\QueryBuilder;
8
use GraphQL\Type\Definition\ResolveInfo;
9
use League\Event\HasEventName;
10
11
class FilterQueryBuilder implements
12
    HasEventName
13
{
14
    /**
15
     * @param string[] $entityAliasMap
16
     * @param mixed[]  $args
17
     */
18
    public function __construct(
19
        protected QueryBuilder $queryBuilder,
20
        protected array $entityAliasMap,
21
        protected string $eventName,
22
        protected mixed $objectValue,
23
        protected array $args,
24
        protected mixed $context,
25
        protected ResolveInfo $info,
26
    ) {
27
    }
28
29
    public function eventName(): string
30
    {
31
        return $this->eventName;
32
    }
33
34
    public function getQueryBuilder(): QueryBuilder
35
    {
36
        return $this->queryBuilder;
37
    }
38
39
    /** @return string[] */
40
    public function getEntityAliasMap(): array
41
    {
42
        return $this->entityAliasMap;
43
    }
44
45
    public function getObjectValue(): mixed
46
    {
47
        return $this->objectValue;
48
    }
49
50
    /** @return mixed[] */
51
    public function getArgs(): array
52
    {
53
        return $this->args;
54
    }
55
56
    public function getContext(): mixed
57
    {
58
        return $this->context;
59
    }
60
61
    public function getInfo(): ResolveInfo
62
    {
63
        return $this->info;
64
    }
65
}
66