-
Notifications
You must be signed in to change notification settings - Fork 7.8k
/
Copy pathtest.stub.php
158 lines (104 loc) · 3.91 KB
/
test.stub.php
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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
<?php
/** @generate-class-entries static */
namespace {
interface _ZendTestInterface
{
}
/** @alias _ZendTestClassAlias */
class _ZendTestClass implements _ZendTestInterface {
/** @var mixed */
public static $_StaticProp;
public static int $staticIntProp = 123;
public int $intProp = 123;
public ?stdClass $classProp = null;
public stdClass|Iterator|null $classUnionProp = null;
public readonly int $readonlyProp;
public static function is_object(): int {}
/**
* @deprecated
* @return string
*/
public function __toString() {}
public function returnsStatic(): static {}
public function returnsThrowable(): Throwable {}
static public function variadicTest(string|Iterator ...$elements) : static {}
}
class _ZendTestChildClass extends _ZendTestClass
{
public function returnsThrowable(): Exception {}
}
trait _ZendTestTrait {
/** @var mixed */
public $testProp;
public function testMethod(): bool {}
}
final class ZendTestAttribute {
}
final class ZendTestParameterAttribute {
public string $parameter;
public function __construct(string $parameter) {}
}
class ZendTestClassWithMethodWithParameterAttribute {
final public function no_override(string $parameter): int {}
public function override(string $parameter): int {}
}
class ZendTestChildClassWithMethodWithParameterAttribute extends ZendTestClassWithMethodWithParameterAttribute {
public function override(string $parameter): int {}
}
enum ZendTestUnitEnum {
case Foo;
case Bar;
}
enum ZendTestStringEnum: string {
case Foo = "Test1";
case Bar = "Test2";
case Baz = "Test2\\a";
case FortyTwo = "42";
}
function zend_test_array_return(): array {}
function zend_test_nullable_array_return(): ?array {}
function zend_test_void_return(): void {}
/** @deprecated */
function zend_test_deprecated(mixed $arg = null): void {}
function zend_create_unterminated_string(string $str): string {}
function zend_terminate_string(string &$str): void {}
function zend_leak_variable(mixed $variable): void {}
function zend_leak_bytes(int $bytes = 3): void {}
function zend_string_or_object(object|string $param): object|string {}
function zend_string_or_object_or_null(object|string|null $param): object|string|null {}
/** @param stdClass|string $param */
function zend_string_or_stdclass($param): stdClass|string {}
/** @param stdClass|string|null $param */
function zend_string_or_stdclass_or_null($param): stdClass|string|null {}
function zend_iterable(iterable $arg1, ?iterable $arg2 = null): void {}
function zend_weakmap_attach(object $object, mixed $value): bool {}
function zend_weakmap_remove(object $object): bool {}
function zend_weakmap_dump(): array {}
function zend_get_unit_enum(): ZendTestUnitEnum {}
function zend_test_parameter_with_attribute(string $parameter): int {}
function zend_get_current_func_name(): string {}
function zend_call_method(string $class, string $method, mixed $arg1 = UNKNOWN, mixed $arg2 = UNKNOWN): mixed {}
function zend_get_map_ptr_last(): int {}
function zend_test_crash(?string $message = null): void {}
#if defined(HAVE_LIBXML) && !defined(PHP_WIN32)
function zend_test_override_libxml_global_state(): void {}
#endif
function zend_test_is_pcre_bundled(): bool {}
}
namespace ZendTestNS {
class Foo {
public function method(): void {}
}
}
namespace ZendTestNS2 {
class Foo {
public ZendSubNS\Foo $foo;
public function method(): void {}
}
}
namespace ZendTestNS2\ZendSubNS {
class Foo {
public function method(): void {}
}
function namespaced_func(): bool {}
}