Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Completed
Pull Request — master (#638)
by Vincent
12:27
created

ExecutorArgumentsEvent::getStartTime()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
eloc 1
c 0
b 0
f 0
dl 0
loc 3
ccs 2
cts 2
cp 1
rs 10
cc 1
nc 1
nop 0
crap 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Overblog\GraphQLBundle\Event;
6
7
use Overblog\GraphQLBundle\Definition\Type\ExtensibleSchema;
8
use Symfony\Contracts\EventDispatcher\Event;
9
10
final class ExecutorArgumentsEvent extends Event
11
{
12
    /** @var ExtensibleSchema */
13
    private $schema;
14
15
    /** @var string */
16
    private $requestString;
17
18
    /** @var mixed */
19
    private $rootValue;
20
21
    /** @var \ArrayObject */
22
    private $contextValue;
23
24
    /** @var array|null */
25
    private $variableValue;
26
27
    /** @var string|null */
28
    private $operationName;
29
30
    /** @var float */
31
    private $startTime;
32
33 104
    public static function create(
34
            ExtensibleSchema $schema,
35
            $requestString,
36
            \ArrayObject $contextValue,
37
            $rootValue = null,
38
            array $variableValue = null,
39
            $operationName = null
40
        ) {
41 104
        $instance = new static();
42 104
        $instance->setSchema($schema);
43 104
        $instance->setRequestString($requestString);
44 104
        $instance->setContextValue($contextValue);
45 104
        $instance->setRootValue($rootValue);
46 104
        $instance->setVariableValue($variableValue);
47 104
        $instance->setOperationName($operationName);
48 104
        $instance->setStartTime(microtime(true));
49
50 104
        return $instance;
51
    }
52
53
    /**
54
     * @param string|null $operationName
55
     */
56 104
    public function setOperationName($operationName = null): void
57
    {
58 104
        $this->operationName = $operationName;
59 104
    }
60
61 104
    public function setContextValue(\ArrayObject $contextValue = null): void
62
    {
63 104
        $this->contextValue = $contextValue;
64 104
    }
65
66
    /**
67
     * @param mixed $rootValue
68
     */
69 104
    public function setRootValue($rootValue = null): void
70
    {
71 104
        $this->rootValue = $rootValue;
72 104
    }
73
74
    /**
75
     * @param string $requestString
76
     */
77 104
    public function setRequestString($requestString): void
78
    {
79 104
        $this->requestString = $requestString;
80 104
    }
81
82 104
    public function setVariableValue(array $variableValue = null): void
83
    {
84 104
        $this->variableValue = $variableValue;
85 104
    }
86
87 104
    public function setSchema(ExtensibleSchema $schema): void
88
    {
89 104
        $this->schema = $schema;
90 104
    }
91
92 104
    public function setStartTime(float $startTime): void
93
    {
94 104
        $this->startTime = $startTime;
95 104
    }
96
97
    /**
98
     * @return ExtensibleSchema
99
     */
100 103
    public function getSchema(): ExtensibleSchema
101
    {
102 103
        return $this->schema;
103
    }
104
105
    /**
106
     * @return string
107
     */
108 104
    public function getRequestString(): string
109
    {
110 104
        return $this->requestString;
111
    }
112
113
    /**
114
     * @return array|null
115
     */
116 103
    public function getRootValue()
117
    {
118 103
        return $this->rootValue;
119
    }
120
121
    /**
122
     * @return \ArrayObject
123
     */
124 103
    public function getContextValue(): \ArrayObject
125
    {
126 103
        return $this->contextValue;
127
    }
128
129
    /**
130
     * @return array|null
131
     */
132 104
    public function getVariableValue()
133
    {
134 104
        return $this->variableValue;
135
    }
136
137
    /**
138
     * @return string|null
139
     */
140 104
    public function getOperationName()
141
    {
142 104
        return $this->operationName;
143
    }
144
145
    /**
146
     * @return float|null
147
     */
148 104
    public function getStartTime()
149
    {
150 104
        return $this->startTime;
151
    }
152
}
153