@@ -181,7 +181,7 @@ discard block |
||
181 | 181 | * @since 5.5 |
182 | 182 | */ |
183 | 183 | #[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false|null")] |
184 | -function password_hash(string $password, string|int|null $algo, array $options = []) {} |
|
184 | +function password_hash(string $password, string | int | null $algo, array $options = []) {} |
|
185 | 185 | |
186 | 186 | /** |
187 | 187 | * Checks if the given hash matches the given options. |
@@ -192,7 +192,7 @@ discard block |
||
192 | 192 | * @return bool Returns TRUE if the hash should be rehashed to match the given algo and options, or FALSE otherwise. |
193 | 193 | * @since 5.5 |
194 | 194 | */ |
195 | -function password_needs_rehash(string $hash, string|int|null $algo, array $options = []): bool {} |
|
195 | +function password_needs_rehash(string $hash, string | int | null $algo, array $options = []): bool {} |
|
196 | 196 | |
197 | 197 | /** |
198 | 198 | * Checks if the given hash matches the given options. |
@@ -306,10 +306,10 @@ discard block |
||
306 | 306 | * @meta |
307 | 307 | */ |
308 | 308 | function array_intersect_ukey( |
309 | - array $array, |
|
310 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
311 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
312 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
309 | + array $array, |
|
310 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
311 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
312 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
313 | 313 | ): array {} |
314 | 314 | |
315 | 315 | /** |
@@ -336,10 +336,10 @@ discard block |
||
336 | 336 | * @meta |
337 | 337 | */ |
338 | 338 | function array_uintersect( |
339 | - array $array, |
|
340 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
341 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
342 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
339 | + array $array, |
|
340 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
341 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
342 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
343 | 343 | ): array {} |
344 | 344 | |
345 | 345 | /** |
@@ -378,10 +378,10 @@ discard block |
||
378 | 378 | * @meta |
379 | 379 | */ |
380 | 380 | function array_uintersect_assoc( |
381 | - array $array, |
|
382 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
383 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
384 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
381 | + array $array, |
|
382 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
383 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
384 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
385 | 385 | ): array {} |
386 | 386 | |
387 | 387 | /** |
@@ -402,10 +402,10 @@ discard block |
||
402 | 402 | * @meta |
403 | 403 | */ |
404 | 404 | function array_intersect_uassoc( |
405 | - array $array, |
|
406 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
407 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
408 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
405 | + array $array, |
|
406 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
407 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
408 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
409 | 409 | ): array {} |
410 | 410 | |
411 | 411 | /** |
@@ -434,11 +434,11 @@ discard block |
||
434 | 434 | */ |
435 | 435 | #[Pure] |
436 | 436 | function array_uintersect_uassoc( |
437 | - array $array, |
|
438 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
439 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
440 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
441 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
437 | + array $array, |
|
438 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
439 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
440 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
441 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
442 | 442 | ): array {} |
443 | 443 | |
444 | 444 | /** |
@@ -493,10 +493,10 @@ discard block |
||
493 | 493 | * @meta |
494 | 494 | */ |
495 | 495 | function array_diff_ukey( |
496 | - array $array, |
|
497 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
498 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
499 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest, |
|
496 | + array $array, |
|
497 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
498 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
499 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest, |
|
500 | 500 | ): array {} |
501 | 501 | |
502 | 502 | /** |
@@ -523,10 +523,10 @@ discard block |
||
523 | 523 | * @meta |
524 | 524 | */ |
525 | 525 | function array_udiff( |
526 | - array $array, |
|
527 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
528 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
529 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest, |
|
526 | + array $array, |
|
527 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
528 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
529 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest, |
|
530 | 530 | ): array {} |
531 | 531 | |
532 | 532 | /** |
@@ -544,9 +544,9 @@ discard block |
||
544 | 544 | */ |
545 | 545 | #[Pure] |
546 | 546 | function array_diff_assoc( |
547 | - array $array, |
|
548 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] $arrays, |
|
549 | - array ...$arrays |
|
547 | + array $array, |
|
548 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] $arrays, |
|
549 | + array ...$arrays |
|
550 | 550 | ): array {} |
551 | 551 | |
552 | 552 | /** |
@@ -580,10 +580,10 @@ discard block |
||
580 | 580 | * @meta |
581 | 581 | */ |
582 | 582 | function array_udiff_assoc( |
583 | - array $array, |
|
584 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
585 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
586 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest, |
|
583 | + array $array, |
|
584 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
585 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
586 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest, |
|
587 | 587 | ): array {} |
588 | 588 | |
589 | 589 | /** |
@@ -607,10 +607,10 @@ discard block |
||
607 | 607 | * @meta |
608 | 608 | */ |
609 | 609 | function array_diff_uassoc( |
610 | - array $array, |
|
611 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
612 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
613 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest, |
|
610 | + array $array, |
|
611 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
612 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
613 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest, |
|
614 | 614 | ): array {} |
615 | 615 | |
616 | 616 | /** |
@@ -651,11 +651,11 @@ discard block |
||
651 | 651 | * @meta |
652 | 652 | */ |
653 | 653 | function array_udiff_uassoc( |
654 | - array $array, |
|
655 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
656 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
657 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
658 | - #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
654 | + array $array, |
|
655 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] array $array2, |
|
656 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $data_compare_func, |
|
657 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] callable $key_compare_func, |
|
658 | + #[PhpStormStubsElementAvailable(from: '8.0')] ...$rest |
|
659 | 659 | ): array {} |
660 | 660 | |
661 | 661 | /** |
@@ -731,10 +731,10 @@ discard block |
||
731 | 731 | * @meta |
732 | 732 | */ |
733 | 733 | function array_map( |
734 | - ?callable $callback, |
|
735 | - #[PhpStormStubsElementAvailable(from: '8.0')] array $array, |
|
736 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] $arrays, |
|
737 | - array ...$arrays |
|
734 | + ?callable $callback, |
|
735 | + #[PhpStormStubsElementAvailable(from: '8.0')] array $array, |
|
736 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] $arrays, |
|
737 | + array ...$arrays |
|
738 | 738 | ): array {} |
739 | 739 | |
740 | 740 | /** |
@@ -874,8 +874,8 @@ discard block |
||
874 | 874 | * @return bool false if the assertion is false, true otherwise. |
875 | 875 | */ |
876 | 876 | function assert( |
877 | - mixed $assertion, |
|
878 | - #[LanguageLevelTypeAware(['8.0' => 'Throwable|string|null'], default: 'string')] $description = '' |
|
877 | + mixed $assertion, |
|
878 | + #[LanguageLevelTypeAware(['8.0' => 'Throwable|string|null'], default: 'string')] $description = '' |
|
879 | 879 | ): bool {} |
880 | 880 | |
881 | 881 | /** |
@@ -974,24 +974,24 @@ discard block |
||
974 | 974 | * by the operator, false otherwise. |
975 | 975 | */ |
976 | 976 | function version_compare( |
977 | - string $version1, |
|
978 | - string $version2, |
|
979 | - #[ExpectedValues(values: [ |
|
980 | - "<", |
|
981 | - "lt", |
|
982 | - "<=", |
|
983 | - "le", |
|
984 | - ">", |
|
985 | - "gt", |
|
986 | - ">=", |
|
987 | - "ge", |
|
988 | - "==", |
|
989 | - "=", |
|
990 | - "eq", |
|
991 | - "!=", |
|
992 | - "<>", |
|
993 | - "ne" |
|
994 | - ])] ?string $operator |
|
977 | + string $version1, |
|
978 | + string $version2, |
|
979 | + #[ExpectedValues(values: [ |
|
980 | + "<", |
|
981 | + "lt", |
|
982 | + "<=", |
|
983 | + "le", |
|
984 | + ">", |
|
985 | + "gt", |
|
986 | + ">=", |
|
987 | + "ge", |
|
988 | + "==", |
|
989 | + "=", |
|
990 | + "eq", |
|
991 | + "!=", |
|
992 | + "<>", |
|
993 | + "ne" |
|
994 | + ])] ?string $operator |
|
995 | 995 | ): int|bool {} |
996 | 996 | |
997 | 997 | /** |
@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | * @since 5.5 |
111 | 111 | */ |
112 | 112 | #[Pure] |
113 | -function array_column(array $array, string|int|null $column_key, string|int|null $index_key = null): array {} |
|
113 | +function array_column(array $array, string | int | null $column_key, string | int | null $index_key = null): array {} |
|
114 | 114 | |
115 | 115 | /** |
116 | 116 | * Return an array with elements in reverse order |
@@ -223,7 +223,7 @@ discard block |
||
223 | 223 | * of keys for the random entries. This is done so that you can pick |
224 | 224 | * random keys as well as values out of the array. |
225 | 225 | */ |
226 | -function array_rand(array $array, int $num = 1): array|string|int {} |
|
226 | +function array_rand(array $array, int $num = 1): array | string | int {} |
|
227 | 227 | |
228 | 228 | /** |
229 | 229 | * Removes duplicate values from an array |
@@ -667,7 +667,7 @@ discard block |
||
667 | 667 | * @return int|float the sum of values as an integer or float. |
668 | 668 | */ |
669 | 669 | #[Pure] |
670 | -function array_sum(array $array): int|float {} |
|
670 | +function array_sum(array $array): int | float {} |
|
671 | 671 | |
672 | 672 | /** |
673 | 673 | * Calculate the product of values in an array |
@@ -678,7 +678,7 @@ discard block |
||
678 | 678 | * @return int|float the product as an integer or float. |
679 | 679 | */ |
680 | 680 | #[Pure] |
681 | -function array_product(array $array): int|float {} |
|
681 | +function array_product(array $array): int | float {} |
|
682 | 682 | |
683 | 683 | /** |
684 | 684 | * Iterates over each value in the <b>array</b> |
@@ -732,8 +732,8 @@ discard block |
||
732 | 732 | */ |
733 | 733 | function array_map( |
734 | 734 | ?callable $callback, |
735 | - #[PhpStormStubsElementAvailable(from: '8.0')] array $array, |
|
736 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] $arrays, |
|
735 | + #[PhpStormStubsElementAvailable(from : '8.0')] array $array, |
|
736 | + #[PhpStormStubsElementAvailable(from : '5.3', to : '7.4')] $arrays, |
|
737 | 737 | array ...$arrays |
738 | 738 | ): array {} |
739 | 739 | |
@@ -771,7 +771,7 @@ discard block |
||
771 | 771 | * @meta |
772 | 772 | */ |
773 | 773 | #[Pure] |
774 | -#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")] |
|
774 | +#[LanguageLevelTypeAware(["8.0" => "array"], default : "array|false")] |
|
775 | 775 | function array_combine(array $keys, array $values) {} |
776 | 776 | |
777 | 777 | /** |
@@ -786,7 +786,7 @@ discard block |
||
786 | 786 | * @return bool true on success or false on failure. |
787 | 787 | */ |
788 | 788 | #[Pure] |
789 | -function array_key_exists($key, #[LanguageLevelTypeAware(["8.0" => "array"], default: "array|ArrayObject")] $array): bool {} |
|
789 | +function array_key_exists($key, #[LanguageLevelTypeAware(["8.0" => "array"], default : "array|ArrayObject")] $array): bool {} |
|
790 | 790 | |
791 | 791 | /** |
792 | 792 | * Gets the first key of an array |
@@ -799,7 +799,7 @@ discard block |
||
799 | 799 | * @since 7.3 |
800 | 800 | */ |
801 | 801 | #[Pure] |
802 | -function array_key_first(array $array): string|int|null {} |
|
802 | +function array_key_first(array $array): string | int | null {} |
|
803 | 803 | |
804 | 804 | /** |
805 | 805 | * Gets the last key of an array |
@@ -812,7 +812,7 @@ discard block |
||
812 | 812 | * @since 7.3 |
813 | 813 | */ |
814 | 814 | #[Pure] |
815 | -function array_key_last(array $array): string|int|null {} |
|
815 | +function array_key_last(array $array): string | int | null {} |
|
816 | 816 | |
817 | 817 | /** |
818 | 818 | * @link https://secure.php.net/array_is_list |
@@ -832,7 +832,7 @@ discard block |
||
832 | 832 | * @return mixed |
833 | 833 | */ |
834 | 834 | #[Pure] |
835 | -function pos(object|array $array): mixed {} |
|
835 | +function pos(object | array $array): mixed {} |
|
836 | 836 | |
837 | 837 | /** |
838 | 838 | * Alias: |
@@ -843,7 +843,7 @@ discard block |
||
843 | 843 | * @return int |
844 | 844 | */ |
845 | 845 | #[Pure] |
846 | -function sizeof(Countable|array $value, int $mode = COUNT_NORMAL): int {} |
|
846 | +function sizeof(Countable | array $value, int $mode = COUNT_NORMAL): int {} |
|
847 | 847 | |
848 | 848 | /** |
849 | 849 | * Checks if the given key or index exists in the array. The name of this function is array_key_exists() in PHP > 4.0.6. |
@@ -875,7 +875,7 @@ discard block |
||
875 | 875 | */ |
876 | 876 | function assert( |
877 | 877 | mixed $assertion, |
878 | - #[LanguageLevelTypeAware(['8.0' => 'Throwable|string|null'], default: 'string')] $description = '' |
|
878 | + #[LanguageLevelTypeAware(['8.0' => 'Throwable|string|null'], default : 'string')] $description = '' |
|
879 | 879 | ): bool {} |
880 | 880 | |
881 | 881 | /** |
@@ -976,7 +976,7 @@ discard block |
||
976 | 976 | function version_compare( |
977 | 977 | string $version1, |
978 | 978 | string $version2, |
979 | - #[ExpectedValues(values: [ |
|
979 | + #[ExpectedValues(values : [ |
|
980 | 980 | "<", |
981 | 981 | "lt", |
982 | 982 | "<=", |
@@ -992,7 +992,7 @@ discard block |
||
992 | 992 | "<>", |
993 | 993 | "ne" |
994 | 994 | ])] ?string $operator |
995 | -): int|bool {} |
|
995 | +): int | bool {} |
|
996 | 996 | |
997 | 997 | /** |
998 | 998 | * Convert a pathname and a project identifier to a System V IPC key |
@@ -31,11 +31,11 @@ |
||
31 | 31 | * @see unpack() |
32 | 32 | * @since 5.4 |
33 | 33 | */ |
34 | -function hex2bin(string $string): string|false {}; |
|
34 | +function hex2bin(string $string): string | false {}; |
|
35 | 35 | |
36 | 36 | /** |
37 | 37 | * Get or Set the HTTP response code |
38 | 38 | * @param int $response_code [optional] The optional response_code will set the response code. |
39 | 39 | * @return int|bool The current response code. By default the return value is int(200). |
40 | 40 | */ |
41 | -function http_response_code(int $response_code): int|bool {} |
|
41 | +function http_response_code(int $response_code): int | bool {} |
@@ -734,9 +734,9 @@ discard block |
||
734 | 734 | */ |
735 | 735 | #[Pure] |
736 | 736 | function min( |
737 | - #[PhpStormStubsElementAvailable(from: '8.0')] mixed $value, |
|
738 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] mixed $values, |
|
739 | - mixed ...$values |
|
737 | + #[PhpStormStubsElementAvailable(from: '8.0')] mixed $value, |
|
738 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] mixed $values, |
|
739 | + mixed ...$values |
|
740 | 740 | ): mixed {} |
741 | 741 | |
742 | 742 | /** |
@@ -749,9 +749,9 @@ discard block |
||
749 | 749 | */ |
750 | 750 | #[Pure] |
751 | 751 | function max( |
752 | - #[PhpStormStubsElementAvailable(from: '8.0')] mixed $value, |
|
753 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] mixed $values, |
|
754 | - mixed ...$values |
|
752 | + #[PhpStormStubsElementAvailable(from: '8.0')] mixed $value, |
|
753 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] mixed $values, |
|
754 | + mixed ...$values |
|
755 | 755 | ): mixed {} |
756 | 756 | |
757 | 757 | /** |
@@ -837,17 +837,17 @@ discard block |
||
837 | 837 | * table. |
838 | 838 | */ |
839 | 839 | function extract( |
840 | - array &$array, |
|
841 | - #[ExpectedValues(flags: [ |
|
842 | - EXTR_OVERWRITE, |
|
843 | - EXTR_SKIP, |
|
844 | - EXTR_PREFIX_SAME, |
|
845 | - EXTR_PREFIX_ALL, |
|
846 | - EXTR_PREFIX_INVALID, |
|
847 | - EXTR_PREFIX_IF_EXISTS, |
|
848 | - EXTR_REFS |
|
849 | - ])] int $flags, |
|
850 | - string $prefix |
|
840 | + array &$array, |
|
841 | + #[ExpectedValues(flags: [ |
|
842 | + EXTR_OVERWRITE, |
|
843 | + EXTR_SKIP, |
|
844 | + EXTR_PREFIX_SAME, |
|
845 | + EXTR_PREFIX_ALL, |
|
846 | + EXTR_PREFIX_INVALID, |
|
847 | + EXTR_PREFIX_IF_EXISTS, |
|
848 | + EXTR_REFS |
|
849 | + ])] int $flags, |
|
850 | + string $prefix |
|
851 | 851 | ): int {} |
852 | 852 | |
853 | 853 | /** |
@@ -934,10 +934,10 @@ discard block |
||
934 | 934 | * @return bool true on success or false on failure. |
935 | 935 | */ |
936 | 936 | function array_multisort( |
937 | - &$array, |
|
938 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] $sort_order = SORT_ASC, |
|
939 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] $sort_flags = SORT_REGULAR, |
|
940 | - &...$rest |
|
937 | + &$array, |
|
938 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] $sort_order = SORT_ASC, |
|
939 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.4')] $sort_flags = SORT_REGULAR, |
|
940 | + &...$rest |
|
941 | 941 | ): bool {} |
942 | 942 | |
943 | 943 | /** |
@@ -954,9 +954,9 @@ discard block |
||
954 | 954 | * @return int the number of elements in the array. |
955 | 955 | */ |
956 | 956 | function array_push( |
957 | - array &$array, |
|
958 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.2')] $values, |
|
959 | - mixed ...$values |
|
957 | + array &$array, |
|
958 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.2')] $values, |
|
959 | + mixed ...$values |
|
960 | 960 | ): int {} |
961 | 961 | |
962 | 962 | /** |
@@ -1089,6 +1089,6 @@ discard block |
||
1089 | 1089 | */ |
1090 | 1090 | #[Pure] |
1091 | 1091 | function array_merge( |
1092 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.3')] $array, |
|
1093 | - array ...$arrays |
|
1092 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.3')] $array, |
|
1093 | + array ...$arrays |
|
1094 | 1094 | ): array {} |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | * @link https://secure.php.net/manual/en/function.getimagesizefromstring.php |
100 | 100 | * @since 5.4 |
101 | 101 | */ |
102 | -function getimagesizefromstring(string $string, &$image_info): array|false {} |
|
102 | +function getimagesizefromstring(string $string, &$image_info): array | false {} |
|
103 | 103 | |
104 | 104 | /** |
105 | 105 | * Set the stream chunk size. |
@@ -143,7 +143,7 @@ discard block |
||
143 | 143 | */ |
144 | 144 | #[Pure] |
145 | 145 | #[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")] |
146 | -function metaphone(string $string, int $max_phonemes = 0): false|string {} |
|
146 | +function metaphone(string $string, int $max_phonemes = 0): false | string {} |
|
147 | 147 | |
148 | 148 | /** |
149 | 149 | * Turn on output buffering |
@@ -249,7 +249,7 @@ discard block |
||
249 | 249 | * @link https://php.net/manual/en/function.ob-get-flush.php |
250 | 250 | * @return string|false the output buffer or false if no buffering is active. |
251 | 251 | */ |
252 | -function ob_get_flush(): string|false {} |
|
252 | +function ob_get_flush(): string | false {} |
|
253 | 253 | |
254 | 254 | /** |
255 | 255 | * Get current buffer contents and delete current output buffer |
@@ -257,7 +257,7 @@ discard block |
||
257 | 257 | * @return string|false the contents of the output buffer and end output buffering. |
258 | 258 | * If output buffering isn't active then false is returned. |
259 | 259 | */ |
260 | -function ob_get_clean(): string|false {} |
|
260 | +function ob_get_clean(): string | false {} |
|
261 | 261 | |
262 | 262 | /** |
263 | 263 | * Return the length of the output buffer |
@@ -265,7 +265,7 @@ discard block |
||
265 | 265 | * @return int|false the length of the output buffer contents or false if no |
266 | 266 | * buffering is active. |
267 | 267 | */ |
268 | -function ob_get_length(): int|false {} |
|
268 | +function ob_get_length(): int | false {} |
|
269 | 269 | |
270 | 270 | /** |
271 | 271 | * Return the nesting level of the output buffering mechanism |
@@ -353,7 +353,7 @@ discard block |
||
353 | 353 | * buffering isn't active. |
354 | 354 | */ |
355 | 355 | #[Pure(true)] |
356 | -function ob_get_contents(): string|false {} |
|
356 | +function ob_get_contents(): string | false {} |
|
357 | 357 | |
358 | 358 | /** |
359 | 359 | * Turn implicit flush on/off |
@@ -582,7 +582,7 @@ discard block |
||
582 | 582 | * </p> |
583 | 583 | * @return bool true on success or false on failure. |
584 | 584 | */ |
585 | -function array_walk(object|array &$array, callable $callback, mixed $arg): bool {} |
|
585 | +function array_walk(object | array &$array, callable $callback, mixed $arg): bool {} |
|
586 | 586 | |
587 | 587 | /** |
588 | 588 | * Apply a user function recursively to every member of an array |
@@ -610,7 +610,7 @@ discard block |
||
610 | 610 | * </p> |
611 | 611 | * @return bool true on success or false on failure. |
612 | 612 | */ |
613 | -function array_walk_recursive(object|array &$array, callable $callback, mixed $arg): bool {} |
|
613 | +function array_walk_recursive(object | array &$array, callable $callback, mixed $arg): bool {} |
|
614 | 614 | |
615 | 615 | /** |
616 | 616 | * Counts all elements in an array, or something in an object. |
@@ -640,7 +640,7 @@ discard block |
||
640 | 640 | * </p> |
641 | 641 | */ |
642 | 642 | #[Pure] |
643 | -function count(Countable|array $value, int $mode = COUNT_NORMAL): int {} |
|
643 | +function count(Countable | array $value, int $mode = COUNT_NORMAL): int {} |
|
644 | 644 | |
645 | 645 | /** |
646 | 646 | * Set the internal pointer of an array to its last element |
@@ -654,7 +654,7 @@ discard block |
||
654 | 654 | * @return mixed|false the value of the last element or false for empty array. |
655 | 655 | * @meta |
656 | 656 | */ |
657 | -function end(object|array &$array): mixed {} |
|
657 | +function end(object | array &$array): mixed {} |
|
658 | 658 | |
659 | 659 | /** |
660 | 660 | * Rewind the internal array pointer |
@@ -667,7 +667,7 @@ discard block |
||
667 | 667 | * elements. |
668 | 668 | * @meta |
669 | 669 | */ |
670 | -function prev(object|array &$array): mixed {} |
|
670 | +function prev(object | array &$array): mixed {} |
|
671 | 671 | |
672 | 672 | /** |
673 | 673 | * Advance the internal array pointer of an array |
@@ -679,7 +679,7 @@ discard block |
||
679 | 679 | * internal array pointer, or false if there are no more elements. |
680 | 680 | * @meta |
681 | 681 | */ |
682 | -function next(object|array &$array): mixed {} |
|
682 | +function next(object | array &$array): mixed {} |
|
683 | 683 | |
684 | 684 | /** |
685 | 685 | * Set the internal pointer of an array to its first element |
@@ -691,7 +691,7 @@ discard block |
||
691 | 691 | * empty. |
692 | 692 | * @meta |
693 | 693 | */ |
694 | -function reset(object|array &$array): mixed {} |
|
694 | +function reset(object | array &$array): mixed {} |
|
695 | 695 | |
696 | 696 | /** |
697 | 697 | * Return the current element in an array |
@@ -707,7 +707,7 @@ discard block |
||
707 | 707 | * @meta |
708 | 708 | */ |
709 | 709 | #[Pure] |
710 | -function current(object|array $array): mixed {} |
|
710 | +function current(object | array $array): mixed {} |
|
711 | 711 | |
712 | 712 | /** |
713 | 713 | * Fetch a key from an array |
@@ -722,7 +722,7 @@ discard block |
||
722 | 722 | * empty, key returns null. |
723 | 723 | */ |
724 | 724 | #[Pure] |
725 | -function key(object|array $array): string|int|null {} |
|
725 | +function key(object | array $array): string | int | null {} |
|
726 | 726 | |
727 | 727 | /** |
728 | 728 | * Find lowest value |
@@ -808,7 +808,7 @@ discard block |
||
808 | 808 | * search_value parameter instead. |
809 | 809 | */ |
810 | 810 | #[Pure] |
811 | -function array_search(mixed $needle, array $haystack, bool $strict = false): string|int|false {} |
|
811 | +function array_search(mixed $needle, array $haystack, bool $strict = false): string | int | false {} |
|
812 | 812 | |
813 | 813 | /** |
814 | 814 | * Import variables into the current symbol table from an array |
@@ -918,7 +918,7 @@ discard block |
||
918 | 918 | * end, inclusive. |
919 | 919 | */ |
920 | 920 | #[Pure] |
921 | -function range($start, $end, int|float $step = 1): array {} |
|
921 | +function range($start, $end, int | float $step = 1): array {} |
|
922 | 922 | |
923 | 923 | /** |
924 | 924 | * Sort multiple or multi-dimensional arrays |
@@ -1089,6 +1089,6 @@ discard block |
||
1089 | 1089 | */ |
1090 | 1090 | #[Pure] |
1091 | 1091 | function array_merge( |
1092 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.3')] $array, |
|
1092 | + #[PhpStormStubsElementAvailable(from : '5.3', to : '7.3')] $array, |
|
1093 | 1093 | array ...$arrays |
1094 | 1094 | ): array {} |
@@ -102,7 +102,7 @@ |
||
102 | 102 | */ |
103 | 103 | #[Pure] |
104 | 104 | #[ExpectedValues([ |
105 | - "boolean", "integer", "double", "string", "array", "object", "resource", "NULL", "unknown type", "resource (closed)" |
|
105 | + "boolean", "integer", "double", "string", "array", "object", "resource", "NULL", "unknown type", "resource (closed)" |
|
106 | 106 | ])] |
107 | 107 | function gettype(mixed $value): string {} |
108 | 108 |
@@ -401,7 +401,7 @@ discard block |
||
401 | 401 | * </p> |
402 | 402 | * @return false|int the number of bytes read from the file, or FALSE on failure |
403 | 403 | */ |
404 | -function readfile(string $filename, bool $use_include_path = false, $context): int|false {} |
|
404 | +function readfile(string $filename, bool $use_include_path = false, $context): int | false {} |
|
405 | 405 | |
406 | 406 | /** |
407 | 407 | * Rewind the position of a file pointer |
@@ -464,7 +464,7 @@ discard block |
||
464 | 464 | * @return string|false a string containing a single character read from the file pointed |
465 | 465 | * to by handle. Returns false on EOF. |
466 | 466 | */ |
467 | -function fgetc($stream): string|false {} |
|
467 | +function fgetc($stream): string | false {} |
|
468 | 468 | |
469 | 469 | /** |
470 | 470 | * Gets line from file pointer |
@@ -488,7 +488,7 @@ discard block |
||
488 | 488 | * <p> |
489 | 489 | * If an error occurs, returns false. |
490 | 490 | */ |
491 | -function fgets($stream, ?int $length): string|false {} |
|
491 | +function fgets($stream, ?int $length): string | false {} |
|
492 | 492 | |
493 | 493 | /** |
494 | 494 | * Gets line from file pointer and strip HTML tags |
@@ -509,8 +509,8 @@ discard block |
||
509 | 509 | * If an error occurs, returns false. |
510 | 510 | * @removed 8.0 |
511 | 511 | */ |
512 | -#[Deprecated(since: '7.3')] |
|
513 | -function fgetss($handle, ?int $length = null, $allowable_tags = null): false|string {} |
|
512 | +#[Deprecated(since : '7.3')] |
|
513 | +function fgetss($handle, ?int $length = null, $allowable_tags = null): false | string {} |
|
514 | 514 | |
515 | 515 | /** |
516 | 516 | * Binary-safe file read |
@@ -521,7 +521,7 @@ discard block |
||
521 | 521 | * </p> |
522 | 522 | * @return string|false the read string or false on failure. |
523 | 523 | */ |
524 | -function fread($stream, int $length): string|false {} |
|
524 | +function fread($stream, int $length): string | false {} |
|
525 | 525 | |
526 | 526 | /** |
527 | 527 | * Opens file or URL |
@@ -715,7 +715,7 @@ discard block |
||
715 | 715 | * the number of characters read from handle |
716 | 716 | * and passed through to the output. |
717 | 717 | */ |
718 | -#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")] |
|
718 | +#[LanguageLevelTypeAware(["8.0" => "int"], default : "int|false")] |
|
719 | 719 | function fpassthru($stream) {} |
720 | 720 | |
721 | 721 | /** |
@@ -750,7 +750,7 @@ discard block |
||
750 | 750 | * is described in detail on the stat manual page. |
751 | 751 | */ |
752 | 752 | #[Pure(true)] |
753 | -function fstat($stream): array|false {} |
|
753 | +function fstat($stream): array | false {} |
|
754 | 754 | |
755 | 755 | /** |
756 | 756 | * Seeks on a file pointer |
@@ -796,7 +796,7 @@ discard block |
||
796 | 796 | * If an error occurs, returns false. |
797 | 797 | */ |
798 | 798 | #[Pure(true)] |
799 | -function ftell($stream): int|false {} |
|
799 | +function ftell($stream): int | false {} |
|
800 | 800 | |
801 | 801 | /** |
802 | 802 | * Flushes the output to a file |
@@ -841,7 +841,7 @@ discard block |
||
841 | 841 | * </p> |
842 | 842 | * @return int|false the number of bytes written, or <b>FALSE</b> on error. |
843 | 843 | */ |
844 | -function fwrite($stream, string $data, ?int $length): int|false {} |
|
844 | +function fwrite($stream, string $data, ?int $length): int | false {} |
|
845 | 845 | |
846 | 846 | /** |
847 | 847 | * Alias: |
@@ -867,7 +867,7 @@ discard block |
||
867 | 867 | * @link https://php.net/manual/en/function.fputs.php |
868 | 868 | * Binary-safe file write |
869 | 869 | */ |
870 | -function fputs($stream, string $data, ?int $length): int|false {} |
|
870 | +function fputs($stream, string $data, ?int $length): int | false {} |
|
871 | 871 | |
872 | 872 | /** |
873 | 873 | * Attempts to create the directory specified by pathname. |
@@ -950,7 +950,7 @@ discard block |
||
950 | 950 | * @return string|false the new temporary filename, or false on |
951 | 951 | * failure. |
952 | 952 | */ |
953 | -function tempnam(string $directory, string $prefix): string|false {} |
|
953 | +function tempnam(string $directory, string $prefix): string | false {} |
|
954 | 954 | |
955 | 955 | /** |
956 | 956 | * Creates a temporary file |
@@ -986,7 +986,7 @@ discard block |
||
986 | 986 | * </p> |
987 | 987 | */ |
988 | 988 | #[Pure(true)] |
989 | -function file(string $filename, int $flags, $context): array|false {} |
|
989 | +function file(string $filename, int $flags, $context): array | false {} |
|
990 | 990 | |
991 | 991 | /** |
992 | 992 | * Reads entire file into a string |
@@ -1013,7 +1013,7 @@ discard block |
||
1013 | 1013 | * @return string|false The function returns the read data or false on failure. |
1014 | 1014 | */ |
1015 | 1015 | #[Pure(true)] |
1016 | -function file_get_contents(string $filename, bool $use_include_path = false, $context, int $offset = 0, ?int $length): string|false {} |
|
1016 | +function file_get_contents(string $filename, bool $use_include_path = false, $context, int $offset = 0, ?int $length): string | false {} |
|
1017 | 1017 | |
1018 | 1018 | /** |
1019 | 1019 | * Write a string to a file |
@@ -1086,4 +1086,4 @@ discard block |
||
1086 | 1086 | * @return int|false The function returns the number of bytes that were written to the file, or |
1087 | 1087 | * false on failure. |
1088 | 1088 | */ |
1089 | -function file_put_contents(string $filename, mixed $data, int $flags = 0, $context): int|false {} |
|
1089 | +function file_put_contents(string $filename, mixed $data, int $flags = 0, $context): int | false {} |
@@ -1,405 +1,405 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | 3 | namespace { |
4 | - use JetBrains\PhpStorm\Internal\LanguageLevelTypeAware; |
|
5 | - |
|
6 | - /** |
|
7 | - * Creates an array. |
|
8 | - * @link https://php.net/manual/en/function.array.php |
|
9 | - * @param mixed ...$_ [optional] <p> |
|
10 | - * Syntax "index => values", separated by commas, define index and values. |
|
11 | - * index may be of type string or integer. When index is omitted, an integer index is automatically generated, |
|
12 | - * starting at 0. If index is an integer, next generated index will be the biggest integer index + 1. |
|
13 | - * Note that when two identical index are defined, the last overwrite the first. |
|
14 | - * </p> |
|
15 | - * <p> |
|
16 | - * Having a trailing comma after the last defined array entry, while unusual, is a valid syntax. |
|
17 | - * </p> |
|
18 | - * @return array an array of the parameters. The parameters can be given an index with the => operator. |
|
19 | - */ |
|
20 | - function PS_UNRESERVE_PREFIX_array(...$_) {} |
|
21 | - |
|
22 | - /** |
|
23 | - * Assigns a list of variables in one operation. |
|
24 | - * @link https://php.net/manual/en/function.list.php |
|
25 | - * @param mixed $var1 <p>A variable.</p> |
|
26 | - * @param mixed ...$_ [optional] <p>Another variable ...</p> |
|
27 | - * @return array the assigned array. |
|
28 | - */ |
|
29 | - function PS_UNRESERVE_PREFIX_list($var1, ...$_) {} |
|
30 | - |
|
31 | - /** |
|
32 | - * <p>Terminates execution of the script. Shutdown functions and object destructors will always be executed even if exit is called.</p> |
|
33 | - * <p>die is a language construct and it can be called without parentheses if no status is passed.</p> |
|
34 | - * @link https://php.net/manual/en/function.die.php |
|
35 | - * @param int|string $status [optional] <p> |
|
36 | - * If status is a string, this function prints the status just before exiting. |
|
37 | - * </p> |
|
38 | - * <p> |
|
39 | - * If status is an integer, that value will be used as the exit status and not printed. Exit statuses should be in the range 0 to 254, |
|
40 | - * the exit status 255 is reserved by PHP and shall not be used. The status 0 is used to terminate the program successfully. |
|
41 | - * </p> |
|
42 | - * <p> |
|
43 | - * Note: PHP >= 4.2.0 does NOT print the status if it is an integer. |
|
44 | - * </p> |
|
45 | - * @return void |
|
46 | - */ |
|
47 | - function PS_UNRESERVE_PREFIX_die($status = "") {} |
|
48 | - |
|
49 | - /** |
|
50 | - * <p>Terminates execution of the script. Shutdown functions and object destructors will always be executed even if exit is called.</p> |
|
51 | - * <p>exit is a language construct and it can be called without parentheses if no status is passed.</p> |
|
52 | - * @link https://php.net/manual/en/function.exit.php |
|
53 | - * @param int|string $status [optional] <p> |
|
54 | - * If status is a string, this function prints the status just before exiting. |
|
55 | - * </p> |
|
56 | - * <p> |
|
57 | - * If status is an integer, that value will be used as the exit status and not printed. Exit statuses should be in the range 0 to 254, |
|
58 | - * the exit status 255 is reserved by PHP and shall not be used. The status 0 is used to terminate the program successfully. |
|
59 | - * </p> |
|
60 | - * <p> |
|
61 | - * Note: PHP >= 4.2.0 does NOT print the status if it is an integer. |
|
62 | - * </p> |
|
63 | - * @return void |
|
64 | - */ |
|
65 | - function PS_UNRESERVE_PREFIX_exit($status = "") {} |
|
66 | - |
|
67 | - /** |
|
68 | - * Determine whether a variable is considered to be empty. A variable is considered empty if it does not exist or if its value |
|
69 | - * equals <b>FALSE</b>. <b>empty()</b> does not generate a warning if the variable does not exist. |
|
70 | - * @link https://php.net/manual/en/function.empty.php |
|
71 | - * @param mixed $var <p>Variable to be checked.</p> |
|
72 | - * <p>Note: Prior to PHP 5.5, <b>empty()</b> only supports variables; anything else will result in a parse error. In other words, |
|
73 | - * the following will not work: <b>empty(trim($name))</b>. Instead, use <b>trim($name) == false</b>. |
|
74 | - * </p> |
|
75 | - * <p> |
|
76 | - * No warning is generated if the variable does not exist. That means <b>empty()</b> is essentially the concise equivalent |
|
77 | - * to <b>!isset($var) || $var == false</b>. |
|
78 | - * </p> |
|
79 | - * @return bool <p><b>FALSE</b> if var exists and has a non-empty, non-zero value. Otherwise returns <b>TRUE</b>.<p> |
|
80 | - * <p> |
|
81 | - * The following things are considered to be empty: |
|
82 | - * <ul> |
|
83 | - * <li>"" (an empty string)</li> |
|
84 | - * <li>0 (0 as an integer)</li> |
|
85 | - * <li>0.0 (0 as a float)</li> |
|
86 | - * <li>"0" (0 as a string)</li> |
|
87 | - * <li><b>NULL</b></li> |
|
88 | - * <li><b>FALSE</b></li> |
|
89 | - * <li>array() (an empty array)</li> |
|
90 | - * <li>$var; (a variable declared, but without a value)</li> |
|
91 | - * </ul> |
|
92 | - * </p> |
|
93 | - */ |
|
94 | - function PS_UNRESERVE_PREFIX_empty($var) {} |
|
95 | - |
|
96 | - /** |
|
97 | - * <p>Determine if a variable is set and is not <b>NULL</b>.</p> |
|
98 | - * <p>If a variable has been unset with unset(), it will no longer be set. <b>isset()</b> will return <b>FALSE</b> if testing a variable |
|
99 | - * that has been set to <b>NULL</b>. Also note that a null character ("\0") is not equivalent to the PHP <b>NULL</b> constant.</p> |
|
100 | - * <p>If multiple parameters are supplied then <b>isset()</b> will return <b>TRUE</b> only if all of the parameters are set. |
|
101 | - * Evaluation goes from left to right and stops as soon as an unset variable is encountered.</p> |
|
102 | - * @link https://php.net/manual/en/function.isset.php |
|
103 | - * @param mixed $var <p>The variable to be checked.</p> |
|
104 | - * @param mixed ...$_ [optional] <p>Another variable ...</p> |
|
105 | - * @return bool Returns <b>TRUE</b> if var exists and has value other than <b>NULL</b>, <b>FALSE</b> otherwise. |
|
106 | - */ |
|
107 | - function PS_UNRESERVE_PREFIX_isset($var, ...$_) {} |
|
108 | - |
|
109 | - /** |
|
110 | - * <p>Destroys the specified variables.</p> |
|
111 | - * <p>The behavior of <b>unset()</b> inside of a function can vary depending on what type of variable you are attempting to destroy.</p> |
|
112 | - * @link https://php.net/manual/en/function.unset.php |
|
113 | - * @param mixed $var <p>The variable to be unset.</p> |
|
114 | - * @param mixed ...$_ [optional] <p>Another variable ...</p> |
|
115 | - * @return void |
|
116 | - */ |
|
117 | - function PS_UNRESERVE_PREFIX_unset($var, ...$_) {} |
|
118 | - |
|
119 | - /** |
|
120 | - * <p>Evaluates the given code as PHP.</p> |
|
121 | - * <p>Caution: The <b>eval()</b> language construct is very dangerous because it allows execution of arbitrary PHP code. Its use thus is |
|
122 | - * discouraged. If you have carefully verified that there is no other option than to use this construct, pay special attention not to |
|
123 | - * pass any user provided data into it without properly validating it beforehand.</p> |
|
124 | - * @link https://php.net/manual/en/function.eval.php |
|
125 | - * @param string $code <p> |
|
126 | - * Valid PHP code to be evaluated. |
|
127 | - * </p> |
|
128 | - * <p> |
|
129 | - * The code must not be wrapped in opening and closing PHP tags, i.e. 'echo "Hi!";' must be passed instead of '<?php echo "Hi!"; ?>'. |
|
130 | - * It is still possible to leave and re-enter PHP mode though using the appropriate PHP tags, e.g. |
|
131 | - * 'echo "In PHP mode!"; ?>In HTML mode!<?php echo "Back in PHP mode!";'. |
|
132 | - * </p> |
|
133 | - * <p> |
|
134 | - * Apart from that the passed code must be valid PHP. This includes that all statements must be properly terminated using a semicolon. |
|
135 | - * 'echo "Hi!"' for example will cause a parse error, whereas 'echo "Hi!";' will work. |
|
136 | - * </p> |
|
137 | - * <p> |
|
138 | - * A return statement will immediately terminate the evaluation of the code. |
|
139 | - * </p> |
|
140 | - * <p> |
|
141 | - * The code will be executed in the scope of the code calling <b>eval()</b>. Thus any variables defined or changed in the <b>eval()</b> |
|
142 | - * call will remain visible after it terminates. |
|
143 | - * </p> |
|
144 | - * @return mixed <b>NULL</b> unless return is called in the evaluated code, in which case the value passed to return is returned. |
|
145 | - * As of PHP 7, if there is a parse error in the evaluated code, <b>eval()</b> throws a ParseError exception. Before PHP 7, in this |
|
146 | - * case <b>eval()</b> returned <b>FALSE</b> and execution of the following code continued normally. It is not possible to catch a parse |
|
147 | - * error in <b>eval()</b> using set_error_handler(). |
|
148 | - */ |
|
149 | - function PS_UNRESERVE_PREFIX_eval($code) {} |
|
150 | - |
|
151 | - /** |
|
152 | - * Generator objects are returned from generators, cannot be instantiated via new. |
|
153 | - * @link https://secure.php.net/manual/en/class.generator.php |
|
154 | - * @link https://wiki.php.net/rfc/generators |
|
155 | - */ |
|
156 | - final class Generator implements Iterator |
|
157 | - { |
|
158 | - /** |
|
159 | - * Throws an exception if the generator is currently after the first yield. |
|
160 | - * @return void |
|
161 | - */ |
|
162 | - public function rewind(): void {} |
|
163 | - |
|
164 | - /** |
|
165 | - * Returns false if the generator has been closed, true otherwise. |
|
166 | - * @return bool |
|
167 | - */ |
|
168 | - public function valid(): bool {} |
|
169 | - |
|
170 | - /** |
|
171 | - * Returns whatever was passed to yield or null if nothing was passed or the generator is already closed. |
|
172 | - * @return mixed |
|
173 | - */ |
|
174 | - public function current(): mixed {} |
|
175 | - |
|
176 | - /** |
|
177 | - * Returns the yielded key or, if none was specified, an auto-incrementing key or null if the generator is already closed. |
|
178 | - * @return string|float|int|bool|null |
|
179 | - */ |
|
180 | - #[LanguageLevelTypeAware(['8.0' => 'mixed'], default: 'string|float|int|bool|null')] |
|
181 | - public function key() {} |
|
182 | - |
|
183 | - /** |
|
184 | - * Resumes the generator (unless the generator is already closed). |
|
185 | - * @return void |
|
186 | - */ |
|
187 | - public function next(): void {} |
|
188 | - |
|
189 | - /** |
|
190 | - * Sets the return value of the yield expression and resumes the generator (unless the generator is already closed). |
|
191 | - * @param mixed $value |
|
192 | - * @return mixed |
|
193 | - */ |
|
194 | - public function send(mixed $value): mixed {} |
|
195 | - |
|
196 | - /** |
|
197 | - * Throws an exception at the current suspension point in the generator. |
|
198 | - * @param Throwable $exception |
|
199 | - * @return mixed |
|
200 | - */ |
|
201 | - public function PS_UNRESERVE_PREFIX_throw(Throwable $exception): mixed {} |
|
202 | - |
|
203 | - /** |
|
204 | - * Returns whatever was passed to return or null if nothing. |
|
205 | - * Throws an exception if the generator is still valid. |
|
206 | - * @link https://wiki.php.net/rfc/generator-return-expressions |
|
207 | - * @return mixed |
|
208 | - * @since 7.0 |
|
209 | - */ |
|
210 | - public function getReturn(): mixed {} |
|
211 | - |
|
212 | - /** |
|
213 | - * Serialize callback |
|
214 | - * Throws an exception as generators can't be serialized. |
|
215 | - * @link https://php.net/manual/en/generator.wakeup.php |
|
216 | - * @return void |
|
217 | - */ |
|
218 | - public function __wakeup() {} |
|
219 | - } |
|
220 | - |
|
221 | - class ClosedGeneratorException extends Exception {} |
|
4 | + use JetBrains\PhpStorm\Internal\LanguageLevelTypeAware; |
|
5 | + |
|
6 | + /** |
|
7 | + * Creates an array. |
|
8 | + * @link https://php.net/manual/en/function.array.php |
|
9 | + * @param mixed ...$_ [optional] <p> |
|
10 | + * Syntax "index => values", separated by commas, define index and values. |
|
11 | + * index may be of type string or integer. When index is omitted, an integer index is automatically generated, |
|
12 | + * starting at 0. If index is an integer, next generated index will be the biggest integer index + 1. |
|
13 | + * Note that when two identical index are defined, the last overwrite the first. |
|
14 | + * </p> |
|
15 | + * <p> |
|
16 | + * Having a trailing comma after the last defined array entry, while unusual, is a valid syntax. |
|
17 | + * </p> |
|
18 | + * @return array an array of the parameters. The parameters can be given an index with the => operator. |
|
19 | + */ |
|
20 | + function PS_UNRESERVE_PREFIX_array(...$_) {} |
|
21 | + |
|
22 | + /** |
|
23 | + * Assigns a list of variables in one operation. |
|
24 | + * @link https://php.net/manual/en/function.list.php |
|
25 | + * @param mixed $var1 <p>A variable.</p> |
|
26 | + * @param mixed ...$_ [optional] <p>Another variable ...</p> |
|
27 | + * @return array the assigned array. |
|
28 | + */ |
|
29 | + function PS_UNRESERVE_PREFIX_list($var1, ...$_) {} |
|
30 | + |
|
31 | + /** |
|
32 | + * <p>Terminates execution of the script. Shutdown functions and object destructors will always be executed even if exit is called.</p> |
|
33 | + * <p>die is a language construct and it can be called without parentheses if no status is passed.</p> |
|
34 | + * @link https://php.net/manual/en/function.die.php |
|
35 | + * @param int|string $status [optional] <p> |
|
36 | + * If status is a string, this function prints the status just before exiting. |
|
37 | + * </p> |
|
38 | + * <p> |
|
39 | + * If status is an integer, that value will be used as the exit status and not printed. Exit statuses should be in the range 0 to 254, |
|
40 | + * the exit status 255 is reserved by PHP and shall not be used. The status 0 is used to terminate the program successfully. |
|
41 | + * </p> |
|
42 | + * <p> |
|
43 | + * Note: PHP >= 4.2.0 does NOT print the status if it is an integer. |
|
44 | + * </p> |
|
45 | + * @return void |
|
46 | + */ |
|
47 | + function PS_UNRESERVE_PREFIX_die($status = "") {} |
|
48 | + |
|
49 | + /** |
|
50 | + * <p>Terminates execution of the script. Shutdown functions and object destructors will always be executed even if exit is called.</p> |
|
51 | + * <p>exit is a language construct and it can be called without parentheses if no status is passed.</p> |
|
52 | + * @link https://php.net/manual/en/function.exit.php |
|
53 | + * @param int|string $status [optional] <p> |
|
54 | + * If status is a string, this function prints the status just before exiting. |
|
55 | + * </p> |
|
56 | + * <p> |
|
57 | + * If status is an integer, that value will be used as the exit status and not printed. Exit statuses should be in the range 0 to 254, |
|
58 | + * the exit status 255 is reserved by PHP and shall not be used. The status 0 is used to terminate the program successfully. |
|
59 | + * </p> |
|
60 | + * <p> |
|
61 | + * Note: PHP >= 4.2.0 does NOT print the status if it is an integer. |
|
62 | + * </p> |
|
63 | + * @return void |
|
64 | + */ |
|
65 | + function PS_UNRESERVE_PREFIX_exit($status = "") {} |
|
66 | + |
|
67 | + /** |
|
68 | + * Determine whether a variable is considered to be empty. A variable is considered empty if it does not exist or if its value |
|
69 | + * equals <b>FALSE</b>. <b>empty()</b> does not generate a warning if the variable does not exist. |
|
70 | + * @link https://php.net/manual/en/function.empty.php |
|
71 | + * @param mixed $var <p>Variable to be checked.</p> |
|
72 | + * <p>Note: Prior to PHP 5.5, <b>empty()</b> only supports variables; anything else will result in a parse error. In other words, |
|
73 | + * the following will not work: <b>empty(trim($name))</b>. Instead, use <b>trim($name) == false</b>. |
|
74 | + * </p> |
|
75 | + * <p> |
|
76 | + * No warning is generated if the variable does not exist. That means <b>empty()</b> is essentially the concise equivalent |
|
77 | + * to <b>!isset($var) || $var == false</b>. |
|
78 | + * </p> |
|
79 | + * @return bool <p><b>FALSE</b> if var exists and has a non-empty, non-zero value. Otherwise returns <b>TRUE</b>.<p> |
|
80 | + * <p> |
|
81 | + * The following things are considered to be empty: |
|
82 | + * <ul> |
|
83 | + * <li>"" (an empty string)</li> |
|
84 | + * <li>0 (0 as an integer)</li> |
|
85 | + * <li>0.0 (0 as a float)</li> |
|
86 | + * <li>"0" (0 as a string)</li> |
|
87 | + * <li><b>NULL</b></li> |
|
88 | + * <li><b>FALSE</b></li> |
|
89 | + * <li>array() (an empty array)</li> |
|
90 | + * <li>$var; (a variable declared, but without a value)</li> |
|
91 | + * </ul> |
|
92 | + * </p> |
|
93 | + */ |
|
94 | + function PS_UNRESERVE_PREFIX_empty($var) {} |
|
95 | + |
|
96 | + /** |
|
97 | + * <p>Determine if a variable is set and is not <b>NULL</b>.</p> |
|
98 | + * <p>If a variable has been unset with unset(), it will no longer be set. <b>isset()</b> will return <b>FALSE</b> if testing a variable |
|
99 | + * that has been set to <b>NULL</b>. Also note that a null character ("\0") is not equivalent to the PHP <b>NULL</b> constant.</p> |
|
100 | + * <p>If multiple parameters are supplied then <b>isset()</b> will return <b>TRUE</b> only if all of the parameters are set. |
|
101 | + * Evaluation goes from left to right and stops as soon as an unset variable is encountered.</p> |
|
102 | + * @link https://php.net/manual/en/function.isset.php |
|
103 | + * @param mixed $var <p>The variable to be checked.</p> |
|
104 | + * @param mixed ...$_ [optional] <p>Another variable ...</p> |
|
105 | + * @return bool Returns <b>TRUE</b> if var exists and has value other than <b>NULL</b>, <b>FALSE</b> otherwise. |
|
106 | + */ |
|
107 | + function PS_UNRESERVE_PREFIX_isset($var, ...$_) {} |
|
108 | + |
|
109 | + /** |
|
110 | + * <p>Destroys the specified variables.</p> |
|
111 | + * <p>The behavior of <b>unset()</b> inside of a function can vary depending on what type of variable you are attempting to destroy.</p> |
|
112 | + * @link https://php.net/manual/en/function.unset.php |
|
113 | + * @param mixed $var <p>The variable to be unset.</p> |
|
114 | + * @param mixed ...$_ [optional] <p>Another variable ...</p> |
|
115 | + * @return void |
|
116 | + */ |
|
117 | + function PS_UNRESERVE_PREFIX_unset($var, ...$_) {} |
|
118 | + |
|
119 | + /** |
|
120 | + * <p>Evaluates the given code as PHP.</p> |
|
121 | + * <p>Caution: The <b>eval()</b> language construct is very dangerous because it allows execution of arbitrary PHP code. Its use thus is |
|
122 | + * discouraged. If you have carefully verified that there is no other option than to use this construct, pay special attention not to |
|
123 | + * pass any user provided data into it without properly validating it beforehand.</p> |
|
124 | + * @link https://php.net/manual/en/function.eval.php |
|
125 | + * @param string $code <p> |
|
126 | + * Valid PHP code to be evaluated. |
|
127 | + * </p> |
|
128 | + * <p> |
|
129 | + * The code must not be wrapped in opening and closing PHP tags, i.e. 'echo "Hi!";' must be passed instead of '<?php echo "Hi!"; ?>'. |
|
130 | + * It is still possible to leave and re-enter PHP mode though using the appropriate PHP tags, e.g. |
|
131 | + * 'echo "In PHP mode!"; ?>In HTML mode!<?php echo "Back in PHP mode!";'. |
|
132 | + * </p> |
|
133 | + * <p> |
|
134 | + * Apart from that the passed code must be valid PHP. This includes that all statements must be properly terminated using a semicolon. |
|
135 | + * 'echo "Hi!"' for example will cause a parse error, whereas 'echo "Hi!";' will work. |
|
136 | + * </p> |
|
137 | + * <p> |
|
138 | + * A return statement will immediately terminate the evaluation of the code. |
|
139 | + * </p> |
|
140 | + * <p> |
|
141 | + * The code will be executed in the scope of the code calling <b>eval()</b>. Thus any variables defined or changed in the <b>eval()</b> |
|
142 | + * call will remain visible after it terminates. |
|
143 | + * </p> |
|
144 | + * @return mixed <b>NULL</b> unless return is called in the evaluated code, in which case the value passed to return is returned. |
|
145 | + * As of PHP 7, if there is a parse error in the evaluated code, <b>eval()</b> throws a ParseError exception. Before PHP 7, in this |
|
146 | + * case <b>eval()</b> returned <b>FALSE</b> and execution of the following code continued normally. It is not possible to catch a parse |
|
147 | + * error in <b>eval()</b> using set_error_handler(). |
|
148 | + */ |
|
149 | + function PS_UNRESERVE_PREFIX_eval($code) {} |
|
150 | + |
|
151 | + /** |
|
152 | + * Generator objects are returned from generators, cannot be instantiated via new. |
|
153 | + * @link https://secure.php.net/manual/en/class.generator.php |
|
154 | + * @link https://wiki.php.net/rfc/generators |
|
155 | + */ |
|
156 | + final class Generator implements Iterator |
|
157 | + { |
|
158 | + /** |
|
159 | + * Throws an exception if the generator is currently after the first yield. |
|
160 | + * @return void |
|
161 | + */ |
|
162 | + public function rewind(): void {} |
|
163 | + |
|
164 | + /** |
|
165 | + * Returns false if the generator has been closed, true otherwise. |
|
166 | + * @return bool |
|
167 | + */ |
|
168 | + public function valid(): bool {} |
|
169 | + |
|
170 | + /** |
|
171 | + * Returns whatever was passed to yield or null if nothing was passed or the generator is already closed. |
|
172 | + * @return mixed |
|
173 | + */ |
|
174 | + public function current(): mixed {} |
|
175 | + |
|
176 | + /** |
|
177 | + * Returns the yielded key or, if none was specified, an auto-incrementing key or null if the generator is already closed. |
|
178 | + * @return string|float|int|bool|null |
|
179 | + */ |
|
180 | + #[LanguageLevelTypeAware(['8.0' => 'mixed'], default: 'string|float|int|bool|null')] |
|
181 | + public function key() {} |
|
182 | + |
|
183 | + /** |
|
184 | + * Resumes the generator (unless the generator is already closed). |
|
185 | + * @return void |
|
186 | + */ |
|
187 | + public function next(): void {} |
|
188 | + |
|
189 | + /** |
|
190 | + * Sets the return value of the yield expression and resumes the generator (unless the generator is already closed). |
|
191 | + * @param mixed $value |
|
192 | + * @return mixed |
|
193 | + */ |
|
194 | + public function send(mixed $value): mixed {} |
|
195 | + |
|
196 | + /** |
|
197 | + * Throws an exception at the current suspension point in the generator. |
|
198 | + * @param Throwable $exception |
|
199 | + * @return mixed |
|
200 | + */ |
|
201 | + public function PS_UNRESERVE_PREFIX_throw(Throwable $exception): mixed {} |
|
202 | + |
|
203 | + /** |
|
204 | + * Returns whatever was passed to return or null if nothing. |
|
205 | + * Throws an exception if the generator is still valid. |
|
206 | + * @link https://wiki.php.net/rfc/generator-return-expressions |
|
207 | + * @return mixed |
|
208 | + * @since 7.0 |
|
209 | + */ |
|
210 | + public function getReturn(): mixed {} |
|
211 | + |
|
212 | + /** |
|
213 | + * Serialize callback |
|
214 | + * Throws an exception as generators can't be serialized. |
|
215 | + * @link https://php.net/manual/en/generator.wakeup.php |
|
216 | + * @return void |
|
217 | + */ |
|
218 | + public function __wakeup() {} |
|
219 | + } |
|
220 | + |
|
221 | + class ClosedGeneratorException extends Exception {} |
|
222 | 222 | } |
223 | 223 | |
224 | 224 | namespace ___PHPSTORM_HELPERS { |
225 | - class PS_UNRESERVE_PREFIX_this {} |
|
226 | - |
|
227 | - class PS_UNRESERVE_PREFIX_static {} |
|
228 | - |
|
229 | - class object |
|
230 | - { |
|
231 | - /** |
|
232 | - * PHP 5 allows developers to declare constructor methods for classes. |
|
233 | - * Classes which have a constructor method call this method on each newly-created object, |
|
234 | - * so it is suitable for any initialization that the object may need before it is used. |
|
235 | - * |
|
236 | - * Note: Parent constructors are not called implicitly if the child class defines a constructor. |
|
237 | - * In order to run a parent constructor, a call to parent::__construct() within the child constructor is required. |
|
238 | - * |
|
239 | - * param [ mixed $args [, $... ]] |
|
240 | - * @link https://php.net/manual/en/language.oop5.decon.php |
|
241 | - */ |
|
242 | - public function __construct() {} |
|
243 | - |
|
244 | - /** |
|
245 | - * PHP 5 introduces a destructor concept similar to that of other object-oriented languages, such as C++. |
|
246 | - * The destructor method will be called as soon as all references to a particular object are removed or |
|
247 | - * when the object is explicitly destroyed or in any order in shutdown sequence. |
|
248 | - * |
|
249 | - * Like constructors, parent destructors will not be called implicitly by the engine. |
|
250 | - * In order to run a parent destructor, one would have to explicitly call parent::__destruct() in the destructor body. |
|
251 | - * |
|
252 | - * Note: Destructors called during the script shutdown have HTTP headers already sent. |
|
253 | - * The working directory in the script shutdown phase can be different with some SAPIs (e.g. Apache). |
|
254 | - * |
|
255 | - * Note: Attempting to throw an exception from a destructor (called in the time of script termination) causes a fatal error. |
|
256 | - * |
|
257 | - * @return void |
|
258 | - * @link https://php.net/manual/en/language.oop5.decon.php |
|
259 | - */ |
|
260 | - public function __destruct() {} |
|
261 | - |
|
262 | - /** |
|
263 | - * is triggered when invoking inaccessible methods in an object context. |
|
264 | - * |
|
265 | - * @param string $name |
|
266 | - * @param array $arguments |
|
267 | - * @return mixed |
|
268 | - * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.methods |
|
269 | - */ |
|
270 | - public function __call(string $name, array $arguments) {} |
|
271 | - |
|
272 | - /** |
|
273 | - * is triggered when invoking inaccessible methods in a static context. |
|
274 | - * |
|
275 | - * @param string $name |
|
276 | - * @param array $arguments |
|
277 | - * @return mixed |
|
278 | - * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.methods |
|
279 | - */ |
|
280 | - public static function __callStatic(string $name, array $arguments) {} |
|
281 | - |
|
282 | - /** |
|
283 | - * is utilized for reading data from inaccessible members. |
|
284 | - * |
|
285 | - * @param string $name |
|
286 | - * @return mixed |
|
287 | - * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.members |
|
288 | - */ |
|
289 | - public function __get(string $name) {} |
|
290 | - |
|
291 | - /** |
|
292 | - * run when writing data to inaccessible members. |
|
293 | - * |
|
294 | - * @param string $name |
|
295 | - * @param mixed $value |
|
296 | - * @return void |
|
297 | - * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.members |
|
298 | - */ |
|
299 | - public function __set(string $name, $value): void {} |
|
300 | - |
|
301 | - /** |
|
302 | - * is triggered by calling isset() or empty() on inaccessible members. |
|
303 | - * |
|
304 | - * @param string $name |
|
305 | - * @return bool |
|
306 | - * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.members |
|
307 | - */ |
|
308 | - public function __isset(string $name): bool {} |
|
309 | - |
|
310 | - /** |
|
311 | - * is invoked when unset() is used on inaccessible members. |
|
312 | - * |
|
313 | - * @param string $name |
|
314 | - * @return void |
|
315 | - * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.members |
|
316 | - */ |
|
317 | - public function __unset(string $name): void {} |
|
318 | - |
|
319 | - /** |
|
320 | - * serialize() checks if your class has a function with the magic name __sleep. |
|
321 | - * If so, that function is executed prior to any serialization. |
|
322 | - * It can clean up the object and is supposed to return an array with the names of all variables of that object that should be serialized. |
|
323 | - * If the method doesn't return anything then NULL is serialized and E_NOTICE is issued. |
|
324 | - * The intended use of __sleep is to commit pending data or perform similar cleanup tasks. |
|
325 | - * Also, the function is useful if you have very large objects which do not need to be saved completely. |
|
326 | - * |
|
327 | - * @return string[] |
|
328 | - * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.sleep |
|
329 | - */ |
|
330 | - public function __sleep(): array {} |
|
331 | - |
|
332 | - /** |
|
333 | - * unserialize() checks for the presence of a function with the magic name __wakeup. |
|
334 | - * If present, this function can reconstruct any resources that the object may have. |
|
335 | - * The intended use of __wakeup is to reestablish any database connections that may have been lost during |
|
336 | - * serialization and perform other reinitialization tasks. |
|
337 | - * |
|
338 | - * @return void |
|
339 | - * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.sleep |
|
340 | - */ |
|
341 | - public function __wakeup(): void {} |
|
342 | - |
|
343 | - /** |
|
344 | - * The __toString method allows a class to decide how it will react when it is converted to a string. |
|
345 | - * |
|
346 | - * @return string |
|
347 | - * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.tostring |
|
348 | - */ |
|
349 | - public function __toString(): string {} |
|
350 | - |
|
351 | - /** |
|
352 | - * The __invoke method is called when a script tries to call an object as a function. |
|
353 | - * |
|
354 | - * @return mixed |
|
355 | - * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.invoke |
|
356 | - */ |
|
357 | - public function __invoke() {} |
|
358 | - |
|
359 | - /** |
|
360 | - * This method is called by var_dump() when dumping an object to get the properties that should be shown. |
|
361 | - * If the method isn't defined on an object, then all public, protected and private properties will be shown. |
|
362 | - * |
|
363 | - * @return array|null |
|
364 | - * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.debuginfo |
|
365 | - */ |
|
366 | - public function __debugInfo(): ?array {} |
|
367 | - |
|
368 | - /** |
|
369 | - * This static method is called for classes exported by var_export() since PHP 5.1.0. |
|
370 | - * The only parameter of this method is an array containing exported properties in the form array('property' => value, ...). |
|
371 | - * |
|
372 | - * @param array $an_array |
|
373 | - * @return object |
|
374 | - * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.set-state |
|
375 | - */ |
|
376 | - public static function __set_state(array $an_array): object {} |
|
377 | - |
|
378 | - /** |
|
379 | - * When an object is cloned, PHP 5 will perform a shallow copy of all of the object's properties. |
|
380 | - * Any properties that are references to other variables, will remain references. |
|
381 | - * Once the cloning is complete, if a __clone() method is defined, |
|
382 | - * then the newly created object's __clone() method will be called, to allow any necessary properties that need to be changed. |
|
383 | - * NOT CALLABLE DIRECTLY. |
|
384 | - * |
|
385 | - * @return void |
|
386 | - * @link https://php.net/manual/en/language.oop5.cloning.php |
|
387 | - */ |
|
388 | - public function __clone(): void {} |
|
389 | - |
|
390 | - /** |
|
391 | - * Returns array containing all the necessary state of the object. |
|
392 | - * @since 7.4 |
|
393 | - * @link https://wiki.php.net/rfc/custom_object_serialization |
|
394 | - */ |
|
395 | - public function __serialize(): array {} |
|
396 | - |
|
397 | - /** |
|
398 | - * Restores the object state from the given data array. |
|
399 | - * @param array $data |
|
400 | - * @since 7.4 |
|
401 | - * @link https://wiki.php.net/rfc/custom_object_serialization |
|
402 | - */ |
|
403 | - public function __unserialize(array $data): void {} |
|
404 | - } |
|
225 | + class PS_UNRESERVE_PREFIX_this {} |
|
226 | + |
|
227 | + class PS_UNRESERVE_PREFIX_static {} |
|
228 | + |
|
229 | + class object |
|
230 | + { |
|
231 | + /** |
|
232 | + * PHP 5 allows developers to declare constructor methods for classes. |
|
233 | + * Classes which have a constructor method call this method on each newly-created object, |
|
234 | + * so it is suitable for any initialization that the object may need before it is used. |
|
235 | + * |
|
236 | + * Note: Parent constructors are not called implicitly if the child class defines a constructor. |
|
237 | + * In order to run a parent constructor, a call to parent::__construct() within the child constructor is required. |
|
238 | + * |
|
239 | + * param [ mixed $args [, $... ]] |
|
240 | + * @link https://php.net/manual/en/language.oop5.decon.php |
|
241 | + */ |
|
242 | + public function __construct() {} |
|
243 | + |
|
244 | + /** |
|
245 | + * PHP 5 introduces a destructor concept similar to that of other object-oriented languages, such as C++. |
|
246 | + * The destructor method will be called as soon as all references to a particular object are removed or |
|
247 | + * when the object is explicitly destroyed or in any order in shutdown sequence. |
|
248 | + * |
|
249 | + * Like constructors, parent destructors will not be called implicitly by the engine. |
|
250 | + * In order to run a parent destructor, one would have to explicitly call parent::__destruct() in the destructor body. |
|
251 | + * |
|
252 | + * Note: Destructors called during the script shutdown have HTTP headers already sent. |
|
253 | + * The working directory in the script shutdown phase can be different with some SAPIs (e.g. Apache). |
|
254 | + * |
|
255 | + * Note: Attempting to throw an exception from a destructor (called in the time of script termination) causes a fatal error. |
|
256 | + * |
|
257 | + * @return void |
|
258 | + * @link https://php.net/manual/en/language.oop5.decon.php |
|
259 | + */ |
|
260 | + public function __destruct() {} |
|
261 | + |
|
262 | + /** |
|
263 | + * is triggered when invoking inaccessible methods in an object context. |
|
264 | + * |
|
265 | + * @param string $name |
|
266 | + * @param array $arguments |
|
267 | + * @return mixed |
|
268 | + * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.methods |
|
269 | + */ |
|
270 | + public function __call(string $name, array $arguments) {} |
|
271 | + |
|
272 | + /** |
|
273 | + * is triggered when invoking inaccessible methods in a static context. |
|
274 | + * |
|
275 | + * @param string $name |
|
276 | + * @param array $arguments |
|
277 | + * @return mixed |
|
278 | + * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.methods |
|
279 | + */ |
|
280 | + public static function __callStatic(string $name, array $arguments) {} |
|
281 | + |
|
282 | + /** |
|
283 | + * is utilized for reading data from inaccessible members. |
|
284 | + * |
|
285 | + * @param string $name |
|
286 | + * @return mixed |
|
287 | + * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.members |
|
288 | + */ |
|
289 | + public function __get(string $name) {} |
|
290 | + |
|
291 | + /** |
|
292 | + * run when writing data to inaccessible members. |
|
293 | + * |
|
294 | + * @param string $name |
|
295 | + * @param mixed $value |
|
296 | + * @return void |
|
297 | + * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.members |
|
298 | + */ |
|
299 | + public function __set(string $name, $value): void {} |
|
300 | + |
|
301 | + /** |
|
302 | + * is triggered by calling isset() or empty() on inaccessible members. |
|
303 | + * |
|
304 | + * @param string $name |
|
305 | + * @return bool |
|
306 | + * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.members |
|
307 | + */ |
|
308 | + public function __isset(string $name): bool {} |
|
309 | + |
|
310 | + /** |
|
311 | + * is invoked when unset() is used on inaccessible members. |
|
312 | + * |
|
313 | + * @param string $name |
|
314 | + * @return void |
|
315 | + * @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.members |
|
316 | + */ |
|
317 | + public function __unset(string $name): void {} |
|
318 | + |
|
319 | + /** |
|
320 | + * serialize() checks if your class has a function with the magic name __sleep. |
|
321 | + * If so, that function is executed prior to any serialization. |
|
322 | + * It can clean up the object and is supposed to return an array with the names of all variables of that object that should be serialized. |
|
323 | + * If the method doesn't return anything then NULL is serialized and E_NOTICE is issued. |
|
324 | + * The intended use of __sleep is to commit pending data or perform similar cleanup tasks. |
|
325 | + * Also, the function is useful if you have very large objects which do not need to be saved completely. |
|
326 | + * |
|
327 | + * @return string[] |
|
328 | + * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.sleep |
|
329 | + */ |
|
330 | + public function __sleep(): array {} |
|
331 | + |
|
332 | + /** |
|
333 | + * unserialize() checks for the presence of a function with the magic name __wakeup. |
|
334 | + * If present, this function can reconstruct any resources that the object may have. |
|
335 | + * The intended use of __wakeup is to reestablish any database connections that may have been lost during |
|
336 | + * serialization and perform other reinitialization tasks. |
|
337 | + * |
|
338 | + * @return void |
|
339 | + * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.sleep |
|
340 | + */ |
|
341 | + public function __wakeup(): void {} |
|
342 | + |
|
343 | + /** |
|
344 | + * The __toString method allows a class to decide how it will react when it is converted to a string. |
|
345 | + * |
|
346 | + * @return string |
|
347 | + * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.tostring |
|
348 | + */ |
|
349 | + public function __toString(): string {} |
|
350 | + |
|
351 | + /** |
|
352 | + * The __invoke method is called when a script tries to call an object as a function. |
|
353 | + * |
|
354 | + * @return mixed |
|
355 | + * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.invoke |
|
356 | + */ |
|
357 | + public function __invoke() {} |
|
358 | + |
|
359 | + /** |
|
360 | + * This method is called by var_dump() when dumping an object to get the properties that should be shown. |
|
361 | + * If the method isn't defined on an object, then all public, protected and private properties will be shown. |
|
362 | + * |
|
363 | + * @return array|null |
|
364 | + * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.debuginfo |
|
365 | + */ |
|
366 | + public function __debugInfo(): ?array {} |
|
367 | + |
|
368 | + /** |
|
369 | + * This static method is called for classes exported by var_export() since PHP 5.1.0. |
|
370 | + * The only parameter of this method is an array containing exported properties in the form array('property' => value, ...). |
|
371 | + * |
|
372 | + * @param array $an_array |
|
373 | + * @return object |
|
374 | + * @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.set-state |
|
375 | + */ |
|
376 | + public static function __set_state(array $an_array): object {} |
|
377 | + |
|
378 | + /** |
|
379 | + * When an object is cloned, PHP 5 will perform a shallow copy of all of the object's properties. |
|
380 | + * Any properties that are references to other variables, will remain references. |
|
381 | + * Once the cloning is complete, if a __clone() method is defined, |
|
382 | + * then the newly created object's __clone() method will be called, to allow any necessary properties that need to be changed. |
|
383 | + * NOT CALLABLE DIRECTLY. |
|
384 | + * |
|
385 | + * @return void |
|
386 | + * @link https://php.net/manual/en/language.oop5.cloning.php |
|
387 | + */ |
|
388 | + public function __clone(): void {} |
|
389 | + |
|
390 | + /** |
|
391 | + * Returns array containing all the necessary state of the object. |
|
392 | + * @since 7.4 |
|
393 | + * @link https://wiki.php.net/rfc/custom_object_serialization |
|
394 | + */ |
|
395 | + public function __serialize(): array {} |
|
396 | + |
|
397 | + /** |
|
398 | + * Restores the object state from the given data array. |
|
399 | + * @param array $data |
|
400 | + * @since 7.4 |
|
401 | + * @link https://wiki.php.net/rfc/custom_object_serialization |
|
402 | + */ |
|
403 | + public function __unserialize(array $data): void {} |
|
404 | + } |
|
405 | 405 | } |
@@ -153,8 +153,7 @@ discard block |
||
153 | 153 | * @link https://secure.php.net/manual/en/class.generator.php |
154 | 154 | * @link https://wiki.php.net/rfc/generators |
155 | 155 | */ |
156 | - final class Generator implements Iterator |
|
157 | - { |
|
156 | + final class Generator implements Iterator { |
|
158 | 157 | /** |
159 | 158 | * Throws an exception if the generator is currently after the first yield. |
160 | 159 | * @return void |
@@ -226,8 +225,7 @@ discard block |
||
226 | 225 | |
227 | 226 | class PS_UNRESERVE_PREFIX_static {} |
228 | 227 | |
229 | - class object |
|
230 | - { |
|
228 | + class object { |
|
231 | 229 | /** |
232 | 230 | * PHP 5 allows developers to declare constructor methods for classes. |
233 | 231 | * Classes which have a constructor method call this method on each newly-created object, |
@@ -169,9 +169,9 @@ |
||
169 | 169 | #[Pure] |
170 | 170 | #[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")] |
171 | 171 | function pack( |
172 | - string $format, |
|
173 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.3')] $values, |
|
174 | - mixed ...$values |
|
172 | + string $format, |
|
173 | + #[PhpStormStubsElementAvailable(from: '5.3', to: '7.3')] $values, |
|
174 | + mixed ...$values |
|
175 | 175 | ) {} |
176 | 176 | |
177 | 177 | /** |
@@ -167,10 +167,10 @@ discard block |
||
167 | 167 | * @return string|false a binary string containing data or false if the format string contains errors |
168 | 168 | */ |
169 | 169 | #[Pure] |
170 | -#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")] |
|
170 | +#[LanguageLevelTypeAware(["8.0" => "string"], default : "string|false")] |
|
171 | 171 | function pack( |
172 | 172 | string $format, |
173 | - #[PhpStormStubsElementAvailable(from: '5.3', to: '7.3')] $values, |
|
173 | + #[PhpStormStubsElementAvailable(from : '5.3', to : '7.3')] $values, |
|
174 | 174 | mixed ...$values |
175 | 175 | ) {} |
176 | 176 | |
@@ -188,7 +188,7 @@ discard block |
||
188 | 188 | * string or false if the format string contains errors |
189 | 189 | */ |
190 | 190 | #[Pure] |
191 | -function unpack(string $format, string $string, int $offset = 0): array|false {} |
|
191 | +function unpack(string $format, string $string, int $offset = 0): array | false {} |
|
192 | 192 | |
193 | 193 | /** |
194 | 194 | * Tells what the user's browser is capable of |
@@ -218,7 +218,7 @@ discard block |
||
218 | 218 | * reload, and check for the value. |
219 | 219 | */ |
220 | 220 | #[Pure] |
221 | -function get_browser(?string $user_agent, bool $return_array = false): object|array|false {} |
|
221 | +function get_browser(?string $user_agent, bool $return_array = false): object | array | false {} |
|
222 | 222 | |
223 | 223 | /** |
224 | 224 | * One-way string encryption (hashing) |
@@ -239,7 +239,7 @@ discard block |
||
239 | 239 | * @return string|null the encrypted string or <b>NULL</b> if an error occurs |
240 | 240 | */ |
241 | 241 | #[Pure] |
242 | -#[PhpStormStubsElementAvailable(to: '7.4')] |
|
242 | +#[PhpStormStubsElementAvailable(to : '7.4')] |
|
243 | 243 | function crypt($string, $salt = null): ?string {} |
244 | 244 | |
245 | 245 | /** |
@@ -338,7 +338,7 @@ discard block |
||
338 | 338 | * </p> |
339 | 339 | */ |
340 | 340 | #[Pure(true)] |
341 | -function getcwd(): string|false {} |
|
341 | +function getcwd(): string | false {} |
|
342 | 342 | |
343 | 343 | /** |
344 | 344 | * Rewind directory handle |
@@ -364,7 +364,7 @@ discard block |
||
364 | 364 | * </p> |
365 | 365 | * @return string|false the filename on success or false on failure. |
366 | 366 | */ |
367 | -function readdir($dir_handle): string|false {} |
|
367 | +function readdir($dir_handle): string | false {} |
|
368 | 368 | |
369 | 369 | /** |
370 | 370 | * Return an instance of the Directory class |
@@ -376,7 +376,7 @@ discard block |
||
376 | 376 | * @return Directory|false an instance of Directory, or <b>NULL</b> with wrong |
377 | 377 | * parameters, or <b>FALSE</b> in case of another error |
378 | 378 | */ |
379 | -function dir(string $directory, $context): Directory|false {} |
|
379 | +function dir(string $directory, $context): Directory | false {} |
|
380 | 380 | |
381 | 381 | /** |
382 | 382 | * Alias of dir() |
@@ -386,7 +386,7 @@ discard block |
||
386 | 386 | * @return Directory|false |
387 | 387 | * @see dir() |
388 | 388 | */ |
389 | -function getdir(string $directory, $context = null): Directory|false {} |
|
389 | +function getdir(string $directory, $context = null): Directory | false {} |
|
390 | 390 | |
391 | 391 | /** |
392 | 392 | * List files and directories inside the specified path |
@@ -409,7 +409,7 @@ discard block |
||
409 | 409 | * boolean false is returned, and an error of level |
410 | 410 | * E_WARNING is generated. |
411 | 411 | */ |
412 | -function scandir(string $directory, int $sorting_order, $context): array|false {} |
|
412 | +function scandir(string $directory, int $sorting_order, $context): array | false {} |
|
413 | 413 | |
414 | 414 | /** |
415 | 415 | * Find pathnames matching a pattern |
@@ -434,7 +434,7 @@ discard block |
||
434 | 434 | * error.</p> |
435 | 435 | */ |
436 | 436 | #[Pure(true)] |
437 | -function glob(string $pattern, int $flags): array|false {} |
|
437 | +function glob(string $pattern, int $flags): array | false {} |
|
438 | 438 | |
439 | 439 | /** |
440 | 440 | * Gets last access time of file |
@@ -446,7 +446,7 @@ discard block |
||
446 | 446 | * The time is returned as a Unix timestamp. |
447 | 447 | */ |
448 | 448 | #[Pure(true)] |
449 | -function fileatime(string $filename): int|false {} |
|
449 | +function fileatime(string $filename): int | false {} |
|
450 | 450 | |
451 | 451 | /** |
452 | 452 | * Gets inode change time of file |
@@ -458,7 +458,7 @@ discard block |
||
458 | 458 | * The time is returned as a Unix timestamp. |
459 | 459 | */ |
460 | 460 | #[Pure(true)] |
461 | -function filectime(string $filename): int|false {} |
|
461 | +function filectime(string $filename): int | false {} |
|
462 | 462 | |
463 | 463 | /** |
464 | 464 | * Gets file group |
@@ -472,7 +472,7 @@ discard block |
||
472 | 472 | * Upon failure, false is returned. |
473 | 473 | */ |
474 | 474 | #[Pure(true)] |
475 | -function filegroup(string $filename): int|false {} |
|
475 | +function filegroup(string $filename): int | false {} |
|
476 | 476 | |
477 | 477 | /** |
478 | 478 | * Gets file inode |
@@ -483,7 +483,7 @@ discard block |
||
483 | 483 | * @return int|false the inode number of the file, or false on failure. |
484 | 484 | */ |
485 | 485 | #[Pure(true)] |
486 | -function fileinode(string $filename): int|false {} |
|
486 | +function fileinode(string $filename): int | false {} |
|
487 | 487 | |
488 | 488 | /** |
489 | 489 | * Gets file modification time |
@@ -496,7 +496,7 @@ discard block |
||
496 | 496 | * suitable for the date function. |
497 | 497 | */ |
498 | 498 | #[Pure(true)] |
499 | -function filemtime(string $filename): int|false {} |
|
499 | +function filemtime(string $filename): int | false {} |
|
500 | 500 | |
501 | 501 | /** |
502 | 502 | * Gets file owner |
@@ -509,7 +509,7 @@ discard block |
||
509 | 509 | * posix_getpwuid to resolve it to a username. |
510 | 510 | */ |
511 | 511 | #[Pure(true)] |
512 | -function fileowner(string $filename): int|false {} |
|
512 | +function fileowner(string $filename): int | false {} |
|
513 | 513 | |
514 | 514 | /** |
515 | 515 | * Gets file permissions |
@@ -520,7 +520,7 @@ discard block |
||
520 | 520 | * @return int|false the permissions on the file, or false on failure. |
521 | 521 | */ |
522 | 522 | #[Pure(true)] |
523 | -function fileperms(string $filename): int|false {} |
|
523 | +function fileperms(string $filename): int | false {} |
|
524 | 524 | |
525 | 525 | /** |
526 | 526 | * Gets file size |
@@ -532,7 +532,7 @@ discard block |
||
532 | 532 | * of level E_WARNING) in case of an error. |
533 | 533 | */ |
534 | 534 | #[Pure(true)] |
535 | -function filesize(string $filename): int|false {} |
|
535 | +function filesize(string $filename): int | false {} |
|
536 | 536 | |
537 | 537 | /** |
538 | 538 | * Gets file type |
@@ -549,7 +549,7 @@ discard block |
||
549 | 549 | * or if the file type is unknown. |
550 | 550 | */ |
551 | 551 | #[Pure(true)] |
552 | -function filetype(string $filename): string|false {} |
|
552 | +function filetype(string $filename): string | false {} |
|
553 | 553 | |
554 | 554 | /** |
555 | 555 | * Checks whether a file or directory exists |
@@ -758,7 +758,7 @@ discard block |
||
758 | 758 | * In case of error, stat returns false. |
759 | 759 | */ |
760 | 760 | #[Pure(true)] |
761 | -function stat(string $filename): array|false {} |
|
761 | +function stat(string $filename): array | false {} |
|
762 | 762 | |
763 | 763 | /** |
764 | 764 | * Gives information about a file or symbolic link |
@@ -775,7 +775,7 @@ discard block |
||
775 | 775 | * file pointed to by the symbolic link. |
776 | 776 | */ |
777 | 777 | #[Pure(true)] |
778 | -function lstat(string $filename): array|false {} |
|
778 | +function lstat(string $filename): array | false {} |
|
779 | 779 | |
780 | 780 | /** |
781 | 781 | * Changes file owner |
@@ -788,7 +788,7 @@ discard block |
||
788 | 788 | * </p> |
789 | 789 | * @return bool true on success or false on failure. |
790 | 790 | */ |
791 | -function chown(string $filename, string|int $user): bool {} |
|
791 | +function chown(string $filename, string | int $user): bool {} |
|
792 | 792 | |
793 | 793 | /** |
794 | 794 | * Changes file group |
@@ -801,7 +801,7 @@ discard block |
||
801 | 801 | * </p> |
802 | 802 | * @return bool true on success or false on failure. |
803 | 803 | */ |
804 | -function chgrp(string $filename, string|int $group): bool {} |
|
804 | +function chgrp(string $filename, string | int $group): bool {} |
|
805 | 805 | |
806 | 806 | /** |
807 | 807 | * Changes user ownership of symlink |
@@ -815,7 +815,7 @@ discard block |
||
815 | 815 | * @return bool true on success or false on failure. |
816 | 816 | * @since 5.1.2 |
817 | 817 | */ |
818 | -function lchown(string $filename, string|int $user): bool {} |
|
818 | +function lchown(string $filename, string | int $user): bool {} |
|
819 | 819 | |
820 | 820 | /** |
821 | 821 | * Changes group ownership of symlink |
@@ -829,7 +829,7 @@ discard block |
||
829 | 829 | * @return bool true on success or false on failure. |
830 | 830 | * @since 5.1.2 |
831 | 831 | */ |
832 | -function lchgrp(string $filename, string|int $group): bool {} |
|
832 | +function lchgrp(string $filename, string | int $group): bool {} |
|
833 | 833 | |
834 | 834 | /** |
835 | 835 | * Changes file mode |
@@ -909,7 +909,7 @@ discard block |
||
909 | 909 | * or false on failure. |
910 | 910 | */ |
911 | 911 | #[Pure(true)] |
912 | -function disk_total_space(string $directory): float|false {} |
|
912 | +function disk_total_space(string $directory): float | false {} |
|
913 | 913 | |
914 | 914 | /** |
915 | 915 | * Returns available space in directory |
@@ -926,7 +926,7 @@ discard block |
||
926 | 926 | * or false on failure. |
927 | 927 | */ |
928 | 928 | #[Pure(true)] |
929 | -function disk_free_space(string $directory): float|false {} |
|
929 | +function disk_free_space(string $directory): float | false {} |
|
930 | 930 | |
931 | 931 | /** |
932 | 932 | * Alias of {@see disk_free_space} |
@@ -936,7 +936,7 @@ discard block |
||
936 | 936 | * @return float|false |
937 | 937 | */ |
938 | 938 | #[Pure(true)] |
939 | -function diskfreespace(string $directory): float|false {} |
|
939 | +function diskfreespace(string $directory): float | false {} |
|
940 | 940 | |
941 | 941 | /** |
942 | 942 | * Send mail |
@@ -1024,7 +1024,7 @@ discard block |
||
1024 | 1024 | * it does NOT mean the mail will actually reach the intended destination. |
1025 | 1025 | * </p> |
1026 | 1026 | */ |
1027 | -function mail(string $to, string $subject, string $message, array|string $additional_headers, string $additional_params): bool {} |
|
1027 | +function mail(string $to, string $subject, string $message, array | string $additional_headers, string $additional_params): bool {} |
|
1028 | 1028 | |
1029 | 1029 | /** |
1030 | 1030 | * Calculate the hash value needed by EZMLM |
@@ -1035,7 +1035,7 @@ discard block |
||
1035 | 1035 | * @return int The hash value of addr. |
1036 | 1036 | * @removed 8.0 |
1037 | 1037 | */ |
1038 | -#[Deprecated(since: '7.4')] |
|
1038 | +#[Deprecated(since : '7.4')] |
|
1039 | 1039 | function ezmlm_hash(string $addr): int {} |
1040 | 1040 | |
1041 | 1041 | /** |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | * </table> |
150 | 150 | * @return string|int The gregorian weekday as either an integer or string. |
151 | 151 | */ |
152 | -function jddayofweek(int $julian_day, int $mode = CAL_DOW_DAYNO): string|int {} |
|
152 | +function jddayofweek(int $julian_day, int $mode = CAL_DOW_DAYNO): string | int {} |
|
153 | 153 | |
154 | 154 | /** |
155 | 155 | * Returns a month name |
@@ -169,7 +169,7 @@ discard block |
||
169 | 169 | * @param int $mode [optional] Allows Easter dates to be calculated based on the Julian calendar when set to CAL_EASTER_ALWAYS_JULIAN |
170 | 170 | * @return int The easter date as a unix timestamp. |
171 | 171 | */ |
172 | -function easter_date(?int $year, #[PhpStormStubsElementAvailable(from: '8.0')] int $mode = CAL_EASTER_DEFAULT): int {} |
|
172 | +function easter_date(?int $year, #[PhpStormStubsElementAvailable(from : '8.0')] int $mode = CAL_EASTER_DEFAULT): int {} |
|
173 | 173 | |
174 | 174 | /** |
175 | 175 | * Get number of days after March 21 on which Easter falls for a given year |
@@ -196,7 +196,7 @@ discard block |
||
196 | 196 | * </p> |
197 | 197 | * @return int|false A julian day number as integer. |
198 | 198 | */ |
199 | -function unixtojd(?int $timestamp = 0): int|false {} |
|
199 | +function unixtojd(?int $timestamp = 0): int | false {} |
|
200 | 200 | |
201 | 201 | /** |
202 | 202 | * Convert Julian Day to Unix timestamp |
@@ -8,72 +8,72 @@ |
||
8 | 8 | */ |
9 | 9 | class Lua |
10 | 10 | { |
11 | - /** |
|
12 | - * @var string |
|
13 | - * |
|
14 | - * @link https://secure.php.net/manual/en/class.lua.php#lua.constants.lua-version |
|
15 | - */ |
|
16 | - public const LUA_VERSION = '5.1.4'; |
|
11 | + /** |
|
12 | + * @var string |
|
13 | + * |
|
14 | + * @link https://secure.php.net/manual/en/class.lua.php#lua.constants.lua-version |
|
15 | + */ |
|
16 | + public const LUA_VERSION = '5.1.4'; |
|
17 | 17 | |
18 | - /** |
|
19 | - * @param null|string $lua_script_file |
|
20 | - * @link https://secure.php.net/manual/en/lua.construct.php |
|
21 | - */ |
|
22 | - public function __construct(?string $lua_script_file = null) {} |
|
18 | + /** |
|
19 | + * @param null|string $lua_script_file |
|
20 | + * @link https://secure.php.net/manual/en/lua.construct.php |
|
21 | + */ |
|
22 | + public function __construct(?string $lua_script_file = null) {} |
|
23 | 23 | |
24 | - /** |
|
25 | - * @link https://secure.php.net/manual/en/lua.assign.php |
|
26 | - * |
|
27 | - * @param string $name |
|
28 | - * @param mixed $value |
|
29 | - * |
|
30 | - * @return $this|null Returns $this or NULL on failure. |
|
31 | - */ |
|
32 | - public function assign(string $name, $value) {} |
|
24 | + /** |
|
25 | + * @link https://secure.php.net/manual/en/lua.assign.php |
|
26 | + * |
|
27 | + * @param string $name |
|
28 | + * @param mixed $value |
|
29 | + * |
|
30 | + * @return $this|null Returns $this or NULL on failure. |
|
31 | + */ |
|
32 | + public function assign(string $name, $value) {} |
|
33 | 33 | |
34 | - /** |
|
35 | - * @link https://secure.php.net/manual/en/lua.call.php |
|
36 | - * |
|
37 | - * @param callable $lua_func Function name in lua |
|
38 | - * @param array $args Arguments passed to the Lua function |
|
39 | - * @param bool $use_self Whether to use self |
|
40 | - * |
|
41 | - * @return mixed|false Returns result of the called function, null for wrong arguments or FALSE on other failure. |
|
42 | - */ |
|
43 | - public function call(callable $lua_func, array $args = [], bool $use_self = false) {} |
|
34 | + /** |
|
35 | + * @link https://secure.php.net/manual/en/lua.call.php |
|
36 | + * |
|
37 | + * @param callable $lua_func Function name in lua |
|
38 | + * @param array $args Arguments passed to the Lua function |
|
39 | + * @param bool $use_self Whether to use self |
|
40 | + * |
|
41 | + * @return mixed|false Returns result of the called function, null for wrong arguments or FALSE on other failure. |
|
42 | + */ |
|
43 | + public function call(callable $lua_func, array $args = [], bool $use_self = false) {} |
|
44 | 44 | |
45 | - /** |
|
46 | - * @link https://secure.php.net/manual/en/lua.eval.php |
|
47 | - * |
|
48 | - * @param string $statements |
|
49 | - * |
|
50 | - * @return mixed|false Returns result of evaled code, NULL for wrong arguments or FALSE on other failure. |
|
51 | - */ |
|
52 | - public function eval(string $statements) {} |
|
45 | + /** |
|
46 | + * @link https://secure.php.net/manual/en/lua.eval.php |
|
47 | + * |
|
48 | + * @param string $statements |
|
49 | + * |
|
50 | + * @return mixed|false Returns result of evaled code, NULL for wrong arguments or FALSE on other failure. |
|
51 | + */ |
|
52 | + public function eval(string $statements) {} |
|
53 | 53 | |
54 | - /** |
|
55 | - * @link https://secure.php.net/manual/en/lua.include.php |
|
56 | - * |
|
57 | - * @param string $file |
|
58 | - * |
|
59 | - * @return mixed|false Returns result of included code, NULL for wrong arguments or FALSE on other failure. |
|
60 | - */ |
|
61 | - public function include(string $file) {} |
|
54 | + /** |
|
55 | + * @link https://secure.php.net/manual/en/lua.include.php |
|
56 | + * |
|
57 | + * @param string $file |
|
58 | + * |
|
59 | + * @return mixed|false Returns result of included code, NULL for wrong arguments or FALSE on other failure. |
|
60 | + */ |
|
61 | + public function include(string $file) {} |
|
62 | 62 | |
63 | - /** |
|
64 | - * @link https://secure.php.net/manual/en/lua.getversion.php |
|
65 | - * |
|
66 | - * @return string Returns Lua::LUA_VERSION |
|
67 | - */ |
|
68 | - public function getVersion(): string {} |
|
63 | + /** |
|
64 | + * @link https://secure.php.net/manual/en/lua.getversion.php |
|
65 | + * |
|
66 | + * @return string Returns Lua::LUA_VERSION |
|
67 | + */ |
|
68 | + public function getVersion(): string {} |
|
69 | 69 | |
70 | - /** |
|
71 | - * @link https://secure.php.net/manual/en/lua.registercallback.php |
|
72 | - * |
|
73 | - * @param string $name |
|
74 | - * @param callable $function A valid PHP function callback |
|
75 | - * |
|
76 | - * @return $this|null|false Returns $this, NULL for wrong arguments or FALSE on other failure. |
|
77 | - */ |
|
78 | - public function registerCallback(string $name, callable $function) {} |
|
70 | + /** |
|
71 | + * @link https://secure.php.net/manual/en/lua.registercallback.php |
|
72 | + * |
|
73 | + * @param string $name |
|
74 | + * @param callable $function A valid PHP function callback |
|
75 | + * |
|
76 | + * @return $this|null|false Returns $this, NULL for wrong arguments or FALSE on other failure. |
|
77 | + */ |
|
78 | + public function registerCallback(string $name, callable $function) {} |
|
79 | 79 | } |
@@ -6,8 +6,7 @@ |
||
6 | 6 | /** |
7 | 7 | * @link https://secure.php.net/manual/en/class.lua.php |
8 | 8 | */ |
9 | -class Lua |
|
10 | -{ |
|
9 | +class Lua { |
|
11 | 10 | /** |
12 | 11 | * @var string |
13 | 12 | * |