GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

EqualsProperty   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
wmc 2
lcom 1
cbo 2
dl 0
loc 26
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A modify() 0 8 1
1
<?php
2
3
namespace Rb\Specification\Doctrine\Condition;
4
5
use Doctrine\ORM\Query\Expr\Comparison as DoctrineComparison;
6
use Doctrine\ORM\QueryBuilder;
7
use InvalidArgumentException;
8
9
class EqualsProperty extends Comparison
10
{
11
    /**
12
     * @param string      $field
13
     * @param string      $field2
14
     * @param string|null $dqlAlias
15
     *
16
     * @throws InvalidArgumentException
17
     */
18
    public function __construct($field, $field2, $dqlAlias = null)
19
    {
20
        parent::__construct(self::EQ, $field, $field2, $dqlAlias);
21
    }
22
23
    /**
24
     * {@inheritdoc}
25
     */
26
    public function modify(QueryBuilder $queryBuilder, $dqlAlias)
27
    {
28
        return (string) new DoctrineComparison(
29
            $this->createPropertyWithAlias($dqlAlias),
30
            $this->operator,
31
            $this->createAliasedName($this->value, $dqlAlias)
32
        );
33
    }
34
}
35