forked from phpstan/phpstan-src
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFunctionReflection.php
More file actions
65 lines (44 loc) · 1.37 KB
/
Copy pathFunctionReflection.php
File metadata and controls
65 lines (44 loc) · 1.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<?php declare(strict_types = 1);
namespace PHPStan\Reflection;
use PHPStan\TrinaryLogic;
use PHPStan\Type\Type;
/** @api */
interface FunctionReflection
{
public function getName(): string;
public function getFileName(): ?string;
/**
* @return list<ExtendedParametersAcceptor>
*/
public function getVariants(): array;
/**
* @internal
*/
public function getOnlyVariant(): ExtendedParametersAcceptor;
/**
* @return list<ExtendedParametersAcceptor>|null
*/
public function getNamedArgumentsVariants(): ?array;
public function acceptsNamedArguments(): TrinaryLogic;
public function isDeprecated(): TrinaryLogic;
public function getDeprecatedDescription(): ?string;
public function isInternal(): TrinaryLogic;
public function getThrowType(): ?Type;
public function hasSideEffects(): TrinaryLogic;
public function isBuiltin(): bool;
public function getAsserts(): Assertions;
public function getDocComment(): ?string;
public function returnsByReference(): TrinaryLogic;
/**
* This indicates whether the function has phpstan-pure
* or phpstan-impure annotation above it.
*
* In most cases asking hasSideEffects() is much more practical
* as it also accounts for void return type (method being always impure).
*/
public function isPure(): TrinaryLogic;
/**
* @return list<AttributeReflection>
*/
public function getAttributes(): array;
}