Provide PHP 8 return types to function signatures
This commit is contained in:
parent
11946d7817
commit
43ce0bb13e
174
Core/Core.php
174
Core/Core.php
|
@ -11,7 +11,7 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @return string the Zend Engine version number, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function zend_version () {}
|
||||
function zend_version (): string {}
|
||||
|
||||
/**
|
||||
* Returns the number of arguments passed to the function
|
||||
|
@ -20,7 +20,7 @@ function zend_version () {}
|
|||
* function.
|
||||
*/
|
||||
#[Pure]
|
||||
function func_num_args () {}
|
||||
function func_num_args (): int {}
|
||||
|
||||
/**
|
||||
* Return an item from the argument list
|
||||
|
@ -32,7 +32,7 @@ function func_num_args () {}
|
|||
* @return mixed|false the specified argument, or false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function func_get_arg (int $position) {}
|
||||
function func_get_arg (int $position): mixed {}
|
||||
|
||||
/**
|
||||
* Returns an array comprising a function's argument list
|
||||
|
@ -41,7 +41,7 @@ function func_get_arg (int $position) {}
|
|||
* member of the current user-defined function's argument list.
|
||||
*/
|
||||
#[Pure]
|
||||
function func_get_args () {}
|
||||
function func_get_args (): array {}
|
||||
|
||||
/**
|
||||
* Get string length
|
||||
|
@ -53,7 +53,7 @@ function func_get_args () {}
|
|||
* and 0 if the <i>string</i> is empty.
|
||||
*/
|
||||
#[Pure]
|
||||
function strlen (string $string) {}
|
||||
function strlen (string $string): int {}
|
||||
|
||||
/**
|
||||
* Binary safe string comparison
|
||||
|
@ -64,13 +64,14 @@ function strlen (string $string) {}
|
|||
* @param string $string2 <p>
|
||||
* The second string.
|
||||
* </p>
|
||||
* @return int < 0 if <i>str1</i> is less than
|
||||
* @return int less 0 if <i>str1</i> is less than
|
||||
* <i>str2</i>; > 0 if <i>str1</i>
|
||||
* is greater than <i>str2</i>, and 0 if they are
|
||||
* equal.
|
||||
*/
|
||||
#[Pure]
|
||||
function strcmp (string $string1, string $string2) {}
|
||||
function strcmp (string $string1, string $string2): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Binary safe string comparison of the first n characters
|
||||
|
@ -84,13 +85,14 @@ function strcmp (string $string1, string $string2) {}
|
|||
* @param int $length <p>
|
||||
* Number of characters to use in the comparison.
|
||||
* </p>
|
||||
* @return int < 0 if <i>str1</i> is less than
|
||||
* @return int less 0 if <i>str1</i> is less than
|
||||
* <i>str2</i>; > 0 if <i>str1</i>
|
||||
* is greater than <i>str2</i>, and 0 if they are
|
||||
* equal.
|
||||
*/
|
||||
#[Pure]
|
||||
function strncmp (string $string1, string $string2, int $length) {}
|
||||
function strncmp (string $string1, string $string2, int $length): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Binary safe case-insensitive string comparison
|
||||
|
@ -101,13 +103,14 @@ function strncmp (string $string1, string $string2, int $length) {}
|
|||
* @param string $string2 <p>
|
||||
* The second string
|
||||
* </p>
|
||||
* @return int < 0 if <i>str1</i> is less than
|
||||
* @return int less than 0 if <i>str1</i> is less than
|
||||
* <i>str2</i>; > 0 if <i>str1</i>
|
||||
* is greater than <i>str2</i>, and 0 if they are
|
||||
* equal.
|
||||
*/
|
||||
#[Pure]
|
||||
function strcasecmp (string $string1, string $string2) {}
|
||||
function strcasecmp (string $string1, string $string2): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Binary safe case-insensitive string comparison of the first n characters
|
||||
|
@ -121,12 +124,13 @@ function strcasecmp (string $string1, string $string2) {}
|
|||
* @param int $length <p>
|
||||
* The length of strings to be used in the comparison.
|
||||
* </p>
|
||||
* @return int < 0 if <i>str1</i> is less than
|
||||
* @return int less than 0 if <i>str1</i> is less than
|
||||
* <i>str2</i>; > 0 if <i>str1</i> is
|
||||
* greater than <i>str2</i>, and 0 if they are equal.
|
||||
*/
|
||||
#[Pure]
|
||||
function strncasecmp (string $string1, string $string2, int $length) {}
|
||||
function strncasecmp (string $string1, string $string2, int $length): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* The function returns {@see true} if the passed $haystack starts from the
|
||||
|
@ -185,7 +189,8 @@ function str_contains(string $haystack, string $needle) : bool {}
|
|||
* @removed 8.0
|
||||
*/
|
||||
#[Deprecated(reason: "Use a foreach loop instead", since: "7.2")]
|
||||
function each (array &$array) {}
|
||||
function each (array &$array): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets which PHP errors are reported
|
||||
|
@ -309,7 +314,8 @@ function each (array &$array) {}
|
|||
* level or the current level if no <i>level</i> parameter is
|
||||
* given.
|
||||
*/
|
||||
function error_reporting (int $error_level) {}
|
||||
function error_reporting (int $error_level): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Defines a named constant
|
||||
|
@ -336,7 +342,8 @@ function error_reporting (int $error_level) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function define (string $constant_name, $value, #[Deprecated] bool $case_insensitive = false) {}
|
||||
function define (string $constant_name, $value, #[Deprecated] bool $case_insensitive = false): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks whether a given named constant exists
|
||||
|
@ -348,7 +355,8 @@ function define (string $constant_name, $value, #[Deprecated] bool $case_insensi
|
|||
* has been defined, false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function defined (string $constant_name) {}
|
||||
function defined (string $constant_name): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the name of the class of an object
|
||||
|
@ -356,24 +364,23 @@ function defined (string $constant_name) {}
|
|||
* @param object $object [optional] <p>
|
||||
* The tested object. This parameter may be omitted when inside a class.
|
||||
* </p>
|
||||
* @return string|false <p>The name of the class of which <i>object</i> is an
|
||||
* instance. Returns false if <i>object</i> is not an
|
||||
* object.
|
||||
* </p>
|
||||
* <p>
|
||||
* @return string <p>The name of the class of which <i>object</i> is an
|
||||
* instance.
|
||||
* If <i>object</i> is omitted when inside a class, the
|
||||
* name of that class is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_class (object $object) {}
|
||||
function get_class (object $object): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* the "Late Static Binding" class name
|
||||
* @link https://php.net/manual/en/function.get-called-class.php
|
||||
* @return string|false The class name. Returns false if called from outside a class.
|
||||
* @return string
|
||||
*/
|
||||
#[Pure]
|
||||
function get_called_class () {}
|
||||
function get_called_class (): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieves the parent class name for object or class
|
||||
|
@ -391,7 +398,8 @@ function get_called_class () {}
|
|||
* If called without parameter outside object, this function returns false.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_parent_class (object|string $object_or_class) {}
|
||||
function get_parent_class (object|string $object_or_class): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if the class method exists
|
||||
|
@ -407,7 +415,8 @@ function get_parent_class (object|string $object_or_class) {}
|
|||
* otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function method_exists (mixed $object_or_class, string $method) {}
|
||||
function method_exists (mixed $object_or_class, string $method): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if the object or class has a property
|
||||
|
@ -422,7 +431,8 @@ function method_exists (mixed $object_or_class, string $method) {}
|
|||
* null in case of an error.
|
||||
*/
|
||||
#[Pure]
|
||||
function property_exists (mixed $object_or_class, string $property) {}
|
||||
function property_exists (mixed $object_or_class, string $property): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if the trait exists
|
||||
|
@ -432,7 +442,8 @@ function property_exists (mixed $object_or_class, string $property) {}
|
|||
* @link https://secure.php.net/manual/en/function.trait-exists.php
|
||||
* @since 5.4
|
||||
*/
|
||||
function trait_exists(string $trait, bool $autoload) {}
|
||||
function trait_exists(string $trait, bool $autoload): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if the class has been defined
|
||||
|
@ -446,7 +457,8 @@ function trait_exists(string $trait, bool $autoload) {}
|
|||
* @return bool true if <i>class_name</i> is a defined class,
|
||||
* false otherwise.
|
||||
*/
|
||||
function class_exists (string $class, bool $autoload = true) {}
|
||||
function class_exists (string $class, bool $autoload = true): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if the interface has been defined
|
||||
|
@ -461,7 +473,8 @@ function class_exists (string $class, bool $autoload = true) {}
|
|||
* <i>interface_name</i> has been defined, false otherwise.
|
||||
* @since 5.0.2
|
||||
*/
|
||||
function interface_exists (string $interface, bool $autoload = true) {}
|
||||
function interface_exists (string $interface, bool $autoload = true): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return true if the given function has been defined
|
||||
|
@ -477,7 +490,8 @@ function interface_exists (string $interface, bool $autoload = true) {}
|
|||
* <b>include_once</b> and <b>echo</b>.
|
||||
*/
|
||||
#[Pure]
|
||||
function function_exists (string $function) {}
|
||||
function function_exists (string $function): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Creates an alias for a class
|
||||
|
@ -487,7 +501,8 @@ function function_exists (string $function) {}
|
|||
* @param bool $autoload [optional] Whether to autoload if the original class is not found.
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function class_alias (string $class, string $alias, bool $autoload = true) {}
|
||||
function class_alias (string $class, string $alias, bool $autoload = true): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an array with the names of included or required files
|
||||
|
@ -504,7 +519,8 @@ function class_alias (string $class, string $alias, bool $autoload = true) {}
|
|||
* the returned array.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_included_files () {}
|
||||
function get_included_files (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias of <b>get_included_files</b>
|
||||
|
@ -512,7 +528,8 @@ function get_included_files () {}
|
|||
* @return string[]
|
||||
*/
|
||||
#[Pure]
|
||||
function get_required_files () {}
|
||||
function get_required_files (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* checks if the object has this class as one of its parents or implements it
|
||||
|
@ -532,7 +549,8 @@ function get_required_files () {}
|
|||
* <i>class_name</i>, false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_subclass_of (mixed $object_or_class, string $class, bool $allow_string = true) {}
|
||||
function is_subclass_of (mixed $object_or_class, string $class, bool $allow_string = true): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if the object is of this class or has this class as one of its parents
|
||||
|
@ -551,7 +569,8 @@ function is_subclass_of (mixed $object_or_class, string $class, bool $allow_stri
|
|||
* its parents, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_a (mixed $object_or_class, string $class, bool $allow_string = false) {}
|
||||
function is_a (mixed $object_or_class, string $class, bool $allow_string = false): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the default properties of the class
|
||||
|
@ -565,7 +584,8 @@ function is_a (mixed $object_or_class, string $class, bool $allow_string = false
|
|||
* varname => value.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_class_vars (string $class) {}
|
||||
function get_class_vars (string $class): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the properties of the given object
|
||||
|
@ -578,7 +598,8 @@ function get_class_vars (string $class) {}
|
|||
* not been assigned a value, it will be returned with a null value.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_object_vars (object $object) {}
|
||||
function get_object_vars (object $object): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the class methods' names
|
||||
|
@ -590,7 +611,8 @@ function get_object_vars (object $object) {}
|
|||
* <i>class_name</i>. In case of an error, it returns null.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_class_methods (object|string $object_or_class) {}
|
||||
function get_class_methods (object|string $object_or_class): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generates a user-level error/warning/notice message
|
||||
|
@ -607,7 +629,8 @@ function get_class_methods (object|string $object_or_class) {}
|
|||
* @return bool This function returns false if wrong <i>error_type</i> is
|
||||
* specified, true otherwise.
|
||||
*/
|
||||
function trigger_error (string $message, int $error_level = E_USER_NOTICE) {}
|
||||
function trigger_error (string $message, int $error_level = E_USER_NOTICE): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias of <b>trigger_error</b>
|
||||
|
@ -617,7 +640,8 @@ function trigger_error (string $message, int $error_level = E_USER_NOTICE) {}
|
|||
* @return bool This function returns false if wrong <i>error_type</i> is
|
||||
* specified, true otherwise.
|
||||
*/
|
||||
function user_error (string $message, int $error_level = E_USER_NOTICE) {}
|
||||
function user_error (string $message, int $error_level = E_USER_NOTICE): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets a user-defined error handler function
|
||||
|
@ -661,7 +685,8 @@ function set_error_handler (callable $callback, int $error_levels = E_ALL | E_ST
|
|||
* @link https://php.net/manual/en/function.restore-error-handler.php
|
||||
* @return bool This function always returns true.
|
||||
*/
|
||||
function restore_error_handler () {}
|
||||
function restore_error_handler (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets a user-defined exception handler function
|
||||
|
@ -677,14 +702,16 @@ function restore_error_handler () {}
|
|||
* @return callable|null the name of the previously defined exception handler, or null on error. If
|
||||
* no previous handler was defined, null is also returned.
|
||||
*/
|
||||
function set_exception_handler (callable $callback) {}
|
||||
function set_exception_handler (callable $callback)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Restores the previously defined exception handler function
|
||||
* @link https://php.net/manual/en/function.restore-exception-handler.php
|
||||
* @return bool This function always returns true.
|
||||
*/
|
||||
function restore_exception_handler () {}
|
||||
function restore_exception_handler (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an array with the name of the defined classes
|
||||
|
@ -699,7 +726,8 @@ function restore_exception_handler () {}
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function get_declared_classes () {}
|
||||
function get_declared_classes (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an array of all declared interfaces
|
||||
|
@ -708,7 +736,8 @@ function get_declared_classes () {}
|
|||
* script.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_declared_interfaces () {}
|
||||
function get_declared_interfaces (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an array of all declared traits
|
||||
|
@ -718,7 +747,8 @@ function get_declared_interfaces () {}
|
|||
* @since 5.4
|
||||
*/
|
||||
#[Pure]
|
||||
function get_declared_traits() {}
|
||||
function get_declared_traits(): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an array of all defined functions
|
||||
|
@ -731,7 +761,8 @@ function get_declared_traits() {}
|
|||
* below).
|
||||
*/
|
||||
#[Pure]
|
||||
function get_defined_functions (bool $exclude_disabled = false) {}
|
||||
function get_defined_functions (bool $exclude_disabled = false): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an array of all defined variables
|
||||
|
@ -739,7 +770,8 @@ function get_defined_functions (bool $exclude_disabled = false) {}
|
|||
* @return array A multidimensional array with all the variables.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_defined_vars () {}
|
||||
function get_defined_vars (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Create an anonymous (lambda-style) function
|
||||
|
@ -754,7 +786,8 @@ function get_defined_vars () {}
|
|||
* @removed 8.0
|
||||
*/
|
||||
#[Deprecated(reason: "Use anonymous functions instead", since: "7.2")]
|
||||
function create_function (string $args, string $code) {}
|
||||
function create_function (string $args, string $code): bool|string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the resource type
|
||||
|
@ -767,7 +800,8 @@ function create_function (string $args, string $code) {}
|
|||
* by this function, the return value will be the string
|
||||
* Unknown.
|
||||
*/
|
||||
function get_resource_type ($resource) {}
|
||||
function get_resource_type ($resource): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an array with the names of all modules compiled and loaded
|
||||
|
@ -779,7 +813,8 @@ function get_resource_type ($resource) {}
|
|||
* @return string[] an indexed array of all the modules names.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_loaded_extensions (bool $zend_extensions = false) {}
|
||||
function get_loaded_extensions (bool $zend_extensions = false): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find out whether an extension is loaded
|
||||
|
@ -814,7 +849,8 @@ function get_loaded_extensions (bool $zend_extensions = false) {}
|
|||
* is loaded, false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function extension_loaded (string $extension) {}
|
||||
function extension_loaded (string $extension): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an array with the names of the functions of a module
|
||||
|
@ -829,7 +865,8 @@ function extension_loaded (string $extension) {}
|
|||
* <i>module_name</i> is not a valid extension.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_extension_funcs (string $extension) {}
|
||||
function get_extension_funcs (string $extension): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an associative array with the names of all the constants and their values
|
||||
|
@ -886,7 +923,8 @@ function get_extension_funcs (string $extension) {}
|
|||
* @return array
|
||||
*/
|
||||
#[Pure]
|
||||
function get_defined_constants (bool $categorize = false) {}
|
||||
function get_defined_constants (bool $categorize = false): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generates a backtrace
|
||||
|
@ -984,7 +1022,8 @@ function get_defined_constants (bool $categorize = false) {}
|
|||
* </tr>
|
||||
* </table>
|
||||
*/
|
||||
function debug_backtrace (int $options = DEBUG_BACKTRACE_PROVIDE_OBJECT, int $limit = 0) {}
|
||||
function debug_backtrace (int $options = DEBUG_BACKTRACE_PROVIDE_OBJECT, int $limit = 0): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Prints a backtrace
|
||||
|
@ -1008,14 +1047,15 @@ function debug_backtrace (int $options = DEBUG_BACKTRACE_PROVIDE_OBJECT, int $li
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function debug_print_backtrace (int $options = 0, int $limit = 0) {}
|
||||
function debug_print_backtrace (int $options = 0, int $limit = 0): void {}
|
||||
|
||||
/**
|
||||
* Forces collection of any existing garbage cycles
|
||||
* @link https://php.net/manual/en/function.gc-collect-cycles.php
|
||||
* @return int number of collected cycles.
|
||||
*/
|
||||
function gc_collect_cycles () {}
|
||||
function gc_collect_cycles (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns status of the circular reference collector
|
||||
|
@ -1023,21 +1063,22 @@ function gc_collect_cycles () {}
|
|||
* @return bool true if the garbage collector is enabled, false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function gc_enabled () {}
|
||||
function gc_enabled (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Activates the circular reference collector
|
||||
* @link https://php.net/manual/en/function.gc-enable.php
|
||||
* @return void
|
||||
*/
|
||||
function gc_enable () {}
|
||||
function gc_enable (): void {}
|
||||
|
||||
/**
|
||||
* Deactivates the circular reference collector
|
||||
* @link https://php.net/manual/en/function.gc-disable.php
|
||||
* @return void
|
||||
*/
|
||||
function gc_disable () {}
|
||||
function gc_disable (): void {}
|
||||
|
||||
/**
|
||||
* Gets information about the garbage collector
|
||||
|
@ -1053,7 +1094,8 @@ function gc_disable () {}
|
|||
*/
|
||||
#[ArrayShape(["runs" => "int", "collected" => "int", "threshold" => "int", "roots" => "int"])]
|
||||
#[Pure]
|
||||
function gc_status () {}
|
||||
function gc_status (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Reclaims memory used by the Zend Engine memory manager
|
||||
|
@ -1061,7 +1103,8 @@ function gc_status () {}
|
|||
* @return int Returns the number of bytes freed.
|
||||
* @since 7.0
|
||||
*/
|
||||
function gc_mem_caches () {}
|
||||
function gc_mem_caches (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns active resources
|
||||
|
@ -1078,4 +1121,5 @@ function gc_mem_caches () {}
|
|||
* @since 7.0
|
||||
*/
|
||||
#[Pure]
|
||||
function get_resources (string $type) {}
|
||||
function get_resources (string $type): array
|
||||
{}
|
||||
|
|
|
@ -1649,7 +1649,8 @@ final class PDORow {
|
|||
* no drivers are available, it returns an empty array.
|
||||
*/
|
||||
#[Pure]
|
||||
function pdo_drivers () {}
|
||||
function pdo_drivers (): array
|
||||
{}
|
||||
|
||||
// End of PDO v.1.0.4dev
|
||||
?>
|
||||
|
|
|
@ -10,7 +10,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @return array
|
||||
*/
|
||||
#[Pure]
|
||||
function spl_classes () {}
|
||||
function spl_classes (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Default implementation for __autoload()
|
||||
|
@ -25,7 +26,7 @@ function spl_classes () {}
|
|||
* @return void
|
||||
* @since 5.1.2
|
||||
*/
|
||||
function spl_autoload (string $class, string $file_extensions)
|
||||
function spl_autoload (string $class, string $file_extensions): void
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -42,7 +43,8 @@ function spl_autoload (string $class, string $file_extensions)
|
|||
* spl_autoload.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
function spl_autoload_extensions (string $file_extensions) {}
|
||||
function spl_autoload_extensions (string $file_extensions): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Register given function as __autoload() implementation
|
||||
|
@ -60,7 +62,8 @@ function spl_autoload_extensions (string $file_extensions) {}
|
|||
* @throws TypeError Since 8.0.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
function spl_autoload_register (callable $callback, bool $throw = true, bool $prepend = false) {}
|
||||
function spl_autoload_register (callable $callback, bool $throw = true, bool $prepend = false): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Unregister given function as __autoload() implementation
|
||||
|
@ -71,7 +74,8 @@ function spl_autoload_register (callable $callback, bool $throw = true, bool $pr
|
|||
* @return bool true on success or false on failure.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
function spl_autoload_unregister (callable $callback) {}
|
||||
function spl_autoload_unregister (callable $callback): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return all registered __autoload() functions
|
||||
|
@ -81,7 +85,8 @@ function spl_autoload_unregister (callable $callback) {}
|
|||
* If no function is registered the return value will be an empty array.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
function spl_autoload_functions () {}
|
||||
function spl_autoload_functions (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Try all registered __autoload() functions to load the requested class
|
||||
|
@ -92,7 +97,7 @@ function spl_autoload_functions () {}
|
|||
* @return void
|
||||
* @since 5.1.2
|
||||
*/
|
||||
function spl_autoload_call (string $class) {}
|
||||
function spl_autoload_call (string $class): void {}
|
||||
|
||||
/**
|
||||
* Return the parent classes of the given class
|
||||
|
@ -108,7 +113,7 @@ function spl_autoload_call (string $class) {}
|
|||
* @return string[]|false An array on success, or false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function class_parents ($object_or_class, bool $autoload)
|
||||
function class_parents ($object_or_class, bool $autoload): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -125,7 +130,7 @@ function class_parents ($object_or_class, bool $autoload)
|
|||
* @return string[]|false An array on success, or false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function class_implements ($object_or_class, bool $autoload)
|
||||
function class_implements ($object_or_class, bool $autoload): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -136,7 +141,8 @@ function class_implements ($object_or_class, bool $autoload)
|
|||
* the same object.
|
||||
*/
|
||||
#[Pure]
|
||||
function spl_object_hash (object $object) {}
|
||||
function spl_object_hash (object $object): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Copy the iterator into an array
|
||||
|
@ -150,7 +156,8 @@ function spl_object_hash (object $object) {}
|
|||
* @return array An array containing the elements of the iterator.
|
||||
*/
|
||||
#[Pure]
|
||||
function iterator_to_array (Traversable $iterator, bool $preserve_keys = true) {}
|
||||
function iterator_to_array (Traversable $iterator, bool $preserve_keys = true): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Count the elements in an iterator
|
||||
|
@ -161,7 +168,8 @@ function iterator_to_array (Traversable $iterator, bool $preserve_keys = true) {
|
|||
* @return int The number of elements in iterator.
|
||||
*/
|
||||
#[Pure]
|
||||
function iterator_count (Traversable $iterator) {}
|
||||
function iterator_count (Traversable $iterator): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Call a function for every element in an iterator
|
||||
|
@ -179,7 +187,7 @@ function iterator_count (Traversable $iterator) {}
|
|||
* </p>
|
||||
* @return int the iteration count.
|
||||
*/
|
||||
function iterator_apply (Traversable $iterator, callable $callback, array $args)
|
||||
function iterator_apply (Traversable $iterator, callable $callback, array $args): int
|
||||
{}
|
||||
|
||||
// End of SPL v.0.2
|
||||
|
@ -194,7 +202,8 @@ function iterator_apply (Traversable $iterator, callable $callback, array $args)
|
|||
* @see get_declared_traits()
|
||||
* @since 5.4
|
||||
*/
|
||||
function class_uses($object_or_class, bool $autoload = true) {}
|
||||
function class_uses($object_or_class, bool $autoload = true): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* return the integer object handle for given object
|
||||
|
@ -202,6 +211,7 @@ function class_uses($object_or_class, bool $autoload = true) {}
|
|||
* @return int
|
||||
* @since 7.2
|
||||
*/
|
||||
function spl_object_id(object $object) {}
|
||||
function spl_object_id(object $object): int
|
||||
{}
|
||||
|
||||
?>
|
||||
|
|
|
@ -415,10 +415,10 @@ class SimpleXMLIterator extends SimpleXMLElement implements RecursiveIterator, C
|
|||
* <b>TRUE</b> if <i>ns</i> is a prefix, <b>FALSE</b> if it's a URI;
|
||||
* defaults to <b>FALSE</b>.
|
||||
* </p>
|
||||
* @return SimpleXMLElement an object of class SimpleXMLElement with
|
||||
* @return SimpleXMLElement|false an object of class SimpleXMLElement with
|
||||
* properties containing the data held within the XML document, or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function simplexml_load_file (string $filename, string $class_name = "SimpleXMLElement", int $options = 0, string $namespace_or_prefix = "", bool $is_prefix = false) {}
|
||||
function simplexml_load_file (string $filename, string $class_name = "SimpleXMLElement", int $options = 0, string $namespace_or_prefix = "", bool $is_prefix = false): SimpleXMLElement|false {}
|
||||
|
||||
/**
|
||||
* Interprets a string of XML into an object
|
||||
|
@ -443,10 +443,10 @@ function simplexml_load_file (string $filename, string $class_name = "SimpleXMLE
|
|||
* <b>TRUE</b> if <i>ns</i> is a prefix, <b>FALSE</b> if it's a URI;
|
||||
* defaults to <b>FALSE</b>.
|
||||
* </p>
|
||||
* @return SimpleXMLElement an object of class SimpleXMLElement with
|
||||
* @return SimpleXMLElement|false an object of class SimpleXMLElement with
|
||||
* properties containing the data held within the xml document, or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function simplexml_load_string (string $data, string $class_name = "SimpleXMLElement", int $options = 0, string $namespace_or_prefix = "", bool $is_prefix = false) {}
|
||||
function simplexml_load_string (string $data, string $class_name = "SimpleXMLElement", int $options = 0, string $namespace_or_prefix = "", bool $is_prefix = false): SimpleXMLElement|false {}
|
||||
|
||||
/**
|
||||
* Get a SimpleXMLElement object from a DOM node.
|
||||
|
@ -462,6 +462,6 @@ function simplexml_load_string (string $data, string $class_name = "SimpleXMLEle
|
|||
* </p>
|
||||
* @return SimpleXMLElement a SimpleXMLElement or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function simplexml_import_dom (DOMNode $node, string $class_name = "SimpleXMLElement") {}
|
||||
function simplexml_import_dom (DOMNode $node, string $class_name = "SimpleXMLElement"): SimpleXMLElement {}
|
||||
|
||||
// End of SimpleXML v.0.1
|
||||
|
|
|
@ -11,7 +11,8 @@
|
|||
* cache is disabled.
|
||||
* @since 5.5
|
||||
*/
|
||||
function opcache_compile_file(string $filename) { }
|
||||
function opcache_compile_file(string $filename): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.5.0, PECL ZendOpcache >= 7.0.0 )<br/>
|
||||
|
@ -25,7 +26,8 @@ function opcache_compile_file(string $filename) { }
|
|||
* cache is disabled.
|
||||
* @since 5.5
|
||||
*/
|
||||
function opcache_invalidate(string $filename, bool $force = false) { }
|
||||
function opcache_invalidate(string $filename, bool $force = false): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.5.0, PECL ZendOpcache >= 7.0.0 )<br/>
|
||||
|
@ -34,26 +36,29 @@ function opcache_invalidate(string $filename, bool $force = false) { }
|
|||
* @return bool Returns <b>TRUE</b> if the opcode cache was reset, or <b>FALSE</b> if the opcode cache is disabled.
|
||||
* @since 5.5
|
||||
*/
|
||||
function opcache_reset() { }
|
||||
function opcache_reset(): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.5.5, PECL ZendOpcache >= 7.0.2 )<br/>
|
||||
* Get status information about the cache
|
||||
* @link https://php.net/manual/en/function.opcache-get-status.php
|
||||
* @param bool $include_scripts <p>Include script specific state information</p>
|
||||
* @return array <p>Returns an array of information, optionally containing script specific state information</p>
|
||||
* @return array|false <p>Returns an array of information, optionally containing script specific state information</p>
|
||||
* @since 5.5
|
||||
*/
|
||||
function opcache_get_status (bool $include_scripts = true) {}
|
||||
function opcache_get_status (bool $include_scripts = true): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.5.5, PECL ZendOpcache >= 7.0.2 )<br/>
|
||||
* Get configuration information about the cache
|
||||
* @link https://php.net/manual/en/function.opcache-get-configuration.php
|
||||
* @return array <p>Returns an array of information, including ini, blacklist and version</p>
|
||||
* @return array|false <p>Returns an array of information, including ini, blacklist and version</p>
|
||||
* @since 5.5
|
||||
*/
|
||||
function opcache_get_configuration() {}
|
||||
function opcache_get_configuration(): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.6, PECL ZendOpcache >= 7.0.4 )<br/>
|
||||
|
@ -64,4 +69,5 @@ function opcache_get_configuration() {}
|
|||
* @return bool Returns TRUE if file is cached in OPCache, FALSE otherwise.
|
||||
* @since 5.6
|
||||
*/
|
||||
function opcache_is_script_cached(string $filename) {}
|
||||
function opcache_is_script_cached(string $filename): bool
|
||||
{}
|
||||
|
|
|
@ -20,7 +20,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @return string The sum of the two operands, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcadd (string $num1, string $num2, int $scale = 0) {}
|
||||
function bcadd (string $num1, string $num2, int $scale = 0): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Subtract one arbitrary precision number from another
|
||||
|
@ -40,7 +41,8 @@ function bcadd (string $num1, string $num2, int $scale = 0) {}
|
|||
* @return string The result of the subtraction, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcsub (string $num1, string $num2, int $scale = 0) {}
|
||||
function bcsub (string $num1, string $num2, int $scale = 0): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Multiply two arbitrary precision numbers
|
||||
|
@ -60,7 +62,8 @@ function bcsub (string $num1, string $num2, int $scale = 0) {}
|
|||
* @return string the result as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcmul (string $num1, string $num2, int $scale = 0) {}
|
||||
function bcmul (string $num1, string $num2, int $scale = 0): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Divide two arbitrary precision numbers
|
||||
|
@ -81,7 +84,8 @@ function bcmul (string $num1, string $num2, int $scale = 0) {}
|
|||
* <i>divisor</i> is 0.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcdiv (string $num1, string $num2, int $scale = 0) {}
|
||||
function bcdiv (string $num1, string $num2, int $scale = 0): ?string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get modulus of an arbitrary precision number
|
||||
|
@ -102,7 +106,8 @@ function bcdiv (string $num1, string $num2, int $scale = 0) {}
|
|||
* <i>divisor</i> is 0.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcmod (string $num1, string $num2, int $scale = 0) {}
|
||||
function bcmod (string $num1, string $num2, int $scale = 0): ?string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Raise an arbitrary precision number to another
|
||||
|
@ -124,7 +129,8 @@ function bcmod (string $num1, string $num2, int $scale = 0) {}
|
|||
* @return string the result as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcpow (string $num, string $exponent, int $scale = 0) {}
|
||||
function bcpow (string $num, string $exponent, int $scale = 0): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the square root of an arbitrary precision number
|
||||
|
@ -137,7 +143,8 @@ function bcpow (string $num, string $exponent, int $scale = 0) {}
|
|||
* <i>operand</i> is negative.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcsqrt (string $num, int $scale) {}
|
||||
function bcsqrt (string $num, int $scale): ?string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set default scale parameter for all bc math functions
|
||||
|
@ -147,7 +154,8 @@ function bcsqrt (string $num, int $scale) {}
|
|||
* </p>
|
||||
* @return int|true <b>INT</b> since 7.3.0 and <b>TRUE</b> before.
|
||||
*/
|
||||
function bcscale (int $scale) {}
|
||||
function bcscale (int $scale): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Compare two arbitrary precision numbers
|
||||
|
@ -168,7 +176,8 @@ function bcscale (int $scale) {}
|
|||
* <i>right_operand</i>, -1 otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function bccomp (string $num1, string $num2, int $scale = 0) {}
|
||||
function bccomp (string $num1, string $num2, int $scale = 0): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Raise an arbitrary precision number to another, reduced by a specified modulus
|
||||
|
@ -193,4 +202,5 @@ function bccomp (string $num1, string $num2, int $scale = 0) {}
|
|||
* is 0 or <i>exponent</i> is negative.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcpowmod (string $num, string $exponent, string $modulus, int $scale = 0) {}
|
||||
function bcpowmod (string $num, string $exponent, string $modulus, int $scale = 0): ?string
|
||||
{}
|
||||
|
|
26
bz2/bz2.php
26
bz2/bz2.php
|
@ -33,7 +33,7 @@ function bzopen ($file, string $mode) {}
|
|||
* </p>
|
||||
* @return string the uncompressed data, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function bzread ($bz, int $length = 1024) {}
|
||||
function bzread ($bz, int $length = 1024): string|false {}
|
||||
|
||||
/**
|
||||
* Binary safe bzip2 file write
|
||||
|
@ -52,7 +52,7 @@ function bzread ($bz, int $length = 1024) {}
|
|||
* </p>
|
||||
* @return int the number of bytes written, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function bzwrite ($bz, string $data, int $length)
|
||||
function bzwrite ($bz, string $data, int $length): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -64,7 +64,7 @@ function bzwrite ($bz, string $data, int $length)
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function bzflush ($bz) {}
|
||||
function bzflush ($bz): bool {}
|
||||
|
||||
/**
|
||||
* Close a bzip2 file
|
||||
|
@ -75,7 +75,8 @@ function bzflush ($bz) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function bzclose ($bz) {}
|
||||
function bzclose ($bz): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns a bzip2 error number
|
||||
|
@ -87,7 +88,8 @@ function bzclose ($bz) {}
|
|||
* @return int the error number as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function bzerrno ($bz) {}
|
||||
function bzerrno ($bz): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns a bzip2 error string
|
||||
|
@ -99,7 +101,8 @@ function bzerrno ($bz) {}
|
|||
* @return string a string containing the error message.
|
||||
*/
|
||||
#[Pure]
|
||||
function bzerrstr ($bz) {}
|
||||
function bzerrstr ($bz): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the bzip2 error number and error string in an array
|
||||
|
@ -113,7 +116,8 @@ function bzerrstr ($bz) {}
|
|||
* errstr entry.
|
||||
*/
|
||||
#[Pure]
|
||||
function bzerror ($bz) {}
|
||||
function bzerror ($bz): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Compress a string into bzip2 encoded data
|
||||
|
@ -135,10 +139,10 @@ function bzerror ($bz) {}
|
|||
* Regardless of the <i>workfactor</i>, the generated
|
||||
* output is the same.
|
||||
* </p>
|
||||
* @return mixed The compressed string, or an error number if an error occurred.
|
||||
* @return string|int The compressed string, or an error number if an error occurred.
|
||||
*/
|
||||
#[Pure]
|
||||
function bzcompress (string $data, int $block_size = 4, int $work_factor = 0) {}
|
||||
function bzcompress (string $data, int $block_size = 4, int $work_factor = 0): string|int {}
|
||||
|
||||
/**
|
||||
* Decompresses bzip2 encoded data
|
||||
|
@ -155,7 +159,7 @@ function bzcompress (string $data, int $block_size = 4, int $work_factor = 0) {}
|
|||
* See the bzip2 documentation for more
|
||||
* information about this feature.
|
||||
* </p>
|
||||
* @return mixed The decompressed string, or an error number if an error occurred.
|
||||
* @return string|int|false The decompressed string, or an error number if an error occurred.
|
||||
*/
|
||||
#[Pure]
|
||||
function bzdecompress (string $data, bool $use_less_memory) {}
|
||||
function bzdecompress (string $data, bool $use_less_memory): string|int|false {}
|
||||
|
|
|
@ -10,7 +10,8 @@
|
|||
* </p>
|
||||
* @return string The gregorian date as a string in the form "month/day/year"
|
||||
*/
|
||||
function jdtogregorian (int $julian_day) {}
|
||||
function jdtogregorian (int $julian_day): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a Gregorian date to Julian Day Count
|
||||
|
@ -26,7 +27,8 @@ function jdtogregorian (int $julian_day) {}
|
|||
* </p>
|
||||
* @return int The julian day for the given gregorian date as an integer.
|
||||
*/
|
||||
function gregoriantojd (int $month, int $day, int $year) {}
|
||||
function gregoriantojd (int $month, int $day, int $year): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a Julian Day Count to a Julian Calendar Date
|
||||
|
@ -36,7 +38,8 @@ function gregoriantojd (int $month, int $day, int $year) {}
|
|||
* </p>
|
||||
* @return string The julian date as a string in the form "month/day/year"
|
||||
*/
|
||||
function jdtojulian (int $julian_day) {}
|
||||
function jdtojulian (int $julian_day): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a Julian Calendar date to Julian Day Count
|
||||
|
@ -52,7 +55,8 @@ function jdtojulian (int $julian_day) {}
|
|||
* </p>
|
||||
* @return int The julian day for the given julian date as an integer.
|
||||
*/
|
||||
function juliantojd (int $month, int $day, int $year) {}
|
||||
function juliantojd (int $month, int $day, int $year): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a Julian day count to a Jewish calendar date
|
||||
|
@ -71,7 +75,8 @@ function juliantojd (int $month, int $day, int $year) {}
|
|||
* </p>
|
||||
* @return string The jewish date as a string in the form "month/day/year"
|
||||
*/
|
||||
function jdtojewish (int $julian_day, bool $hebrew = false, int $flags = 0) {}
|
||||
function jdtojewish (int $julian_day, bool $hebrew = false, int $flags = 0): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a date in the Jewish Calendar to Julian Day Count
|
||||
|
@ -87,7 +92,8 @@ function jdtojewish (int $julian_day, bool $hebrew = false, int $flags = 0) {}
|
|||
* </p>
|
||||
* @return int The julian day for the given jewish date as an integer.
|
||||
*/
|
||||
function jewishtojd (int $month, int $day, int $year) {}
|
||||
function jewishtojd (int $month, int $day, int $year): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a Julian Day Count to the French Republican Calendar
|
||||
|
@ -95,7 +101,8 @@ function jewishtojd (int $month, int $day, int $year) {}
|
|||
* @param int $julian_day
|
||||
* @return string The french revolution date as a string in the form "month/day/year"
|
||||
*/
|
||||
function jdtofrench (int $julian_day) {}
|
||||
function jdtofrench (int $julian_day): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a date from the French Republican Calendar to a Julian Day Count
|
||||
|
@ -111,7 +118,8 @@ function jdtofrench (int $julian_day) {}
|
|||
* </p>
|
||||
* @return int The julian day for the given french revolution date as an integer.
|
||||
*/
|
||||
function frenchtojd (int $month, int $day, int $year) {}
|
||||
function frenchtojd (int $month, int $day, int $year): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the day of the week
|
||||
|
@ -146,9 +154,10 @@ function frenchtojd (int $month, int $day, int $year) {}
|
|||
* </td>
|
||||
* </tr>
|
||||
* </table>
|
||||
* @return mixed The gregorian weekday as either an integer or string.
|
||||
* @return string|int The gregorian weekday as either an integer or string.
|
||||
*/
|
||||
function jddayofweek (int $julian_day, int $mode = CAL_DOW_DAYNO) {}
|
||||
function jddayofweek (int $julian_day, int $mode = CAL_DOW_DAYNO): string|int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns a month name
|
||||
|
@ -157,7 +166,8 @@ function jddayofweek (int $julian_day, int $mode = CAL_DOW_DAYNO) {}
|
|||
* @param int $mode
|
||||
* @return string The month name for the given Julian Day and <i>calendar</i>.
|
||||
*/
|
||||
function jdmonthname (int $julian_day, int $mode) {}
|
||||
function jdmonthname (int $julian_day, int $mode): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get Unix timestamp for midnight on Easter of a given year
|
||||
|
@ -168,7 +178,8 @@ function jdmonthname (int $julian_day, int $mode) {}
|
|||
* @param int $mode [optional] Allows Easter dates to be calculated based on the Julian calendar when set to CAL_EASTER_ALWAYS_JULIAN
|
||||
* @return int The easter date as a unix timestamp.
|
||||
*/
|
||||
function easter_date (int $year, int $mode = CAL_EASTER_DEFAULT) {}
|
||||
function easter_date (int $year, int $mode = CAL_EASTER_DEFAULT): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get number of days after March 21 on which Easter falls for a given year
|
||||
|
@ -185,7 +196,8 @@ function easter_date (int $year, int $mode = CAL_EASTER_DEFAULT) {}
|
|||
* @return int The number of days after March 21st that the Easter Sunday
|
||||
* is in the given <i>year</i>.
|
||||
*/
|
||||
function easter_days (int $year, int $mode = CAL_EASTER_DEFAULT) {}
|
||||
function easter_days (int $year, int $mode = CAL_EASTER_DEFAULT): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert Unix timestamp to Julian Day
|
||||
|
@ -193,9 +205,10 @@ function easter_days (int $year, int $mode = CAL_EASTER_DEFAULT) {}
|
|||
* @param int $timestamp [optional] defaults to time() <p>
|
||||
* A unix timestamp to convert.
|
||||
* </p>
|
||||
* @return int A julian day number as integer.
|
||||
* @return int|false A julian day number as integer.
|
||||
*/
|
||||
function unixtojd (int $timestamp = 0) {}
|
||||
function unixtojd (int $timestamp = 0): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert Julian Day to Unix timestamp
|
||||
|
@ -205,7 +218,8 @@ function unixtojd (int $timestamp = 0) {}
|
|||
* </p>
|
||||
* @return int The unix timestamp for the start of the given julian day.
|
||||
*/
|
||||
function jdtounix (int $julian_day) {}
|
||||
function jdtounix (int $julian_day): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts from a supported calendar to Julian Day Count
|
||||
|
@ -231,7 +245,8 @@ function jdtounix (int $julian_day) {}
|
|||
* </p>
|
||||
* @return int A Julian Day number.
|
||||
*/
|
||||
function cal_to_jd (int $calendar, int $month, int $day, int $year) {}
|
||||
function cal_to_jd (int $calendar, int $month, int $day, int $year): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts from Julian Day Count to a supported calendar
|
||||
|
@ -246,7 +261,8 @@ function cal_to_jd (int $calendar, int $month, int $day, int $year) {}
|
|||
* day of week, abbreviated and full names of weekday and month and the
|
||||
* date in string form "month/day/year".
|
||||
*/
|
||||
function cal_from_jd (int $julian_day, int $calendar) {}
|
||||
function cal_from_jd (int $julian_day, int $calendar): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the number of days in a month for a given year and calendar
|
||||
|
@ -262,7 +278,8 @@ function cal_from_jd (int $julian_day, int $calendar) {}
|
|||
* </p>
|
||||
* @return int The length in days of the selected month in the given calendar
|
||||
*/
|
||||
function cal_days_in_month (int $calendar, int $month, int $year) {}
|
||||
function cal_days_in_month (int $calendar, int $month, int $year): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns information about a particular calendar
|
||||
|
@ -273,7 +290,8 @@ function cal_days_in_month (int $calendar, int $month, int $year) {}
|
|||
* </p>
|
||||
* @return array
|
||||
*/
|
||||
function cal_info (int $calendar = -1) {}
|
||||
function cal_info (int $calendar = -1): array
|
||||
{}
|
||||
|
||||
define ('CAL_GREGORIAN', 0);
|
||||
define ('CAL_JULIAN', 1);
|
||||
|
|
|
@ -12,7 +12,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* a letter or a digit, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_alnum (mixed $text) {}
|
||||
function ctype_alnum (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for alphabetic character(s)
|
||||
|
@ -24,7 +25,8 @@ function ctype_alnum (mixed $text) {}
|
|||
* a letter from the current locale, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_alpha (mixed $text) {}
|
||||
function ctype_alpha (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for control character(s)
|
||||
|
@ -36,7 +38,8 @@ function ctype_alpha (mixed $text) {}
|
|||
* a control character from the current locale, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_cntrl (mixed $text) {}
|
||||
function ctype_cntrl (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for numeric character(s)
|
||||
|
@ -48,7 +51,8 @@ function ctype_cntrl (mixed $text) {}
|
|||
* <i>text</i> is a decimal digit, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_digit (mixed $text) {}
|
||||
function ctype_digit (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for lowercase character(s)
|
||||
|
@ -60,7 +64,8 @@ function ctype_digit (mixed $text) {}
|
|||
* a lowercase letter in the current locale.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_lower (mixed $text) {}
|
||||
function ctype_lower (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for any printable character(s) except space
|
||||
|
@ -73,7 +78,8 @@ function ctype_lower (mixed $text) {}
|
|||
* otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_graph (mixed $text) {}
|
||||
function ctype_graph (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for printable character(s)
|
||||
|
@ -87,7 +93,8 @@ function ctype_graph (mixed $text) {}
|
|||
* that do not have any output or control function at all.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_print (mixed $text) {}
|
||||
function ctype_print (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for any printable character which is not whitespace or an
|
||||
|
@ -100,7 +107,8 @@ function ctype_print (mixed $text) {}
|
|||
* is printable, but neither letter, digit or blank, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_punct (mixed $text) {}
|
||||
function ctype_punct (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for whitespace character(s)
|
||||
|
@ -114,7 +122,8 @@ function ctype_punct (mixed $text) {}
|
|||
* carriage return and form feed characters.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_space (mixed $text) {}
|
||||
function ctype_space (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for uppercase character(s)
|
||||
|
@ -126,7 +135,8 @@ function ctype_space (mixed $text) {}
|
|||
* an uppercase letter in the current locale.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_upper (mixed $text) {}
|
||||
function ctype_upper (mixed $text): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check for character(s) representing a hexadecimal digit
|
||||
|
@ -139,4 +149,5 @@ function ctype_upper (mixed $text) {}
|
|||
* [A-Fa-f] , <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function ctype_xdigit (mixed $text) {}
|
||||
function ctype_xdigit (mixed $text): bool
|
||||
{}
|
||||
|
|
|
@ -85,22 +85,24 @@ class CURLFile {
|
|||
* </p>
|
||||
* @return resource|false|CurlHandle a cURL handle on success, false on errors.
|
||||
*/
|
||||
#[LanguageLevelTypeAware(["8.0" => "CurlHandle|false"], default: "resource|false")]
|
||||
function curl_init (string $url) {}
|
||||
|
||||
/**
|
||||
* Copy a cURL handle along with all of its preferences
|
||||
* @link https://php.net/manual/en/function.curl-copy-handle.php
|
||||
* @param CurlHandle|resource $handle
|
||||
* @return resource a new cURL handle.
|
||||
* @return CurlHandle|resource|false a new cURL handle.
|
||||
*/
|
||||
#[Pure]
|
||||
#[LanguageLevelTypeAware(["8.0" => "CurlHandle|false"], default: "resource|false")]
|
||||
function curl_copy_handle (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle) {}
|
||||
|
||||
/**
|
||||
* Gets cURL version information
|
||||
* @link https://php.net/manual/en/function.curl-version.php
|
||||
* @param int $age [optional] Removed since version PHP 8.0.
|
||||
* @return array an associative array with the following elements:
|
||||
* @return array|false an associative array with the following elements:
|
||||
* <tr valign="top">
|
||||
* <td>Indice</td>
|
||||
* <td>Value description</td>
|
||||
|
@ -154,7 +156,8 @@ function curl_copy_handle (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], def
|
|||
"protocols" => "array",
|
||||
])]
|
||||
#[Pure]
|
||||
function curl_version ($age = null) {}
|
||||
function curl_version ($age = null): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set an option for a cURL transfer
|
||||
|
@ -2122,7 +2125,8 @@ function curl_version ($age = null) {}
|
|||
* </table>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function curl_setopt (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, int $option, mixed $value) {}
|
||||
function curl_setopt (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, int $option, mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set multiple options for a cURL transfer
|
||||
|
@ -2138,7 +2142,8 @@ function curl_setopt (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default:
|
|||
* future options in the options array.
|
||||
* @since 5.1.3
|
||||
*/
|
||||
function curl_setopt_array (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, array $options) {}
|
||||
function curl_setopt_array (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, array $options): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2150,7 +2155,7 @@ function curl_setopt_array (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], de
|
|||
* @return void
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_share_close (#[LanguageLevelTypeAware(["8.0" => "CurlShareHandle"], default: "resource")] $share_handle) {}
|
||||
function curl_share_close (#[LanguageLevelTypeAware(["8.0" => "CurlShareHandle"], default: "resource")] $share_handle): void {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2159,7 +2164,8 @@ function curl_share_close (#[LanguageLevelTypeAware(["8.0" => "CurlShareHandle"]
|
|||
* @return resource|CurlShareHandle Returns resource of type "cURL Share Handle".
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_share_init () {}
|
||||
function curl_share_init (): CurlShareHandle
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2240,7 +2246,8 @@ function curl_share_init () {}
|
|||
* Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_share_setopt (#[LanguageLevelTypeAware(["8.0" => "CurlShareHandle"], default: "resource")] $share_handle, int $option, mixed $value ) {}
|
||||
function curl_share_setopt (#[LanguageLevelTypeAware(["8.0" => "CurlShareHandle"], default: "resource")] $share_handle, int $option, mixed $value ): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2253,7 +2260,8 @@ function curl_share_setopt (#[LanguageLevelTypeAware(["8.0" => "CurlShareHandle"
|
|||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_strerror (int $error_code) {}
|
||||
function curl_strerror (int $error_code): ?string
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2268,7 +2276,8 @@ function curl_strerror (int $error_code) {}
|
|||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_unescape (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, string $string) {}
|
||||
function curl_unescape (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, string $string): string|false
|
||||
{}
|
||||
/**
|
||||
* Perform a cURL session
|
||||
* @link https://php.net/manual/en/function.curl-exec.php
|
||||
|
@ -2276,7 +2285,8 @@ function curl_unescape (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], defau
|
|||
* @return string|bool true on success or false on failure. However, if the CURLOPT_RETURNTRANSFER
|
||||
* option is set, it will return the result on success, false on failure.
|
||||
*/
|
||||
function curl_exec (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle) {}
|
||||
function curl_exec (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get information regarding a specific transfer
|
||||
|
@ -2310,7 +2320,8 @@ function curl_exec (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "
|
|||
* "redirect_time"
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_getinfo (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, int $option) {}
|
||||
function curl_getinfo (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, int $option): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return a string containing the last error for the current session
|
||||
|
@ -2320,7 +2331,8 @@ function curl_getinfo (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default
|
|||
* error occurred.
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_error (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle) {}
|
||||
function curl_error (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the last error number
|
||||
|
@ -2330,7 +2342,8 @@ function curl_error (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default:
|
|||
* occurred.
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_errno (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle) {}
|
||||
function curl_errno (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* URL encodes the given string
|
||||
|
@ -2344,7 +2357,8 @@ function curl_errno (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default:
|
|||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_escape(#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, string $string) {}
|
||||
function curl_escape(#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, string $string): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.5.0) <br/>
|
||||
|
@ -2358,7 +2372,8 @@ function curl_escape(#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default:
|
|||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_file_create(string $filename, string $mime_type = '', string $posted_filename = '') {}
|
||||
function curl_file_create(string $filename, string $mime_type = '', string $posted_filename = ''): CURLFile
|
||||
{}
|
||||
|
||||
/**
|
||||
* Close a cURL session
|
||||
|
@ -2366,14 +2381,16 @@ function curl_file_create(string $filename, string $mime_type = '', string $post
|
|||
* @param CurlHandle|resource $handle
|
||||
* @return void
|
||||
*/
|
||||
function curl_close (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle) {}
|
||||
function curl_close (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle): void {}
|
||||
|
||||
/**
|
||||
* Returns a new cURL multi handle
|
||||
* @link https://php.net/manual/en/function.curl-multi-init.php
|
||||
* @return resource|false|CurlMultiHandle a cURL multi handle resource on success, false on failure.
|
||||
* @return resource|CurlMultiHandle a cURL multi handle resource on success, false on failure.
|
||||
*/
|
||||
function curl_multi_init () {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")]
|
||||
function curl_multi_init (): CurlMultiHandle|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Add a normal cURL handle to a cURL multi handle
|
||||
|
@ -2383,7 +2400,8 @@ function curl_multi_init () {}
|
|||
* @return int 0 on success, or one of the CURLM_XXX errors
|
||||
* code.
|
||||
*/
|
||||
function curl_multi_add_handle (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, #[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle) {}
|
||||
function curl_multi_add_handle (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, #[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Remove a multi handle from a set of cURL handles
|
||||
|
@ -2392,7 +2410,9 @@ function curl_multi_add_handle (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHan
|
|||
* @param CurlHandle|resource $handle
|
||||
* @return int|false On success, returns one of the CURLM_XXX error codes, false on failure.
|
||||
*/
|
||||
function curl_multi_remove_handle (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, #[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function curl_multi_remove_handle (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, #[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Wait for activity on any curl_multi connection
|
||||
|
@ -2404,7 +2424,8 @@ function curl_multi_remove_handle (#[LanguageLevelTypeAware(["8.0" => "CurlMulti
|
|||
* @return int On success, returns the number of descriptors contained in,
|
||||
* the descriptor sets. On failure, this function will return -1 on a select failure or timeout (from the underlying select system call).
|
||||
*/
|
||||
function curl_multi_select (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, float $timeout = 1.0) {}
|
||||
function curl_multi_select (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, float $timeout = 1.0): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2457,7 +2478,8 @@ function curl_multi_select (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"
|
|||
* @return bool Returns TRUE on success or FALSE on failure.
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_multi_setopt (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, int $option, mixed $value) {}
|
||||
function curl_multi_setopt (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, int $option, mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2469,7 +2491,8 @@ function curl_multi_setopt (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"
|
|||
* @return string|null Returns error string for valid error code, NULL otherwise.
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_multi_strerror (int $error_code) {}
|
||||
function curl_multi_strerror (int $error_code): ?string
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2481,7 +2504,8 @@ function curl_multi_strerror (int $error_code) {}
|
|||
* @return int Returns an error code (<b>CURLE_OK</b> for no error).
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_pause (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, int $flags) {}
|
||||
function curl_pause (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle, int $flags): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2492,7 +2516,7 @@ function curl_pause (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default:
|
|||
* @return void
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_reset (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle) {}
|
||||
function curl_reset (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $handle): void {}
|
||||
|
||||
/**
|
||||
* Run the sub-connections of the current cURL handle
|
||||
|
@ -2508,7 +2532,8 @@ function curl_reset (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default:
|
|||
* occurred problems on individual transfers even when this function returns
|
||||
* CURLM_OK.
|
||||
*/
|
||||
function curl_multi_exec (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, &$still_running) {}
|
||||
function curl_multi_exec (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, &$still_running): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the content of a cURL handle if <constant>CURLOPT_RETURNTRANSFER</constant> is set
|
||||
|
@ -2517,7 +2542,8 @@ function curl_multi_exec (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"],
|
|||
* @return string Return the content of a cURL handle if CURLOPT_RETURNTRANSFER is set.
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_multi_getcontent (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $multi_handle) {}
|
||||
function curl_multi_getcontent (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"], default: "resource")] $multi_handle): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get information about the current transfers
|
||||
|
@ -2529,7 +2555,8 @@ function curl_multi_getcontent (#[LanguageLevelTypeAware(["8.0" => "CurlHandle"]
|
|||
* @return array|false On success, returns an associative array for the message, false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_multi_info_read (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, &$queued_messages) {}
|
||||
function curl_multi_info_read (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle, &$queued_messages): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Close a set of cURL handles
|
||||
|
@ -2537,7 +2564,7 @@ function curl_multi_info_read (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHand
|
|||
* @param CurlMultiHandle|resource $multi_handle
|
||||
* @return void
|
||||
*/
|
||||
function curl_multi_close (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle) {}
|
||||
function curl_multi_close (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle): void {}
|
||||
|
||||
/**
|
||||
* Return the last multi curl error number
|
||||
|
@ -2546,7 +2573,8 @@ function curl_multi_close (#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"]
|
|||
* @since 7.1
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_multi_errno(#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle) {}
|
||||
function curl_multi_errno(#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"], default: "resource")] $multi_handle): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the last share curl error number
|
||||
|
@ -2555,7 +2583,8 @@ function curl_multi_errno(#[LanguageLevelTypeAware(["8.0" => "CurlMultiHandle"],
|
|||
* @since 7.1
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_share_errno(#[LanguageLevelTypeAware(["8.0" => "CurlShareHandle"], default: "resource")] $share_handle) {}
|
||||
function curl_share_errno(#[LanguageLevelTypeAware(["8.0" => "CurlShareHandle"], default: "resource")] $share_handle): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return string describing the given error code
|
||||
|
@ -2564,7 +2593,8 @@ function curl_share_errno(#[LanguageLevelTypeAware(["8.0" => "CurlShareHandle"],
|
|||
* @since 7.1
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_share_strerror(int $error_code){}
|
||||
function curl_share_strerror(int $error_code): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
|
|
180
date/date.php
180
date/date.php
|
@ -20,7 +20,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* this function would return -1 on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function strtotime (string $datetime, int $baseTimestamp) {}
|
||||
function strtotime (string $datetime, int $baseTimestamp): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Format a local time/date
|
||||
|
@ -289,7 +290,9 @@ function strtotime (string $datetime, int $baseTimestamp) {}
|
|||
* E_WARNING level error is emitted.
|
||||
*/
|
||||
#[Pure]
|
||||
function date (string $format, int $timestamp) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function date (string $format, int $timestamp)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Format a local time/date as integer
|
||||
|
@ -377,7 +380,7 @@ function date (string $format, int $timestamp) {}
|
|||
* </table>
|
||||
* </p>
|
||||
* @param int $timestamp [optional]
|
||||
* @return int an integer.
|
||||
* @return int|false an integer.
|
||||
* </p>
|
||||
* <p>
|
||||
* As idate always returns an integer and
|
||||
|
@ -385,7 +388,8 @@ function date (string $format, int $timestamp) {}
|
|||
* fewer digits than you would expect. See the example below.
|
||||
*/
|
||||
#[Pure]
|
||||
function idate (string $format, int $timestamp) {}
|
||||
function idate (string $format, int $timestamp): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Format a GMT/UTC date/time
|
||||
|
@ -400,7 +404,9 @@ function idate (string $format, int $timestamp) {}
|
|||
* E_WARNING level error is emitted.
|
||||
*/
|
||||
#[Pure]
|
||||
function gmdate (string $format, int $timestamp) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function gmdate (string $format, int $timestamp)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get Unix timestamp for a date
|
||||
|
@ -453,7 +459,8 @@ function gmdate (string $format, int $timestamp) {}
|
|||
* it returned -1).
|
||||
*/
|
||||
#[Pure]
|
||||
function mktime ($hour = null, $minute = null, $second = null, $month = null, $day = null, $year = null, #[Deprecated('Use the new timezone handling functions instead', since: '5.3')] $is_dst = -1) {}
|
||||
function mktime ($hour = null, $minute = null, $second = null, $month = null, $day = null, $year = null, #[Deprecated('Use the new timezone handling functions instead', since: '5.3')] $is_dst = -1): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get Unix timestamp for a GMT date
|
||||
|
@ -480,10 +487,11 @@ function mktime ($hour = null, $minute = null, $second = null, $month = null, $d
|
|||
* Parameters always represent a GMT date so is_dst
|
||||
* doesn't influence the result.
|
||||
* </p>
|
||||
* @return int a integer Unix timestamp.
|
||||
* @return int|false a integer Unix timestamp.
|
||||
*/
|
||||
#[Pure]
|
||||
function gmmktime ($hour = null, $minute = null, $second = null, $month = null, $day = null, $year = null, $is_dst = null) {}
|
||||
function gmmktime ($hour = null, $minute = null, $second = null, $month = null, $day = null, $year = null, $is_dst = null): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Validate a Gregorian date
|
||||
|
@ -502,7 +510,8 @@ function gmmktime ($hour = null, $minute = null, $second = null, $month = null,
|
|||
* @return bool true if the date given is valid; otherwise returns false.
|
||||
*/
|
||||
#[Pure]
|
||||
function checkdate (int $month, int $day, int $year) {}
|
||||
function checkdate (int $month, int $day, int $year): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Format a local time/date according to locale settings
|
||||
|
@ -756,13 +765,13 @@ function checkdate (int $month, int $day, int $year) {}
|
|||
* @param string $format <p>
|
||||
* @param int $timestamp [optional] defaults to the value of time()
|
||||
* Unix timestamp that defaults to the current local time if a timestamp is not given..
|
||||
* @return string a string formatted according format
|
||||
* @return string|false a string formatted according format
|
||||
* using the given timestamp or the current
|
||||
* local time if no timestamp is given. Month and weekday names and
|
||||
* other language-dependent strings respect the current locale set
|
||||
* with setlocale.
|
||||
*/
|
||||
function strftime (string $format, int $timestamp)
|
||||
function strftime (string $format, int $timestamp): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -772,20 +781,22 @@ function strftime (string $format, int $timestamp)
|
|||
* See description in strftime.
|
||||
* </p>
|
||||
* @param int $timestamp [optional]
|
||||
* @return string a string formatted according to the given format string
|
||||
* @return string|false a string formatted according to the given format string
|
||||
* using the given timestamp or the current
|
||||
* local time if no timestamp is given. Month and weekday names and
|
||||
* other language dependent strings respect the current locale set
|
||||
* with setlocale.
|
||||
*/
|
||||
function gmstrftime (string $format, int $timestamp) {}
|
||||
function gmstrftime (string $format, int $timestamp): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return current Unix timestamp
|
||||
* @link https://php.net/manual/en/function.time.php
|
||||
* @return int <p>Returns the current time measured in the number of seconds since the Unix Epoch (January 1 1970 00:00:00 GMT).</p>
|
||||
*/
|
||||
function time () {}
|
||||
function time (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the local time
|
||||
|
@ -804,7 +815,8 @@ function time () {}
|
|||
* @return array
|
||||
*/
|
||||
#[Pure]
|
||||
function localtime (int $timestamp, bool $associative) {}
|
||||
function localtime (int $timestamp, bool $associative): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get date/time information
|
||||
|
@ -886,7 +898,8 @@ function localtime (int $timestamp, bool $associative) {}
|
|||
* </table>
|
||||
*/
|
||||
#[Pure]
|
||||
function getdate (int $timestamp) {}
|
||||
function getdate (int $timestamp): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns new DateTime object
|
||||
|
@ -900,7 +913,8 @@ function getdate (int $timestamp) {}
|
|||
* @return DateTime|false DateTime object on success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_create (string $datetime, DateTimeZone $timezone ) {}
|
||||
function date_create (string $datetime, DateTimeZone $timezone ): DateTime|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5.5)<br/>
|
||||
|
@ -917,7 +931,8 @@ function date_create (string $datetime, DateTimeZone $timezone ) {}
|
|||
* @return DateTimeImmutable|false DateTime object on success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_create_immutable (string $datetime, DateTimeZone $timezone) {}
|
||||
function date_create_immutable (string $datetime, DateTimeZone $timezone): DateTimeImmutable|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns new DateTimeImmutable object formatted according to the specified format
|
||||
|
@ -925,10 +940,11 @@ function date_create_immutable (string $datetime, DateTimeZone $timezone) {}
|
|||
* @param string $format
|
||||
* @param string $datetime
|
||||
* @param DateTimeZone $timezone [optional]
|
||||
* @return DateTimeImmutable
|
||||
* @return DateTimeImmutable|false
|
||||
*/
|
||||
#[Pure]
|
||||
function date_create_immutable_from_format (string $format, string $datetime, DateTimeZone $timezone) {}
|
||||
function date_create_immutable_from_format (string $format, string $datetime, DateTimeZone $timezone): DateTimeImmutable|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -944,7 +960,8 @@ function date_create_immutable_from_format (string $format, string $datetime, Da
|
|||
* {@see DateTime} instance or <b>FALSE</b> on failure.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_create_from_format (string $format, string $datetime, DateTimeZone $timezone) {}
|
||||
function date_create_from_format (string $format, string $datetime, DateTimeZone $timezone): DateTime|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns associative array with detailed info about given date
|
||||
|
@ -956,7 +973,9 @@ function date_create_from_format (string $format, string $datetime, DateTimeZone
|
|||
* on success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_parse (string $datetime) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")]
|
||||
function date_parse (string $datetime): bool|array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get info about given date formatted according to the specified format
|
||||
|
@ -970,17 +989,19 @@ function date_parse (string $datetime) {}
|
|||
* @return array associative array with detailed info about given date.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_parse_from_format (string $format, string $datetime) {}
|
||||
function date_parse_from_format (string $format, string $datetime): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the warnings and errors
|
||||
* Alias:
|
||||
* {@see DateTime::getLastErrors}
|
||||
* @link https://php.net/manual/en/function.date-get-last-errors.php
|
||||
* @return array <p>Returns array containing info about warnings and errors.</p>
|
||||
* @return array|false <p>Returns array containing info about warnings and errors.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_get_last_errors () {}
|
||||
function date_get_last_errors (): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -991,7 +1012,9 @@ function date_get_last_errors () {}
|
|||
* @return string|false formatted date string on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_format (DateTimeInterface $object, string $format) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function date_format (DateTimeInterface $object, string $format)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alter the timestamp of a DateTime object by incrementing or decrementing
|
||||
|
@ -1004,7 +1027,8 @@ function date_format (DateTimeInterface $object, string $format) {}
|
|||
* @return DateTime|false Returns the DateTime object for method chaining or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_modify (DateTime $object, string $modifier) {}
|
||||
function date_modify (DateTime $object, string $modifier): DateTime|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <methodname>DateTime::add</methodname>
|
||||
|
@ -1018,7 +1042,9 @@ function date_modify (DateTime $object, string $modifier) {}
|
|||
* {@see DateTime} object for method chaining or <b>FALSE</b> on failure.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_add (DateTime $object, DateInterval $interval) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "DateTime"], default: "DateTime|false")]
|
||||
function date_add (DateTime $object, DateInterval $interval)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Subtracts an amount of days, months, years, hours, minutes and seconds from a datetime object
|
||||
|
@ -1034,7 +1060,9 @@ function date_add (DateTime $object, DateInterval $interval) {}
|
|||
* {@see DateTime} object for method chaining or <b>FALSE</b> on failure.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_sub (DateTime $object, DateInterval $interval) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "DateTime"], default: "DateTime|false")]
|
||||
function date_sub (DateTime $object, DateInterval $interval)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -1052,7 +1080,8 @@ function date_sub (DateTime $object, DateInterval $interval) {}
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_timezone_get (DateTimeInterface $object) {}
|
||||
function date_timezone_get (DateTimeInterface $object): DateTimeZone|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets the time zone for the datetime object
|
||||
|
@ -1068,7 +1097,9 @@ function date_timezone_get (DateTimeInterface $object) {}
|
|||
* {@see DateTime} object for method chaining or <b>FALSE</b> on failure.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_timezone_set (DateTimeInterface $object, DateTimeZone $timezone) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "DateTime"], default: "DateTime|false")]
|
||||
function date_timezone_set (DateTimeInterface $object, DateTimeZone $timezone)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -1079,7 +1110,10 @@ function date_timezone_set (DateTimeInterface $object, DateTimeZone $timezone) {
|
|||
* @return int|false <p>Returns the timezone offset in seconds from UTC on success or <b>FALSE</b> on failure.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_offset_get (DateTimeInterface $object) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function date_offset_get (DateTimeInterface $object)
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
* Returns the difference between two datetime objects
|
||||
|
@ -1092,8 +1126,9 @@ function date_offset_get (DateTimeInterface $object) {}
|
|||
* @return DateInterval|false The DateInterval object representing the difference between the two dates or FALSE on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_diff (DateTimeInterface $baseObject, DateTimeInterface $targetObject, bool $absolute = false) {}
|
||||
|
||||
#[LanguageLevelTypeAware(["8.0" => "DateInterval"], default: "DateInterval|false")]
|
||||
function date_diff (DateTimeInterface $baseObject, DateTimeInterface $targetObject, bool $absolute = false)
|
||||
{}
|
||||
/**
|
||||
* &Alias; <methodname>DateTime::setTime</methodname>
|
||||
* @link https://php.net/manual/en/function.date-time-set.php
|
||||
|
@ -1102,11 +1137,11 @@ function date_diff (DateTimeInterface $baseObject, DateTimeInterface $targetObje
|
|||
* @param int $minute
|
||||
* @param int $second [optional]
|
||||
* @param int $microsecond [optional]
|
||||
* @return void <p>Returns the
|
||||
* @return DateTime <p>Returns the
|
||||
* {@see DateTime} object for method chaining or <b>FALSE</b> on failure.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_time_set (DateTime $object, int $hour, int $minute, int $second = 0, int $microsecond = 0) {}
|
||||
function date_time_set (DateTime $object, int $hour, int $minute, int $second = 0, int $microsecond = 0): DateTime {}
|
||||
|
||||
/**
|
||||
* &Alias; <methodname>DateTime::setDate</methodname>
|
||||
|
@ -1123,7 +1158,9 @@ function date_time_set (DateTime $object, int $hour, int $minute, int $second =
|
|||
* {@see DateTime} object for method chaining or <b>FALSE</b> on failure.
|
||||
* </p>
|
||||
*/
|
||||
function date_date_set (DateTime $object, int $year, int $month, int $day) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "DateTime"], default: "DateTime|false")]
|
||||
function date_date_set (DateTime $object, int $year, int $month, int $day): DateTime|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -1137,7 +1174,9 @@ function date_date_set (DateTime $object, int $year, int $month, int $day) {}
|
|||
* Returns the {@see DateTime} object for method chaining or <strong><code>FALSE</code></strong> on failure.
|
||||
* </p>
|
||||
*/
|
||||
function date_isodate_set (DateTime $object, int $year, int $week, int $dayOfWeek = 1) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "DateTime"], default: "DateTime|false")]
|
||||
function date_isodate_set (DateTime $object, int $year, int $week, int $dayOfWeek = 1)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets the date and time based on an unix timestamp
|
||||
|
@ -1150,7 +1189,9 @@ function date_isodate_set (DateTime $object, int $year, int $week, int $dayOfWee
|
|||
* @return DateTime|false
|
||||
* {@see DateTime} object for call chaining or <b>FALSE</b> on failure
|
||||
*/
|
||||
function date_timestamp_set (DateTime $object, int $timestamp) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "DateTime"], default: "DateTime|false")]
|
||||
function date_timestamp_set (DateTime $object, int $timestamp): DateTime|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the unix timestamp
|
||||
|
@ -1161,7 +1202,8 @@ function date_timestamp_set (DateTime $object, int $timestamp) {}
|
|||
* @return int <p>Returns the Unix timestamp representing the date.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_timestamp_get (DateTimeInterface $object) {}
|
||||
function date_timestamp_get (DateTimeInterface $object): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns new DateTimeZone object
|
||||
|
@ -1173,7 +1215,8 @@ function date_timestamp_get (DateTimeInterface $object) {}
|
|||
* @return DateTimeZone|false DateTimeZone object on success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_open (string $timezone) {}
|
||||
function timezone_open (string $timezone): DateTimeZone|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias: {@see DateTimeZone::getName}
|
||||
|
@ -1183,7 +1226,8 @@ function timezone_open (string $timezone) {}
|
|||
* @return string One of the timezone names in the list of timezones.
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_name_get (DateTimeZone $object) {}
|
||||
function timezone_name_get (DateTimeZone $object): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the timezone name from abbreviation
|
||||
|
@ -1206,7 +1250,7 @@ function timezone_name_get (DateTimeZone $object) {}
|
|||
* @since 5.1.3
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_name_from_abbr (string $abbr, int $utcOffset, int $isDST)
|
||||
function timezone_name_from_abbr (string $abbr, int $utcOffset, int $isDST): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1221,7 +1265,9 @@ function timezone_name_from_abbr (string $abbr, int $utcOffset, int $isDST)
|
|||
* @return int|false <p>Returns time zone offset in seconds on success or <b>FALSE</b> on failure.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_offset_get (DateTimeZone $object, DateTimeInterface $datetime) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function timezone_offset_get (DateTimeZone $object, DateTimeInterface $datetime)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns all transitions for the timezone
|
||||
|
@ -1236,16 +1282,18 @@ function timezone_offset_get (DateTimeZone $object, DateTimeInterface $datetime)
|
|||
* @return array|false <p>Returns numerically indexed array containing associative array with all transitions on success or FALSE on failure.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_transitions_get (DateTimeZone $object, int $timestampBegin, int $timestampEnd) {}
|
||||
function timezone_transitions_get (DateTimeZone $object, int $timestampBegin, int $timestampEnd): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; {@see DateTimeZone::getLocation}
|
||||
* @link https://php.net/manual/en/function.timezone-location-get.php
|
||||
* @param DateTimeZone $object <p>Procedural style only: A {@see DateTimeZone} object returned by {@see timezone_open()}
|
||||
* @return array <p>Array containing location information about timezone.</p>
|
||||
* @return array|false <p>Array containing location information about timezone.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_location_get (DateTimeZone $object) {}
|
||||
function timezone_location_get (DateTimeZone $object): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns a numerically indexed array containing all defined timezone identifiers
|
||||
|
@ -1258,7 +1306,9 @@ function timezone_location_get (DateTimeZone $object) {}
|
|||
* Note: This option is only used when what is set to DateTimeZone::PER_COUNTRY.
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_identifiers_list (int $timezoneGroup = DateTimeZone::ALL, string $countryCode) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")]
|
||||
function timezone_identifiers_list (int $timezoneGroup = DateTimeZone::ALL, string $countryCode)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns associative array containing dst, offset and the timezone name
|
||||
|
@ -1268,7 +1318,9 @@ function timezone_identifiers_list (int $timezoneGroup = DateTimeZone::ALL, stri
|
|||
* @return array|false Array on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_abbreviations_list () {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")]
|
||||
function timezone_abbreviations_list ()
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the version of the timezonedb
|
||||
|
@ -1276,7 +1328,8 @@ function timezone_abbreviations_list () {}
|
|||
* @return string a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_version_get () {}
|
||||
function timezone_version_get (): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -1286,21 +1339,23 @@ function timezone_version_get () {}
|
|||
* {@see strtotime()} and
|
||||
* {@see DateTime} will be used to construct the
|
||||
* {@see DateInterval}.</p>
|
||||
* @return DateInterval
|
||||
* @return DateInterval|false
|
||||
* <p>Returns a new DateInterval instance.</p>
|
||||
*/
|
||||
#[Pure]
|
||||
function date_interval_create_from_date_string (string $datetime) {}
|
||||
function date_interval_create_from_date_string (string $datetime): DateInterval|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <methodname>DateInterval::format</methodname>
|
||||
* @link https://php.net/manual/en/function.date-interval-format.php
|
||||
* @param DateInterval $object
|
||||
* @param string $format
|
||||
* @return DateInterval
|
||||
* @return string
|
||||
*/
|
||||
#[Pure]
|
||||
function date_interval_format (DateInterval $object, string $format) {}
|
||||
function date_interval_format (DateInterval $object, string $format): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets the default timezone used by all date/time functions in a script
|
||||
|
@ -1323,7 +1378,8 @@ function date_default_timezone_set (string $timezoneId): bool
|
|||
* @return string a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_default_timezone_get () {}
|
||||
function date_default_timezone_get (): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns time of sunrise for a given day and location
|
||||
|
@ -1369,11 +1425,12 @@ function date_default_timezone_get () {}
|
|||
* Default: date.sunrise_zenith
|
||||
* </p>
|
||||
* @param float $utcOffset [optional]
|
||||
* @return mixed the sunrise time in a specified format on
|
||||
* @return string|int|float|false the sunrise time in a specified format on
|
||||
* success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_sunrise (int $timestamp, int $returnFormat, float $latitude, float $longitude, float $zenith, float $utcOffset) {}
|
||||
function date_sunrise (int $timestamp, int $returnFormat, float $latitude, float $longitude, float $zenith, float $utcOffset): string|int|float|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns time of sunset for a given day and location
|
||||
|
@ -1419,11 +1476,12 @@ function date_sunrise (int $timestamp, int $returnFormat, float $latitude, float
|
|||
* Default: date.sunset_zenith
|
||||
* </p>
|
||||
* @param float $utcOffset [optional]
|
||||
* @return mixed the sunset time in a specified format on
|
||||
* @return string|int|float|false the sunset time in a specified format on
|
||||
* success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function date_sunset (int $timestamp, int $returnFormat, float $latitude, float $longitude, float $zenith, float $utcOffset) {}
|
||||
function date_sunset (int $timestamp, int $returnFormat, float $latitude, float $longitude, float $zenith, float $utcOffset): string|int|float|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns an array with information about sunset/sunrise and twilight begin/end
|
||||
|
@ -1441,6 +1499,8 @@ function date_sunset (int $timestamp, int $returnFormat, float $latitude, float
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[Pure]
|
||||
function date_sun_info (int $timestamp, float $latitude, float $longitude) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")]
|
||||
function date_sun_info (int $timestamp, float $latitude, float $longitude)
|
||||
{}
|
||||
|
||||
// End of date v.5.3.2-0.dotdeb.1
|
||||
|
|
45
dba/dba.php
45
dba/dba.php
|
@ -155,7 +155,7 @@ function dba_popen ($path, $mode, $handler, ...$handler_params)
|
|||
* </p>
|
||||
* @return void No value is returned.
|
||||
*/
|
||||
function dba_close ($dba) {}
|
||||
function dba_close ($dba): void {}
|
||||
|
||||
/**
|
||||
* Delete DBA entry specified by key
|
||||
|
@ -169,7 +169,8 @@ function dba_close ($dba) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function dba_delete ($key, $dba) {}
|
||||
function dba_delete ($key, $dba): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check whether key exists
|
||||
|
@ -183,7 +184,8 @@ function dba_delete ($key, $dba) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> if the key exists, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
function dba_exists ($key, $dba) {}
|
||||
function dba_exists ($key, $dba): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Fetch data specified by key
|
||||
|
@ -203,7 +205,8 @@ function dba_exists ($key, $dba) {}
|
|||
* @return string|false the associated string if the key/data pair is found, <b>FALSE</b>
|
||||
* otherwise.
|
||||
*/
|
||||
function dba_fetch ($key, $handle) {}
|
||||
function dba_fetch ($key, $handle): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Fetch data specified by key
|
||||
|
@ -224,7 +227,8 @@ function dba_fetch ($key, $handle) {}
|
|||
* @return string|false the associated string if the key/data pair is found, <b>FALSE</b>
|
||||
* otherwise.
|
||||
*/
|
||||
function dba_fetch ($key, $skip, $dba) {}
|
||||
function dba_fetch ($key, $skip, $dba): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Insert entry
|
||||
|
@ -243,7 +247,8 @@ function dba_fetch ($key, $skip, $dba) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function dba_insert ($key, string $value, $dba) {}
|
||||
function dba_insert ($key, string $value, $dba): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Replace or insert entry
|
||||
|
@ -260,7 +265,8 @@ function dba_insert ($key, string $value, $dba) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function dba_replace ($key, string $value, $dba) {}
|
||||
function dba_replace ($key, string $value, $dba): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Fetch first key
|
||||
|
@ -269,9 +275,10 @@ function dba_replace ($key, string $value, $dba) {}
|
|||
* The database handler, returned by <b>dba_open</b> or
|
||||
* <b>dba_popen</b>.
|
||||
* </p>
|
||||
* @return string the key on success or <b>FALSE</b> on failure.
|
||||
* @return string|false the key on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function dba_firstkey ($dba) {}
|
||||
function dba_firstkey ($dba): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Fetch next key
|
||||
|
@ -280,9 +287,10 @@ function dba_firstkey ($dba) {}
|
|||
* The database handler, returned by <b>dba_open</b> or
|
||||
* <b>dba_popen</b>.
|
||||
* </p>
|
||||
* @return string the key on success or <b>FALSE</b> on failure.
|
||||
* @return string|false the key on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function dba_nextkey ($dba) {}
|
||||
function dba_nextkey ($dba): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Optimize database
|
||||
|
@ -293,7 +301,8 @@ function dba_nextkey ($dba) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function dba_optimize ($dba) {}
|
||||
function dba_optimize ($dba): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Synchronize database
|
||||
|
@ -304,7 +313,8 @@ function dba_optimize ($dba) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function dba_sync ($dba) {}
|
||||
function dba_sync ($dba): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* List all the handlers available
|
||||
|
@ -321,14 +331,16 @@ function dba_sync ($dba) {}
|
|||
* When the internal cdb library is used you will see
|
||||
* cdb and cdb_make.
|
||||
*/
|
||||
function dba_handlers (bool $full_info = false) {}
|
||||
function dba_handlers (bool $full_info = false): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* List all open database files
|
||||
* @link https://php.net/manual/en/function.dba-list.php
|
||||
* @return array An associative array, in the form resourceid => filename.
|
||||
*/
|
||||
function dba_list () {}
|
||||
function dba_list (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Splits a key in string representation into array representation
|
||||
|
@ -340,6 +352,7 @@ function dba_list () {}
|
|||
* value_name). This function will return <b>FALSE</b> if
|
||||
* <i>key</i> is <b>NULL</b> or <b>FALSE</b>.
|
||||
*/
|
||||
function dba_key_split (string|false|null $key) {}
|
||||
function dba_key_split (string|false|null $key): array|false
|
||||
{}
|
||||
|
||||
// End of dba v.
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
* </p>
|
||||
* @return DOMElement|false The <b>DOMElement</b> node added or <b>FALSE</b> if any errors occur.
|
||||
*/
|
||||
function dom_import_simplexml (object $node) {}
|
||||
function dom_import_simplexml (object $node): DOMElement {}
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -11,7 +11,7 @@ use JetBrains\PhpStorm\Deprecated;
|
|||
* Since 7.2.0 this can either be a path to the file (stream wrappers are also supported as usual)
|
||||
* or a stream resource.
|
||||
* </p>
|
||||
* @param null $required_sections [optional] <p>
|
||||
* @param string $required_sections [optional] <p>
|
||||
* Is a comma separated list of sections that need to be present in file
|
||||
* to produce a result array. If none of the requested
|
||||
* sections could be found the return value is <b>FALSE</b>.
|
||||
|
@ -72,12 +72,12 @@ use JetBrains\PhpStorm\Deprecated;
|
|||
* When set to <b>TRUE</b> the thumbnail itself is read. Otherwise, only the
|
||||
* tagged data is read.
|
||||
* </p>
|
||||
* @return array It returns an associative array where the array indexes are
|
||||
* @return array|false It returns an associative array where the array indexes are
|
||||
* the header names and the array values are the values associated with
|
||||
* those headers. If no data can be returned,
|
||||
* <b>exif_read_data</b> will return <b>FALSE</b>.
|
||||
*/
|
||||
function exif_read_data ($file, string $required_sections, bool $as_arrays = false, bool $read_thumbnail = false)
|
||||
function exif_read_data ($file, string $required_sections, bool $as_arrays = false, bool $read_thumbnail = false): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -101,7 +101,7 @@ function read_exif_data ($filename, $sections = null, $arrays = false, $thumbnai
|
|||
* @return string|false the header name, or <b>FALSE</b> if <i>index</i> is
|
||||
* not a defined EXIF tag id.
|
||||
*/
|
||||
function exif_tagname (int $index) {}
|
||||
function exif_tagname (int $index): string|false {}
|
||||
|
||||
/**
|
||||
* Retrieve the embedded thumbnail of a TIFF or JPEG image
|
||||
|
@ -124,7 +124,7 @@ function exif_tagname (int $index) {}
|
|||
* @return string|false the embedded thumbnail, or <b>FALSE</b> if the image contains no
|
||||
* thumbnail.
|
||||
*/
|
||||
function exif_thumbnail ($file, &$width, &$height, &$image_type) {}
|
||||
function exif_thumbnail ($file, &$width, &$height, &$image_type): string|false {}
|
||||
|
||||
/**
|
||||
* Determine the type of an image
|
||||
|
@ -140,7 +140,7 @@ function exif_thumbnail ($file, &$width, &$height, &$image_type) {}
|
|||
* and return <b>FALSE</b> if it is unable to read enough bytes from the file to
|
||||
* determine the image type.
|
||||
*/
|
||||
function exif_imagetype (string $filename) {}
|
||||
function exif_imagetype (string $filename): int|false {}
|
||||
|
||||
define ('EXIF_USE_MBSTRING', 1);
|
||||
|
||||
|
|
|
@ -82,7 +82,8 @@ class finfo {
|
|||
* </p>
|
||||
* @return resource|false a magic database resource on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function finfo_open (int $flags, string $magic_database) {}
|
||||
function finfo_open (int $flags, string $magic_database)
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL fileinfo >= 0.1.0)<br/>
|
||||
|
@ -93,7 +94,8 @@ function finfo_open (int $flags, string $magic_database) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function finfo_close ($finfo) {}
|
||||
function finfo_close ($finfo): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL fileinfo >= 0.1.0)<br/>
|
||||
|
@ -108,7 +110,8 @@ function finfo_close ($finfo) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function finfo_set_flags ($finfo, int $flags) {}
|
||||
function finfo_set_flags ($finfo, int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL fileinfo >= 0.1.0)<br/>
|
||||
|
@ -127,10 +130,10 @@ function finfo_set_flags ($finfo, int $flags) {}
|
|||
* @param resource $context [optional] <p>
|
||||
* For a description of contexts, refer to .
|
||||
* </p>
|
||||
* @return mixed a textual description of the contents of the
|
||||
* @return string|false a textual description of the contents of the
|
||||
* <i>filename</i> argument, or <b>FALSE</b> if an error occurred.
|
||||
*/
|
||||
function finfo_file ($finfo, string $filename, int $flags, $context)
|
||||
function finfo_file ($finfo, string $filename, int $flags, $context): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -156,7 +159,8 @@ function finfo_file ($finfo, string $filename, int $flags, $context)
|
|||
* @return string|false a textual description of the <i>string</i>
|
||||
* argument, or <b>FALSE</b> if an error occurred.
|
||||
*/
|
||||
function finfo_buffer ($finfo , string $string, int $flags = FILEINFO_NONE, $context) {}
|
||||
function finfo_buffer ($finfo , string $string, int $flags = FILEINFO_NONE, $context): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Detect MIME Content-type for a file
|
||||
|
@ -164,10 +168,11 @@ function finfo_buffer ($finfo , string $string, int $flags = FILEINFO_NONE, $con
|
|||
* @param string $filename <p>
|
||||
* Path to the tested file.
|
||||
* </p>
|
||||
* @return string the content type in MIME format, like
|
||||
* @return string|false the content type in MIME format, like
|
||||
* text/plain or application/octet-stream.
|
||||
*/
|
||||
function mime_content_type ($filename) {}
|
||||
function mime_content_type ($filename): string|false
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -28,7 +28,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* returns <b>FALSE</b> if the variable is not set and <b>NULL</b> if the filter fails.
|
||||
*/
|
||||
#[Pure]
|
||||
function filter_input (int $type, string $var_name, int $filter = FILTER_DEFAULT, array|int $options) {}
|
||||
function filter_input (int $type, string $var_name, int $filter = FILTER_DEFAULT, array|int $options): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Filters a variable with a specified filter
|
||||
|
@ -84,7 +85,8 @@ function filter_input (int $type, string $var_name, int $filter = FILTER_DEFAULT
|
|||
* @return mixed the filtered data, or <b>FALSE</b> if the filter fails.
|
||||
*/
|
||||
#[Pure]
|
||||
function filter_var (mixed $value, int $filter = FILTER_DEFAULT, array|int $options) {}
|
||||
function filter_var (mixed $value, int $filter = FILTER_DEFAULT, array|int $options): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets external variables and optionally filters them
|
||||
|
@ -111,14 +113,15 @@ function filter_var (mixed $value, int $filter = FILTER_DEFAULT, array|int $opti
|
|||
* @param bool $add_empty [optional] <p>
|
||||
* Add missing keys as <b>NULL</b> to the return value.
|
||||
* </p>
|
||||
* @return mixed An array containing the values of the requested variables on success, or <b>FALSE</b>
|
||||
* @return array|false|null An array containing the values of the requested variables on success, or <b>FALSE</b>
|
||||
* on failure. An array value will be <b>FALSE</b> if the filter fails, or <b>NULL</b> if
|
||||
* the variable is not set. Or if the flag <b>FILTER_NULL_ON_FAILURE</b>
|
||||
* is used, it returns <b>FALSE</b> if the variable is not set and <b>NULL</b> if the filter
|
||||
* fails.
|
||||
*/
|
||||
#[Pure]
|
||||
function filter_input_array (int $type, array|int $options, bool $add_empty = true) {}
|
||||
function filter_input_array (int $type, array|int $options, bool $add_empty = true): array|false|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets multiple variables and optionally filters them
|
||||
|
@ -144,12 +147,13 @@ function filter_input_array (int $type, array|int $options, bool $add_empty = tr
|
|||
* @param bool $add_empty [optional] <p>
|
||||
* Add missing keys as <b>NULL</b> to the return value.
|
||||
* </p>
|
||||
* @return mixed An array containing the values of the requested variables on success, or <b>FALSE</b>
|
||||
* @return array|false|null An array containing the values of the requested variables on success, or <b>FALSE</b>
|
||||
* on failure. An array value will be <b>FALSE</b> if the filter fails, or <b>NULL</b> if
|
||||
* the variable is not set.
|
||||
*/
|
||||
#[Pure]
|
||||
function filter_var_array (array $array, array|int $options, bool $add_empty = true) {}
|
||||
function filter_var_array (array $array, array|int $options, bool $add_empty = true): array|false|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns a list of all supported filters
|
||||
|
@ -159,7 +163,8 @@ function filter_var_array (array $array, array|int $options, bool $add_empty = t
|
|||
* obtained with <b>filter_id</b> from a name instead.
|
||||
*/
|
||||
#[Pure]
|
||||
function filter_list () {}
|
||||
function filter_list (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if variable of specified type exists
|
||||
|
@ -175,7 +180,8 @@ function filter_list () {}
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function filter_has_var (int $input_type, string $var_name) {}
|
||||
function filter_has_var (int $input_type, string $var_name): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the filter ID belonging to a named filter
|
||||
|
@ -186,7 +192,8 @@ function filter_has_var (int $input_type, string $var_name) {}
|
|||
* @return int|false ID of a filter on success or <b>FALSE</b> if filter doesn't exist.
|
||||
*/
|
||||
#[Pure]
|
||||
function filter_id (string $name) {}
|
||||
function filter_id (string $name): int|false
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
|
|
115
ftp/ftp.php
115
ftp/ftp.php
|
@ -11,16 +11,18 @@
|
|||
* @return bool
|
||||
* @since 7.2
|
||||
*/
|
||||
function ftp_append ($ftp, string $remote_filename, string $local_filename, int $mode = FTP_BINARY){}
|
||||
function ftp_append ($ftp, string $remote_filename, string $local_filename, int $mode = FTP_BINARY): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* returns a list of files in the given directory
|
||||
* @param resource $ftp
|
||||
* @param string $directory
|
||||
* @return array
|
||||
* @return array|false
|
||||
* @since 7.2
|
||||
*/
|
||||
function ftp_mlsd ($ftp, string $directory) {}
|
||||
function ftp_mlsd ($ftp, string $directory): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Opens an FTP connection
|
||||
|
@ -41,7 +43,8 @@ function ftp_mlsd ($ftp, string $directory) {}
|
|||
* </p>
|
||||
* @return resource|false a FTP stream on success or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ftp_connect (string $hostname, int $port = 21, int $timeout = 90) {}
|
||||
function ftp_connect (string $hostname, int $port = 21, int $timeout = 90)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Opens a Secure SSL-FTP connection
|
||||
|
@ -62,7 +65,8 @@ function ftp_connect (string $hostname, int $port = 21, int $timeout = 90) {}
|
|||
* </p>
|
||||
* @return resource|false a SSL-FTP stream on success or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ftp_ssl_connect (string $hostname, int $port = 21, int $timeout = 90) {}
|
||||
function ftp_ssl_connect (string $hostname, int $port = 21, int $timeout = 90)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Logs in to an FTP connection
|
||||
|
@ -79,7 +83,8 @@ function ftp_ssl_connect (string $hostname, int $port = 21, int $timeout = 90) {
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* If login fails, PHP will also throw a warning.
|
||||
*/
|
||||
function ftp_login ($ftp, string $username, string $password) {}
|
||||
function ftp_login ($ftp, string $username, string $password): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the current directory name
|
||||
|
@ -89,7 +94,8 @@ function ftp_login ($ftp, string $username, string $password) {}
|
|||
* </p>
|
||||
* @return string|false the current directory name or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ftp_pwd ($ftp) {}
|
||||
function ftp_pwd ($ftp): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Changes to the parent directory
|
||||
|
@ -99,7 +105,8 @@ function ftp_pwd ($ftp) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_cdup ($ftp) {}
|
||||
function ftp_cdup ($ftp): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Changes the current directory on a FTP server
|
||||
|
@ -113,7 +120,8 @@ function ftp_cdup ($ftp) {}
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* If changing directory fails, PHP will also throw a warning.
|
||||
*/
|
||||
function ftp_chdir ($ftp, string $directory) {}
|
||||
function ftp_chdir ($ftp, string $directory): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Requests execution of a command on the FTP server
|
||||
|
@ -127,7 +135,8 @@ function ftp_chdir ($ftp, string $directory) {}
|
|||
* @return bool <b>TRUE</b> if the command was successful (server sent response code:
|
||||
* 200); otherwise returns <b>FALSE</b>.
|
||||
*/
|
||||
function ftp_exec ($ftp, string $command) {}
|
||||
function ftp_exec ($ftp, string $command): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sends an arbitrary command to an FTP server
|
||||
|
@ -142,7 +151,8 @@ function ftp_exec ($ftp, string $command) {}
|
|||
* No parsing is performed on the response string, nor does
|
||||
* <b>ftp_raw</b> determine if the command succeeded.
|
||||
*/
|
||||
function ftp_raw ($ftp, string $command) {}
|
||||
function ftp_raw ($ftp, string $command): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Creates a directory
|
||||
|
@ -155,7 +165,8 @@ function ftp_raw ($ftp, string $command) {}
|
|||
* </p>
|
||||
* @return string|false the newly created directory name on success or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ftp_mkdir ($ftp, string $directory) {}
|
||||
function ftp_mkdir ($ftp, string $directory): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Removes a directory
|
||||
|
@ -169,7 +180,8 @@ function ftp_mkdir ($ftp, string $directory) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_rmdir ($ftp, string $directory) {}
|
||||
function ftp_rmdir ($ftp, string $directory): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set permissions on a file via FTP
|
||||
|
@ -185,7 +197,8 @@ function ftp_rmdir ($ftp, string $directory) {}
|
|||
* </p>
|
||||
* @return int|false the new file permissions on success or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ftp_chmod ($ftp, int $permissions, string $filename) {}
|
||||
function ftp_chmod ($ftp, int $permissions, string $filename): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Allocates space for a file to be uploaded
|
||||
|
@ -202,7 +215,7 @@ function ftp_chmod ($ftp, int $permissions, string $filename) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_alloc ($ftp, int $size, &$response)
|
||||
function ftp_alloc ($ftp, int $size, &$response): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -220,7 +233,8 @@ function ftp_alloc ($ftp, int $size, &$response)
|
|||
* @return array|false an array of filenames from the specified directory on success or
|
||||
* <b>FALSE</b> on error.
|
||||
*/
|
||||
function ftp_nlist ($ftp, string $directory) {}
|
||||
function ftp_nlist ($ftp, string $directory): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns a detailed list of files in the given directory
|
||||
|
@ -235,14 +249,15 @@ function ftp_nlist ($ftp, string $directory) {}
|
|||
* @param bool $recursive [optional] <p>
|
||||
* If set to <b>TRUE</b>, the issued command will be LIST -R.
|
||||
* </p>
|
||||
* @return array an array where each element corresponds to one line of text.
|
||||
* @return array|false an array where each element corresponds to one line of text.
|
||||
* </p>
|
||||
* <p>
|
||||
* The output is not parsed in any way. The system type identifier returned by
|
||||
* <b>ftp_systype</b> can be used to determine how the results
|
||||
* should be interpreted.
|
||||
*/
|
||||
function ftp_rawlist ($ftp, string $directory, bool $recursive = false) {}
|
||||
function ftp_rawlist ($ftp, string $directory, bool $recursive = false): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the system type identifier of the remote FTP server
|
||||
|
@ -252,7 +267,8 @@ function ftp_rawlist ($ftp, string $directory, bool $recursive = false) {}
|
|||
* </p>
|
||||
* @return string|false the remote system type, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ftp_systype ($ftp) {}
|
||||
function ftp_systype ($ftp): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Turns passive mode on or off
|
||||
|
@ -265,7 +281,8 @@ function ftp_systype ($ftp) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_pasv ($ftp, bool $enable) {}
|
||||
function ftp_pasv ($ftp, bool $enable): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Downloads a file from the FTP server
|
||||
|
@ -288,7 +305,8 @@ function ftp_pasv ($ftp, bool $enable) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_get ($ftp, string $local_filename, string $remote_filename, int $mode = FTP_BINARY, int $offset = 0) {}
|
||||
function ftp_get ($ftp, string $local_filename, string $remote_filename, int $mode = FTP_BINARY, int $offset = 0): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Downloads a file from the FTP server and saves to an open file
|
||||
|
@ -311,7 +329,8 @@ function ftp_get ($ftp, string $local_filename, string $remote_filename, int $mo
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_fget ($ftp, $stream, string $remote_filename, int $mode = FTP_BINARY, int $offset = 0) {}
|
||||
function ftp_fget ($ftp, $stream, string $remote_filename, int $mode = FTP_BINARY, int $offset = 0): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Uploads a file to the FTP server
|
||||
|
@ -332,7 +351,8 @@ function ftp_fget ($ftp, $stream, string $remote_filename, int $mode = FTP_BINAR
|
|||
* @param int $offset [optional] <p>The position in the remote file to start uploading to.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_put ($ftp, string $remote_filename, string $local_filename, int $mode = FTP_BINARY, int $offset = 0) {}
|
||||
function ftp_put ($ftp, string $remote_filename, string $local_filename, int $mode = FTP_BINARY, int $offset = 0): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Uploads from an open file to the FTP server
|
||||
|
@ -353,7 +373,8 @@ function ftp_put ($ftp, string $remote_filename, string $local_filename, int $mo
|
|||
* @param int $offset [optional] <p>The position in the remote file to start uploading to.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_fput ($ftp, string $remote_filename, $stream, int $mode = FTP_BINARY, int $offset = 0) {}
|
||||
function ftp_fput ($ftp, string $remote_filename, $stream, int $mode = FTP_BINARY, int $offset = 0): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the size of the given file
|
||||
|
@ -366,7 +387,8 @@ function ftp_fput ($ftp, string $remote_filename, $stream, int $mode = FTP_BINAR
|
|||
* </p>
|
||||
* @return int the file size on success, or -1 on error.
|
||||
*/
|
||||
function ftp_size ($ftp, string $filename) {}
|
||||
function ftp_size ($ftp, string $filename): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the last modified time of the given file
|
||||
|
@ -380,7 +402,8 @@ function ftp_size ($ftp, string $filename) {}
|
|||
* @return int the last modified time as a Unix timestamp on success, or -1 on
|
||||
* error.
|
||||
*/
|
||||
function ftp_mdtm ($ftp, string $filename) {}
|
||||
function ftp_mdtm ($ftp, string $filename): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Renames a file or a directory on the FTP server
|
||||
|
@ -396,7 +419,8 @@ function ftp_mdtm ($ftp, string $filename) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_rename ($ftp, string $from, string $to) {}
|
||||
function ftp_rename ($ftp, string $from, string $to): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Deletes a file on the FTP server
|
||||
|
@ -409,7 +433,8 @@ function ftp_rename ($ftp, string $from, string $to) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_delete ($ftp, string $filename) {}
|
||||
function ftp_delete ($ftp, string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sends a SITE command to the server
|
||||
|
@ -423,7 +448,8 @@ function ftp_delete ($ftp, string $filename) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_site ($ftp, string $command) {}
|
||||
function ftp_site ($ftp, string $command): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Closes an FTP connection
|
||||
|
@ -433,7 +459,8 @@ function ftp_site ($ftp, string $command) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_close ($ftp) {}
|
||||
function ftp_close ($ftp): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set miscellaneous runtime FTP options
|
||||
|
@ -473,7 +500,8 @@ function ftp_close ($ftp) {}
|
|||
* supported or the passed <i>value</i> doesn't match the
|
||||
* expected value for the given <i>option</i>.
|
||||
*/
|
||||
function ftp_set_option ($ftp, int $option, $value) {}
|
||||
function ftp_set_option ($ftp, int $option, $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieves various runtime behaviours of the current FTP stream
|
||||
|
@ -499,11 +527,12 @@ function ftp_set_option ($ftp, int $option, $value) {}
|
|||
* </tr>
|
||||
* </table>
|
||||
* </p>
|
||||
* @return mixed the value on success or <b>FALSE</b> if the given
|
||||
* @return int|bool the value on success or <b>FALSE</b> if the given
|
||||
* <i>option</i> is not supported. In the latter case, a
|
||||
* warning message is also thrown.
|
||||
*/
|
||||
function ftp_get_option ($ftp, int $option) {}
|
||||
function ftp_get_option ($ftp, int $option): int|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieves a file from the FTP server and writes it to an open file (non-blocking)
|
||||
|
@ -525,7 +554,8 @@ function ftp_get_option ($ftp, int $option) {}
|
|||
* @return int <b>FTP_FAILED</b> or <b>FTP_FINISHED</b>
|
||||
* or <b>FTP_MOREDATA</b>.
|
||||
*/
|
||||
function ftp_nb_fget ($ftp, $stream, string $remote_filename, int $mode = FTP_BINARY, int $offset = 0) {}
|
||||
function ftp_nb_fget ($ftp, $stream, string $remote_filename, int $mode = FTP_BINARY, int $offset = 0): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieves a file from the FTP server and writes it to a local file (non-blocking)
|
||||
|
@ -547,7 +577,8 @@ function ftp_nb_fget ($ftp, $stream, string $remote_filename, int $mode = FTP_BI
|
|||
* @return int <b>FTP_FAILED</b> or <b>FTP_FINISHED</b>
|
||||
* or <b>FTP_MOREDATA</b>.
|
||||
*/
|
||||
function ftp_nb_get ($ftp, string $local_filename, string $remote_filename, int $mode = FTP_BINARY, int $offset = 0) {}
|
||||
function ftp_nb_get ($ftp, string $local_filename, string $remote_filename, int $mode = FTP_BINARY, int $offset = 0): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Continues retrieving/sending a file (non-blocking)
|
||||
|
@ -558,7 +589,8 @@ function ftp_nb_get ($ftp, string $local_filename, string $remote_filename, int
|
|||
* @return int <b>FTP_FAILED</b> or <b>FTP_FINISHED</b>
|
||||
* or <b>FTP_MOREDATA</b>.
|
||||
*/
|
||||
function ftp_nb_continue ($ftp) {}
|
||||
function ftp_nb_continue ($ftp): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Stores a file on the FTP server (non-blocking)
|
||||
|
@ -577,10 +609,11 @@ function ftp_nb_continue ($ftp) {}
|
|||
* <b>FTP_BINARY</b>.
|
||||
* </p>
|
||||
* @param int $offset [optional] <p>The position in the remote file to start uploading to.</p>
|
||||
* @return int <b>FTP_FAILED</b> or <b>FTP_FINISHED</b>
|
||||
* @return int|false <b>FTP_FAILED</b> or <b>FTP_FINISHED</b>
|
||||
* or <b>FTP_MOREDATA</b>.
|
||||
*/
|
||||
function ftp_nb_put ($ftp, string $remote_filename, string $local_filename, int $mode = FTP_BINARY, int $offset = 0) {}
|
||||
function ftp_nb_put ($ftp, string $remote_filename, string $local_filename, int $mode = FTP_BINARY, int $offset = 0): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Stores a file from an open file to the FTP server (non-blocking)
|
||||
|
@ -602,7 +635,8 @@ function ftp_nb_put ($ftp, string $remote_filename, string $local_filename, int
|
|||
* @return int <b>FTP_FAILED</b> or <b>FTP_FINISHED</b>
|
||||
* or <b>FTP_MOREDATA</b>.
|
||||
*/
|
||||
function ftp_nb_fput ($ftp, string $remote_filename, $stream, int $mode = FTP_BINARY, int $offset = 0) {}
|
||||
function ftp_nb_fput ($ftp, string $remote_filename, $stream, int $mode = FTP_BINARY, int $offset = 0): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias of <b>ftp_close</b>
|
||||
|
@ -610,7 +644,8 @@ function ftp_nb_fput ($ftp, string $remote_filename, $stream, int $mode = FTP_BI
|
|||
* @param resource $ftp
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ftp_quit ($ftp) {}
|
||||
function ftp_quit ($ftp): bool
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -13,7 +13,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @return string If successful, this function returns the current message
|
||||
* domain, after possibly changing it.
|
||||
*/
|
||||
function textdomain (string $domain) {}
|
||||
function textdomain (string $domain): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Lookup a message in the current domain
|
||||
|
@ -25,7 +26,8 @@ function textdomain (string $domain) {}
|
|||
* translation table, or the submitted message if not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function _ (string $message) {}
|
||||
function _ (string $message): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Lookup a message in the current domain
|
||||
|
@ -37,7 +39,8 @@ function _ (string $message) {}
|
|||
* translation table, or the submitted message if not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function gettext (string $message) {}
|
||||
function gettext (string $message): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Override the current domain
|
||||
|
@ -50,7 +53,8 @@ function gettext (string $message) {}
|
|||
* </p>
|
||||
* @return string A string on success.
|
||||
*/
|
||||
function dgettext (string $domain, string $message) {}
|
||||
function dgettext (string $domain, string $message): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Overrides the domain for a single lookup
|
||||
|
@ -66,7 +70,8 @@ function dgettext (string $domain, string $message) {}
|
|||
* </p>
|
||||
* @return string A string on success.
|
||||
*/
|
||||
function dcgettext (string $domain, string $message, int $category) {}
|
||||
function dcgettext (string $domain, string $message, int $category): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets the path for a domain
|
||||
|
@ -77,9 +82,10 @@ function dcgettext (string $domain, string $message, int $category) {}
|
|||
* @param string $directory <p>
|
||||
* The directory path
|
||||
* </p>
|
||||
* @return string The full pathname for the <i>domain</i> currently being set.
|
||||
* @return string|false The full pathname for the <i>domain</i> currently being set.
|
||||
*/
|
||||
function bindtextdomain (string $domain, string $directory) {}
|
||||
function bindtextdomain (string $domain, string $directory): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Plural version of gettext
|
||||
|
@ -92,7 +98,8 @@ function bindtextdomain (string $domain, string $directory) {}
|
|||
* for count <i>n</i>.
|
||||
*/
|
||||
#[Pure]
|
||||
function ngettext (string $singular, string $plural, int $count) {}
|
||||
function ngettext (string $singular, string $plural, int $count): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Plural version of dgettext
|
||||
|
@ -106,7 +113,8 @@ function ngettext (string $singular, string $plural, int $count) {}
|
|||
* @return string A string on success.
|
||||
*/
|
||||
#[Pure]
|
||||
function dngettext (string $domain, string $singular, string $plural, int $count) {}
|
||||
function dngettext (string $domain, string $singular, string $plural, int $count): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Plural version of dcgettext
|
||||
|
@ -121,7 +129,8 @@ function dngettext (string $domain, string $singular, string $plural, int $count
|
|||
* @return string A string on success.
|
||||
*/
|
||||
#[Pure]
|
||||
function dcngettext (string $domain, string $singular, string $plural, int $count, int $category) {}
|
||||
function dcngettext (string $domain, string $singular, string $plural, int $count, int $category): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Specify the character encoding in which the messages from the DOMAIN message catalog will be returned
|
||||
|
@ -132,9 +141,10 @@ function dcngettext (string $domain, string $singular, string $plural, int $coun
|
|||
* @param string $codeset <p>
|
||||
* The code set
|
||||
* </p>
|
||||
* @return string A string on success.
|
||||
* @return string|false A string on success.
|
||||
*/
|
||||
function bind_textdomain_codeset (string $domain, string $codeset) {}
|
||||
function bind_textdomain_codeset (string $domain, string $codeset): string|false
|
||||
{}
|
||||
|
||||
// End of gettext v.
|
||||
?>
|
||||
|
|
|
@ -17,12 +17,13 @@ use JetBrains\PhpStorm\Pure;
|
|||
* When set to <b>TRUE</b>, outputs raw binary data.
|
||||
* <b>FALSE</b> outputs lowercase hexits.
|
||||
* </p>
|
||||
* @return string a string containing the calculated message digest as lowercase hexits
|
||||
* @return string|false a string containing the calculated message digest as lowercase hexits
|
||||
* unless <i>raw_output</i> is set to true in which case the raw
|
||||
* binary representation of the message digest is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function hash (string $algo, string $data, bool $binary = false) {}
|
||||
function hash (string $algo, string $data, bool $binary = false): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Timing attack safe string comparison
|
||||
|
@ -33,7 +34,8 @@ function hash (string $algo, string $data, bool $binary = false) {}
|
|||
* @since 5.6
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_equals(string $known_string, string $user_string) {}
|
||||
function hash_equals(string $known_string, string $user_string): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL hash >= 1.1)<br/>
|
||||
|
@ -49,12 +51,13 @@ function hash_equals(string $known_string, string $user_string) {}
|
|||
* When set to <b>TRUE</b>, outputs raw binary data.
|
||||
* <b>FALSE</b> outputs lowercase hexits.
|
||||
* </p>
|
||||
* @return string a string containing the calculated message digest as lowercase hexits
|
||||
* @return string|false a string containing the calculated message digest as lowercase hexits
|
||||
* unless <i>raw_output</i> is set to true in which case the raw
|
||||
* binary representation of the message digest is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_file (string $algo, string $filename, bool $binary = false) {}
|
||||
function hash_file (string $algo, string $filename, bool $binary = false): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL hash >= 1.1)<br/>
|
||||
|
@ -74,12 +77,13 @@ function hash_file (string $algo, string $filename, bool $binary = false) {}
|
|||
* When set to <b>TRUE</b>, outputs raw binary data.
|
||||
* <b>FALSE</b> outputs lowercase hexits.
|
||||
* </p>
|
||||
* @return string a string containing the calculated message digest as lowercase hexits
|
||||
* @return string|false a string containing the calculated message digest as lowercase hexits
|
||||
* unless <i>raw_output</i> is set to true in which case the raw
|
||||
* binary representation of the message digest is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_hmac (string $algo, string $data, string $key, bool $binary = false) {}
|
||||
function hash_hmac (string $algo, string $data, string $key, bool $binary = false): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL hash >= 1.1)<br/>
|
||||
|
@ -99,12 +103,13 @@ function hash_hmac (string $algo, string $data, string $key, bool $binary = fals
|
|||
* When set to <b>TRUE</b>, outputs raw binary data.
|
||||
* <b>FALSE</b> outputs lowercase hexits.
|
||||
* </p>
|
||||
* @return string a string containing the calculated message digest as lowercase hexits
|
||||
* @return string|false a string containing the calculated message digest as lowercase hexits
|
||||
* unless <i>raw_output</i> is set to true in which case the raw
|
||||
* binary representation of the message digest is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_hmac_file (string $algo, string $data, string $key, bool $binary = false) {}
|
||||
function hash_hmac_file (string $algo, string $data, string $key, bool $binary = false): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL hash >= 1.1)<br/>
|
||||
|
@ -129,7 +134,7 @@ function hash_hmac_file (string $algo, string $data, string $key, bool $binary =
|
|||
* and <b>hash_final</b>.
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_init (string $algo, int $flags = 0, string $key)
|
||||
function hash_init (string $algo, int $flags = 0, string $key): HashContext
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -144,7 +149,8 @@ function hash_init (string $algo, int $flags = 0, string $key)
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b>.
|
||||
*/
|
||||
function hash_update (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context, string $data){}
|
||||
function hash_update (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context, string $data): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL hash >= 1.1)<br/>
|
||||
|
@ -162,7 +168,7 @@ function hash_update (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default
|
|||
* </p>
|
||||
* @return int Actual number of bytes added to the hashing context from <i>handle</i>.
|
||||
*/
|
||||
function hash_update_stream (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context, $stream, int $length = -1)
|
||||
function hash_update_stream (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context, $stream, int $length = -1): int
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -180,7 +186,7 @@ function hash_update_stream (#[LanguageLevelTypeAware(["8.0" => "HashContext"],
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function hash_update_file (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context, string $filename, $stream_context)
|
||||
function hash_update_file (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context, string $filename, $stream_context): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -198,7 +204,7 @@ function hash_update_file (#[LanguageLevelTypeAware(["8.0" => "HashContext"], de
|
|||
* unless <i>raw_output</i> is set to true in which case the raw
|
||||
* binary representation of the message digest is returned.
|
||||
*/
|
||||
function hash_final (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context, bool $binary = false)
|
||||
function hash_final (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context, bool $binary = false): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -210,7 +216,8 @@ function hash_final (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default:
|
|||
* @return HashContext|resource a copy of Hashing Context resource.
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_copy (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context) {}
|
||||
function hash_copy (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default: "resource")] $context): HashContext
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL hash >= 1.1)<br/>
|
||||
|
@ -220,7 +227,8 @@ function hash_copy (#[LanguageLevelTypeAware(["8.0" => "HashContext"], default:
|
|||
* hashing algorithms.
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_algos () {}
|
||||
function hash_algos (): array
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
|
@ -244,7 +252,9 @@ function hash_algos () {}
|
|||
* @link https://php.net/manual/en/function.hash-hkdf.php
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_hkdf(string $algo , string $key, int $length = 0, string $info = '', string $salt = '') {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function hash_hkdf(string $algo , string $key, int $length = 0, string $info = '', string $salt = '')
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return a list of registered hashing algorithms suitable for hash_hmac
|
||||
|
@ -253,7 +263,8 @@ function hash_hkdf(string $algo , string $key, int $length = 0, string $info = '
|
|||
* @return string[] Returns a numerically indexed array containing the list of supported hashing algorithms suitable for {@see hash_hmac()}.
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_hmac_algos() {}
|
||||
function hash_hmac_algos(): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generate a PBKDF2 key derivation of a supplied password
|
||||
|
@ -279,13 +290,14 @@ function hash_hmac_algos() {}
|
|||
* @param bool $binary [optional] <p>
|
||||
* When set to TRUE, outputs raw binary data. FALSE outputs lowercase hexits.
|
||||
* </p>
|
||||
* @return mixed a string containing the derived key as lowercase hexits unless
|
||||
* @return string a string containing the derived key as lowercase hexits unless
|
||||
* <i>raw_output</i> is set to <b>TRUE</b> in which case the raw
|
||||
* binary representation of the derived key is returned.
|
||||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function hash_pbkdf2 (string $algo, string $password, string $salt, int $iterations, int $length = 0, bool $binary = false) {}
|
||||
function hash_pbkdf2 (string $algo, string $password, string $salt, int $iterations, int $length = 0, bool $binary = false): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generates a key
|
||||
|
@ -310,7 +322,8 @@ function hash_pbkdf2 (string $algo, string $password, string $salt, int $iterati
|
|||
* @return string|false the generated key as a string, or <b>FALSE</b> on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function mhash_keygen_s2k (int $algo, string $password, string $salt, int $length) {}
|
||||
function mhash_keygen_s2k (int $algo, string $password, string $salt, int $length): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the block size of the specified hash
|
||||
|
@ -322,7 +335,8 @@ function mhash_keygen_s2k (int $algo, string $password, string $salt, int $lengt
|
|||
* does not exist.
|
||||
*/
|
||||
#[Pure]
|
||||
function mhash_get_block_size (int $algo) {}
|
||||
function mhash_get_block_size (int $algo): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the name of the specified hash
|
||||
|
@ -333,7 +347,8 @@ function mhash_get_block_size (int $algo) {}
|
|||
* @return string|false the name of the hash or <b>FALSE</b>, if the hash does not exist.
|
||||
*/
|
||||
#[Pure]
|
||||
function mhash_get_hash_name (int $algo) {}
|
||||
function mhash_get_hash_name (int $algo): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the highest available hash ID
|
||||
|
@ -342,7 +357,8 @@ function mhash_get_hash_name (int $algo) {}
|
|||
* hash ID.
|
||||
*/
|
||||
#[Pure]
|
||||
function mhash_count () {}
|
||||
function mhash_count (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Computes hash
|
||||
|
@ -359,11 +375,11 @@ function mhash_count () {}
|
|||
* digest that depends on the specified key. Not all algorithms
|
||||
* supported in mhash can be used in HMAC mode.
|
||||
* </p>
|
||||
* @return string the resulting hash (also called digest) or HMAC as a string, or
|
||||
* @return string|false the resulting hash (also called digest) or HMAC as a string, or
|
||||
* <b>FALSE</b> on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function mhash (int $algo, string $data, string $key)
|
||||
function mhash (int $algo, string $data, string $key): string|false
|
||||
{}
|
||||
|
||||
|
||||
|
|
|
@ -28,7 +28,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @return string|false the converted string or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function iconv (string $from_encoding, string $to_encoding, string $string) {}
|
||||
function iconv (string $from_encoding, string $to_encoding, string $string): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert character encoding as output buffer handler
|
||||
|
@ -39,7 +40,8 @@ function iconv (string $from_encoding, string $to_encoding, string $string) {}
|
|||
* return values.
|
||||
*/
|
||||
#[Pure]
|
||||
function ob_iconv_handler (string $contents, int $status) {}
|
||||
function ob_iconv_handler (string $contents, int $status): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve internal configuration variables of iconv extension
|
||||
|
@ -61,7 +63,8 @@ function ob_iconv_handler (string $contents, int $status) {}
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function iconv_get_encoding (string $type = "all") {}
|
||||
function iconv_get_encoding (string $type = "all"): array|string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set current setting for character encoding conversion
|
||||
|
@ -77,7 +80,8 @@ function iconv_get_encoding (string $type = "all") {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function iconv_set_encoding (string $type, string $encoding) {}
|
||||
function iconv_set_encoding (string $type, string $encoding): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the character count of string
|
||||
|
@ -93,7 +97,8 @@ function iconv_set_encoding (string $type, string $encoding) {}
|
|||
* @return int|false the character count of <i>str</i>, as an integer. False on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function iconv_strlen (string $string, string $encoding = 'ini_get("iconv.internal_encoding")') {}
|
||||
function iconv_strlen (string $string, string $encoding = 'ini_get("iconv.internal_encoding")'): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Cut out part of a string
|
||||
|
@ -149,7 +154,7 @@ function iconv_strlen (string $string, string $encoding = 'ini_get("iconv.intern
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function iconv_substr (string $string, int $offset, int $length, string $encoding = 'ini_get("iconv.internal_encoding")')
|
||||
function iconv_substr (string $string, int $offset, int $length, string $encoding = 'ini_get("iconv.internal_encoding")'): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -179,7 +184,8 @@ function iconv_substr (string $string, int $offset, int $length, string $encodin
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function iconv_strpos (string $haystack, string $needle, int $offset = 0, string $encoding = 'ini_get("iconv.internal_encoding")') {}
|
||||
function iconv_strpos (string $haystack, string $needle, int $offset = 0, string $encoding = 'ini_get("iconv.internal_encoding")'): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds the last occurrence of a needle within a haystack
|
||||
|
@ -204,7 +210,8 @@ function iconv_strpos (string $haystack, string $needle, int $offset = 0, string
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function iconv_strrpos (string $haystack, string $needle, string $encoding = 'ini_get("iconv.internal_encoding")') {}
|
||||
function iconv_strrpos (string $haystack, string $needle, string $encoding = 'ini_get("iconv.internal_encoding")'): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Composes a MIME header field
|
||||
|
@ -305,7 +312,7 @@ function iconv_strrpos (string $haystack, string $needle, string $encoding = 'in
|
|||
* or <b>FALSE</b> if an error occurs during the encoding.
|
||||
*/
|
||||
#[Pure]
|
||||
function iconv_mime_encode (string $field_name, string $field_value, array $options)
|
||||
function iconv_mime_encode (string $field_name, string $field_value, array $options): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -358,7 +365,8 @@ function iconv_mime_encode (string $field_name, string $field_value, array $opti
|
|||
* or <b>FALSE</b> if an error occurs during the decoding.
|
||||
*/
|
||||
#[Pure]
|
||||
function iconv_mime_decode (string $string, int $mode = 0, string $encoding = 'ini_get("iconv.internal_encoding")') {}
|
||||
function iconv_mime_decode (string $string, int $mode = 0, string $encoding = 'ini_get("iconv.internal_encoding")'): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Decodes multiple MIME header fields at once
|
||||
|
@ -420,7 +428,8 @@ function iconv_mime_decode (string $string, int $mode = 0, string $encoding = 'i
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function iconv_mime_decode_headers (string $headers, int $mode = 0, string $encoding = 'ini_get("iconv.internal_encoding")') {}
|
||||
function iconv_mime_decode_headers (string $headers, int $mode = 0, string $encoding = 'ini_get("iconv.internal_encoding")'): array|false
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -92,7 +92,7 @@ class JsonIncrementalParser {
|
|||
* </p>
|
||||
* @return string|false a JSON encoded string on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function json_encode (mixed $value, int $flags = 0, int $depth = 512) {}
|
||||
function json_encode (mixed $value, int $flags = 0, int $depth = 512): string|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL json >= 1.2.0)<br/>
|
||||
|
@ -130,7 +130,7 @@ function json_encode (mixed $value, int $flags = 0, int $depth = 512) {}
|
|||
* <i>json</i> cannot be decoded or if the encoded
|
||||
* data is deeper than the recursion limit.
|
||||
*/
|
||||
function json_decode (string $json, bool $associative = false, int $depth = 512, int $flags = 0) {}
|
||||
function json_decode (string $json, bool $associative = false, int $depth = 512, int $flags = 0): mixed {}
|
||||
|
||||
/**
|
||||
* Returns the last error occurred
|
||||
|
@ -224,16 +224,16 @@ function json_decode (string $json, bool $associative = false, int $depth = 512,
|
|||
* </table>
|
||||
*/
|
||||
#[Pure]
|
||||
function json_last_error () {}
|
||||
function json_last_error (): int {}
|
||||
|
||||
/**
|
||||
* Returns the error string of the last json_encode() or json_decode() call, which did not specify <b>JSON_THROW_ON_ERROR</b>.
|
||||
* @link https://php.net/manual/en/function.json-last-error-msg.php
|
||||
* @return string|false Returns the error message on success, "No error" if no error has occurred, or FALSE on failure.
|
||||
* @return string Returns the error message on success, "No error" if no error has occurred.
|
||||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function json_last_error_msg () {}
|
||||
function json_last_error_msg (): string {}
|
||||
|
||||
|
||||
/**
|
||||
|
|
182
ldap/ldap.php
182
ldap/ldap.php
|
@ -14,7 +14,8 @@ use JetBrains\PhpStorm\Deprecated;
|
|||
* @return string|bool Returns the generated password if newpw is empty or omitted. Otherwise returns TRUE on success and FALSE on failure.
|
||||
* @since 7.2
|
||||
*/
|
||||
function ldap_exop_passwd ($ldap , string $user = "" , string $old_password = "" , string $new_password = "" , &$controls = []) {}
|
||||
function ldap_exop_passwd ($ldap , string $user = "" , string $old_password = "" , string $new_password = "" , &$controls = []): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Refresh extended operation helper
|
||||
|
@ -25,7 +26,8 @@ function ldap_exop_passwd ($ldap , string $user = "" , string $old_password = ""
|
|||
* @return int|false From RFC: The responseTtl field is the time in seconds which the server chooses to have as the time-to-live field for that entry. It must not be any smaller than that which the client requested, and it may be larger. However, to allow servers to maintain a relatively accurate directory, and to prevent clients from abusing the dynamic extensions, servers are permitted to shorten a client-requested time-to-live value, down to a minimum of 86400 seconds (one day). FALSE will be returned on error.
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_exop_refresh ($ldap, string $dn, int $ttl) {}
|
||||
function ldap_exop_refresh ($ldap, string $dn, int $ttl): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* WHOAMI extended operation helper
|
||||
|
@ -34,7 +36,8 @@ function ldap_exop_refresh ($ldap, string $dn, int $ttl) {}
|
|||
* @return string|false The data returned by the server, or FALSE on error.
|
||||
* @since 7.2
|
||||
*/
|
||||
function ldap_exop_whoami ($ldap) {}
|
||||
function ldap_exop_whoami ($ldap): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Performs an extended operation on the specified link with reqoid the OID of the operation and reqdata the data.
|
||||
|
@ -48,7 +51,8 @@ function ldap_exop_whoami ($ldap) {}
|
|||
* @return resource|bool When used with retdata, returns TRUE on success or FALSE on error. When used without retdata, returns a result identifier or FALSE on error.
|
||||
* @since 7.2
|
||||
*/
|
||||
function ldap_exop ($ldap , string $request_oid , string $request_data , array $controls = [], &$response_data, &$response_oid) {}
|
||||
function ldap_exop ($ldap , string $request_oid , string $request_data , array $controls = [], &$response_data, &$response_oid)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parse LDAP extended operation data from result object result
|
||||
|
@ -60,7 +64,8 @@ function ldap_exop ($ldap , string $request_oid , string $request_data , array $
|
|||
* @return bool Returns TRUE on success or FALSE on failure.
|
||||
* @since 7.2
|
||||
*/
|
||||
function ldap_parse_exop ($ldap , $result, &$response_data, &$response_oid) {}
|
||||
function ldap_parse_exop ($ldap , $result, &$response_data, &$response_oid): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Translate 8859 characters to t61 characters
|
||||
|
@ -68,7 +73,8 @@ function ldap_parse_exop ($ldap , $result, &$response_data, &$response_oid) {}
|
|||
* @param string $value
|
||||
* @return string
|
||||
*/
|
||||
function ldap_8859_to_t61(string $value) {}
|
||||
function ldap_8859_to_t61(string $value): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Translate t61 characters to 8859 characters
|
||||
|
@ -76,7 +82,8 @@ function ldap_8859_to_t61(string $value) {}
|
|||
* @param string $value
|
||||
* @return string
|
||||
*/
|
||||
function ldap_t61_to_8859(string $value) {}
|
||||
function ldap_t61_to_8859(string $value): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Connect to an LDAP server
|
||||
|
@ -101,14 +108,15 @@ function ldap_t61_to_8859(string $value) {}
|
|||
* If no arguments are specified then the link identifier of the already
|
||||
* opened link will be returned.
|
||||
*/
|
||||
function ldap_connect (string $uri, int $port = 389) {}
|
||||
function ldap_connect (string $uri, int $port = 389)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias of <b>ldap_unbind</b>
|
||||
* @link https://php.net/manual/en/function.ldap-close.php
|
||||
* @param $ldap
|
||||
*/
|
||||
function ldap_close ($ldap) {}
|
||||
function ldap_close ($ldap): bool {}
|
||||
|
||||
/**
|
||||
* Bind to LDAP directory
|
||||
|
@ -120,7 +128,8 @@ function ldap_close ($ldap) {}
|
|||
* @param string $password [optional]
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_bind ($ldap, string $dn, string $password) {}
|
||||
function ldap_bind ($ldap, string $dn, string $password): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Bind to LDAP directory
|
||||
|
@ -135,7 +144,8 @@ function ldap_bind ($ldap, string $dn, string $password) {}
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_bind_ext ($ldap, string $dn, string $password, array $controls = []) {}
|
||||
function ldap_bind_ext ($ldap, string $dn, string $password, array $controls = [])
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
|
@ -151,7 +161,8 @@ function ldap_bind_ext ($ldap, string $dn, string $password, array $controls = [
|
|||
* @param string $props [optional]
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_sasl_bind ($ldap, $binddn = null, $password = null, $sasl_mech = null, $sasl_realm = null, $sasl_authc_id = null, $sasl_authz_id = null, $props = null) {}
|
||||
function ldap_sasl_bind ($ldap, $binddn = null, $password = null, $sasl_mech = null, $sasl_realm = null, $sasl_authc_id = null, $sasl_authz_id = null, $props = null): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Unbind from LDAP directory
|
||||
|
@ -161,7 +172,8 @@ function ldap_sasl_bind ($ldap, $binddn = null, $password = null, $sasl_mech = n
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_unbind ($ldap) {}
|
||||
function ldap_unbind ($ldap): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Read an entry
|
||||
|
@ -225,7 +237,8 @@ function ldap_unbind ($ldap) {}
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return resource|false a search result identifier or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ldap_read ($ldap, array|string $base, array|string $filter, array $attributes, int $attributes_only, int $sizelimit, int $timelimit, int $deref, array $controls = []) {}
|
||||
function ldap_read ($ldap, array|string $base, array|string $filter, array $attributes, int $attributes_only, int $sizelimit, int $timelimit, int $deref, array $controls = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* Single-level search
|
||||
|
@ -283,7 +296,8 @@ function ldap_read ($ldap, array|string $base, array|string $filter, array $attr
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return resource|false a search result identifier or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ldap_list ($ldap, array|string $base, array|string $filter, array $attributes, int $attributes_only, int $sizelimit, int $timelimit, int $deref, array $controls = []) {}
|
||||
function ldap_list ($ldap, array|string $base, array|string $filter, array $attributes, int $attributes_only, int $sizelimit, int $timelimit, int $deref, array $controls = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* Search LDAP tree
|
||||
|
@ -345,7 +359,8 @@ function ldap_list ($ldap, array|string $base, array|string $filter, array $attr
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return resource|false a search result identifier or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ldap_search ($ldap, array|string $base, array|string $filter, array $attributes, int $attributes_only, int $sizelimit, int $timelimit, int $deref, array $controls = []) {}
|
||||
function ldap_search ($ldap, array|string $base, array|string $filter, array $attributes, int $attributes_only, int $sizelimit, int $timelimit, int $deref, array $controls = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* Free result memory
|
||||
|
@ -353,7 +368,8 @@ function ldap_search ($ldap, array|string $base, array|string $filter, array $at
|
|||
* @param resource $ldap
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_free_result ($ldap) {}
|
||||
function ldap_free_result ($ldap): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Count the number of entries in a search
|
||||
|
@ -366,7 +382,9 @@ function ldap_free_result ($ldap) {}
|
|||
* </p>
|
||||
* @return int|false number of entries in the result or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ldap_count_entries ($ldap, $result) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function ldap_count_entries ($ldap, $result)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return first result id
|
||||
|
@ -378,7 +396,8 @@ function ldap_count_entries ($ldap, $result) {}
|
|||
* @return resource|false the result entry identifier for the first entry on success and
|
||||
* <b>FALSE</b> on error.
|
||||
*/
|
||||
function ldap_first_entry ($ldap, $result) {}
|
||||
function ldap_first_entry ($ldap, $result)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get next result entry
|
||||
|
@ -391,7 +410,8 @@ function ldap_first_entry ($ldap, $result) {}
|
|||
* are being read starting with <b>ldap_first_entry</b>. If
|
||||
* there are no more entries in the result then it returns <b>FALSE</b>.
|
||||
*/
|
||||
function ldap_next_entry ($ldap, $result) {}
|
||||
function ldap_next_entry ($ldap, $result)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get all result entries
|
||||
|
@ -400,7 +420,7 @@ function ldap_next_entry ($ldap, $result) {}
|
|||
* An LDAP link identifier, returned by <b>ldap_connect</b>.
|
||||
* </p>
|
||||
* @param resource $result
|
||||
* @return array a complete result information in a multi-dimensional array on
|
||||
* @return array|false a complete result information in a multi-dimensional array on
|
||||
* success and <b>FALSE</b> on error.
|
||||
* </p>
|
||||
* <p>
|
||||
|
@ -419,7 +439,8 @@ function ldap_next_entry ($ldap, $result) {}
|
|||
* return_value[i]["attribute"][j] = jth value of attribute in ith entry
|
||||
* </pre>
|
||||
*/
|
||||
function ldap_get_entries ($ldap, $result) {}
|
||||
function ldap_get_entries ($ldap, $result): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return first attribute
|
||||
|
@ -431,7 +452,8 @@ function ldap_get_entries ($ldap, $result) {}
|
|||
* @return string|false the first attribute in the entry on success and <b>FALSE</b> on
|
||||
* error.
|
||||
*/
|
||||
function ldap_first_attribute ($ldap, $entry) {}
|
||||
function ldap_first_attribute ($ldap, $entry): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the next attribute in result
|
||||
|
@ -443,7 +465,8 @@ function ldap_first_attribute ($ldap, $entry) {}
|
|||
* @return string|false the next attribute in an entry on success and <b>FALSE</b> on
|
||||
* error.
|
||||
*/
|
||||
function ldap_next_attribute ($ldap, $entry) {}
|
||||
function ldap_next_attribute ($ldap, $entry): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get attributes from a search result entry
|
||||
|
@ -455,7 +478,8 @@ function ldap_next_attribute ($ldap, $entry) {}
|
|||
* @return array a complete entry information in a multi-dimensional array
|
||||
* on success and <b>FALSE</b> on error.
|
||||
*/
|
||||
function ldap_get_attributes ($ldap, $entry) {}
|
||||
function ldap_get_attributes ($ldap, $entry): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get all values from a result entry
|
||||
|
@ -478,7 +502,8 @@ function ldap_get_attributes ($ldap, $entry) {}
|
|||
* return_value[0] = first value of attribute
|
||||
* return_value[i] = ith value of attribute
|
||||
*/
|
||||
function ldap_get_values ($ldap, $entry, string $attribute) {}
|
||||
function ldap_get_values ($ldap, $entry, string $attribute): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get all binary values from a result entry
|
||||
|
@ -493,7 +518,8 @@ function ldap_get_values ($ldap, $entry, string $attribute) {}
|
|||
* first index is 0. The number of values can be found by indexing "count"
|
||||
* in the resultant array.
|
||||
*/
|
||||
function ldap_get_values_len ($ldap, $entry, string $attribute) {}
|
||||
function ldap_get_values_len ($ldap, $entry, string $attribute): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the DN of a result entry
|
||||
|
@ -504,7 +530,8 @@ function ldap_get_values_len ($ldap, $entry, string $attribute) {}
|
|||
* @param resource $entry
|
||||
* @return string|false the DN of the result entry and <b>FALSE</b> on error.
|
||||
*/
|
||||
function ldap_get_dn ($ldap, $entry) {}
|
||||
function ldap_get_dn ($ldap, $entry): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Splits DN into its component parts
|
||||
|
@ -518,12 +545,13 @@ function ldap_get_dn ($ldap, $entry) {}
|
|||
* attribute=value format) set <i>with_attrib</i> to 0
|
||||
* and to get only values set it to 1.
|
||||
* </p>
|
||||
* @return array an array of all DN components.
|
||||
* @return array|false an array of all DN components.
|
||||
* The first element in this array has count key and
|
||||
* represents the number of returned values, next elements are numerically
|
||||
* indexed DN components.
|
||||
*/
|
||||
function ldap_explode_dn (string $dn, int $with_attrib) {}
|
||||
function ldap_explode_dn (string $dn, int $with_attrib): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert DN to User Friendly Naming format
|
||||
|
@ -531,9 +559,10 @@ function ldap_explode_dn (string $dn, int $with_attrib) {}
|
|||
* @param string $dn <p>
|
||||
* The distinguished name of an LDAP entity.
|
||||
* </p>
|
||||
* @return string the user friendly name.
|
||||
* @return string|false the user friendly name.
|
||||
*/
|
||||
function ldap_dn2ufn (string $dn) {}
|
||||
function ldap_dn2ufn (string $dn): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Add entries to LDAP directory
|
||||
|
@ -558,7 +587,8 @@ function ldap_dn2ufn (string $dn) {}
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_add ($ldap, string $dn, array $entry, array $controls = []) {}
|
||||
function ldap_add ($ldap, string $dn, array $entry, array $controls = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Add entries to LDAP directory
|
||||
|
@ -585,7 +615,8 @@ function ldap_add ($ldap, string $dn, array $entry, array $controls = []) {}
|
|||
* @return resource|false
|
||||
* @since 7.4
|
||||
*/
|
||||
function ldap_add_ext ($ldap, string $dn, array $entry, array $controls = []) {}
|
||||
function ldap_add_ext ($ldap, string $dn, array $entry, array $controls = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* Delete an entry from a directory
|
||||
|
@ -599,7 +630,8 @@ function ldap_add_ext ($ldap, string $dn, array $entry, array $controls = []) {}
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_delete ($ldap, string $dn, array $controls = []) {}
|
||||
function ldap_delete ($ldap, string $dn, array $controls = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Delete an entry from a directory
|
||||
|
@ -615,7 +647,8 @@ function ldap_delete ($ldap, string $dn, array $controls = []) {}
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_delete_ext ($ldap, string $dn, array $controls = []) {}
|
||||
function ldap_delete_ext ($ldap, string $dn, array $controls = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* This function is an alias of: ldap_mod_replace().
|
||||
|
@ -632,7 +665,8 @@ function ldap_delete_ext ($ldap, string $dn, array $controls = []) {}
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @since 7.0
|
||||
*/
|
||||
function ldap_modify ($ldap, string $dn, array $entry, array $controls = []) {}
|
||||
function ldap_modify ($ldap, string $dn, array $entry, array $controls = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Add attribute values to current attributes
|
||||
|
@ -647,7 +681,8 @@ function ldap_modify ($ldap, string $dn, array $entry, array $controls = []) {}
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_mod_add ($ldap, string $dn, array $entry, array $controls = []) {}
|
||||
function ldap_mod_add ($ldap, string $dn, array $entry, array $controls = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Add attribute values to current attributes
|
||||
|
@ -663,7 +698,8 @@ function ldap_mod_add ($ldap, string $dn, array $entry, array $controls = []) {}
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return resource|false
|
||||
*/
|
||||
function ldap_mod_add_ext ($ldap, string $dn, array $entry, array $controls = []) {}
|
||||
function ldap_mod_add_ext ($ldap, string $dn, array $entry, array $controls = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* Replace attribute values with new ones
|
||||
|
@ -678,7 +714,8 @@ function ldap_mod_add_ext ($ldap, string $dn, array $entry, array $controls = []
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_mod_replace ($ldap, string $dn, array $entry, array $controls = []) {}
|
||||
function ldap_mod_replace ($ldap, string $dn, array $entry, array $controls = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Replace attribute values with new ones
|
||||
|
@ -695,7 +732,8 @@ function ldap_mod_replace ($ldap, string $dn, array $entry, array $controls = []
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_mod_replace_ext ($ldap, string $dn, array $entry, array $controls = []) {}
|
||||
function ldap_mod_replace_ext ($ldap, string $dn, array $entry, array $controls = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* Delete attribute values from current attributes
|
||||
|
@ -710,7 +748,8 @@ function ldap_mod_replace_ext ($ldap, string $dn, array $entry, array $controls
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_mod_del ($ldap, string $dn, array $entry, array $controls = []) {}
|
||||
function ldap_mod_del ($ldap, string $dn, array $entry, array $controls = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Delete attribute values from current attributes
|
||||
|
@ -727,7 +766,8 @@ function ldap_mod_del ($ldap, string $dn, array $entry, array $controls = []) {}
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_mod_del_ext ($ldap, string $dn, array $entry, array $controls = []) {}
|
||||
function ldap_mod_del_ext ($ldap, string $dn, array $entry, array $controls = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the LDAP error number of the last LDAP command
|
||||
|
@ -738,7 +778,8 @@ function ldap_mod_del_ext ($ldap, string $dn, array $entry, array $controls = []
|
|||
* @return int Return the LDAP error number of the last LDAP command for this
|
||||
* link.
|
||||
*/
|
||||
function ldap_errno ($ldap) {}
|
||||
function ldap_errno ($ldap): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert LDAP error number into string error message
|
||||
|
@ -748,7 +789,8 @@ function ldap_errno ($ldap) {}
|
|||
* </p>
|
||||
* @return string the error message, as a string.
|
||||
*/
|
||||
function ldap_err2str (int $errno) {}
|
||||
function ldap_err2str (int $errno): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the LDAP error message of the last LDAP command
|
||||
|
@ -758,7 +800,8 @@ function ldap_err2str (int $errno) {}
|
|||
* </p>
|
||||
* @return string string error message.
|
||||
*/
|
||||
function ldap_error ($ldap) {}
|
||||
function ldap_error ($ldap): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Compare value of attribute found in entry specified with DN
|
||||
|
@ -776,10 +819,11 @@ function ldap_error ($ldap) {}
|
|||
* The compared value.
|
||||
* </p>
|
||||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return mixed <b>TRUE</b> if <i>value</i> matches otherwise returns
|
||||
* @return int|bool <b>TRUE</b> if <i>value</i> matches otherwise returns
|
||||
* <b>FALSE</b>. Returns -1 on error.
|
||||
*/
|
||||
function ldap_compare ($ldap, string $dn, string $attribute, string $value, array $controls = []) {}
|
||||
function ldap_compare ($ldap, string $dn, string $attribute, string $value, array $controls = []): int|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort LDAP result entries
|
||||
|
@ -798,7 +842,8 @@ function ldap_compare ($ldap, string $dn, string $attribute, string $value, arra
|
|||
* @return bool
|
||||
*/
|
||||
#[Deprecated(since: "7.0")]
|
||||
function ldap_sort ($ldap, $result, string $sortfilter) {}
|
||||
function ldap_sort ($ldap, $result, string $sortfilter): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Modify the name of an entry
|
||||
|
@ -822,7 +867,8 @@ function ldap_sort ($ldap, $result, string $sortfilter) {}
|
|||
* @param array $controls [optional] Array of LDAP Controls to send with the request.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_rename ($ldap, string $dn, string $new_rdn, string $new_parent, bool $delete_old_rdn, array $controls = []) {}
|
||||
function ldap_rename ($ldap, string $dn, string $new_rdn, string $new_parent, bool $delete_old_rdn, array $controls = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Modify the name of an entry
|
||||
|
@ -848,7 +894,8 @@ function ldap_rename ($ldap, string $dn, string $new_rdn, string $new_parent, bo
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_rename_ext ($ldap, string $dn, string $new_rdn, string $new_parent, bool $delete_old_rdn, array $controls = []) {}
|
||||
function ldap_rename_ext ($ldap, string $dn, string $new_rdn, string $new_parent, bool $delete_old_rdn, array $controls = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the current value for given option
|
||||
|
@ -920,7 +967,8 @@ function ldap_rename_ext ($ldap, string $dn, string $new_rdn, string $new_parent
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_get_option ($ldap, int $option, &$value) {}
|
||||
function ldap_get_option ($ldap, int $option, &$value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set the value of the given option
|
||||
|
@ -1021,7 +1069,8 @@ function ldap_get_option ($ldap, int $option, &$value) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_set_option ($ldap, int $option, $value) {}
|
||||
function ldap_set_option ($ldap, int $option, $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return first reference
|
||||
|
@ -1049,7 +1098,8 @@ function ldap_next_reference ($ldap, $entry) {}
|
|||
* @param array &$referrals
|
||||
* @return bool
|
||||
*/
|
||||
function ldap_parse_reference ($ldap, $entry, &$referrals) {}
|
||||
function ldap_parse_reference ($ldap, $entry, &$referrals): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Extract information from result
|
||||
|
@ -1063,7 +1113,8 @@ function ldap_parse_reference ($ldap, $entry, &$referrals) {}
|
|||
* @param array &$controls [optional] An array of LDAP Controls which have been sent with the response.
|
||||
* @return bool
|
||||
*/
|
||||
function ldap_parse_result ($ldap, $result, &$error_code, &$matched_dn, &$error_message, &$referrals, &$controls = []) {}
|
||||
function ldap_parse_result ($ldap, $result, &$error_code, &$matched_dn, &$error_message, &$referrals, &$controls = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Start TLS
|
||||
|
@ -1071,7 +1122,8 @@ function ldap_parse_result ($ldap, $result, &$error_code, &$matched_dn, &$error_
|
|||
* @param resource $ldap
|
||||
* @return bool
|
||||
*/
|
||||
function ldap_start_tls ($ldap) {}
|
||||
function ldap_start_tls ($ldap): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set a callback function to do re-binds on referral chasing
|
||||
|
@ -1080,7 +1132,8 @@ function ldap_start_tls ($ldap) {}
|
|||
* @param callable $callback
|
||||
* @return bool
|
||||
*/
|
||||
function ldap_set_rebind_proc ($ldap, callable $callback) {}
|
||||
function ldap_set_rebind_proc ($ldap, callable $callback): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Send LDAP pagination control
|
||||
|
@ -1105,7 +1158,8 @@ function ldap_set_rebind_proc ($ldap, callable $callback) {}
|
|||
* @removed 8.0
|
||||
*/
|
||||
#[Deprecated(since: "7.4")]
|
||||
function ldap_control_paged_result ($ldap, int $pagesize, $iscritical = false, $cookie = "") {}
|
||||
function ldap_control_paged_result ($ldap, int $pagesize, $iscritical = false, $cookie = ""): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve the LDAP pagination cookie
|
||||
|
@ -1125,7 +1179,8 @@ function ldap_control_paged_result ($ldap, int $pagesize, $iscritical = false, $
|
|||
* @removed 8.0
|
||||
*/
|
||||
#[Deprecated(since: "7.4")]
|
||||
function ldap_control_paged_result_response ($ldap, $result, &$cookie = null, &$estimated = null) {}
|
||||
function ldap_control_paged_result_response ($ldap, $result, &$cookie = null, &$estimated = null): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Escape a string for use in an LDAP filter or DN
|
||||
|
@ -1136,7 +1191,8 @@ function ldap_control_paged_result_response ($ldap, $result, &$cookie = null, &$
|
|||
* @since 5.6
|
||||
*/
|
||||
|
||||
function ldap_escape (string $value, string $ignore = "", int $flags = 0) {}
|
||||
function ldap_escape (string $value, string $ignore = "", int $flags = 0): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5.4 >= 5.4.26, PHP 5.5 >= 5.5.10, PHP 5.6 >= 5.6.0)
|
||||
|
@ -1217,7 +1273,8 @@ function ldap_escape (string $value, string $ignore = "", int $flags = 0) {}
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @since 5.4
|
||||
*/
|
||||
function ldap_modify_batch ($ldap , string $dn , array $modifications_info, array $controls = []) {}
|
||||
function ldap_modify_batch ($ldap , string $dn , array $modifications_info, array $controls = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* @param resource $ldap
|
||||
|
@ -1225,7 +1282,8 @@ function ldap_modify_batch ($ldap , string $dn , array $modifications_info, arra
|
|||
* @return int returns the number of reference messages in a search result.
|
||||
* @since 8.0
|
||||
*/
|
||||
function ldap_count_references($ldap, $result){}
|
||||
function ldap_count_references($ldap, $result): int
|
||||
{}
|
||||
|
||||
define('LDAP_ESCAPE_FILTER', 1);
|
||||
define ('LDAP_ESCAPE_DN', 2);
|
||||
|
|
|
@ -71,7 +71,7 @@ class LibXMLError {
|
|||
* </p>
|
||||
* @return void No value is returned.
|
||||
*/
|
||||
function libxml_set_streams_context ($context) {}
|
||||
function libxml_set_streams_context ($context):void {}
|
||||
|
||||
/**
|
||||
* Disable libxml errors and allow user to fetch error information as needed
|
||||
|
@ -82,23 +82,24 @@ function libxml_set_streams_context ($context) {}
|
|||
* @return bool This function returns the previous value of
|
||||
* <i>use_errors</i>.
|
||||
*/
|
||||
function libxml_use_internal_errors (bool $use_errors = false) {}
|
||||
function libxml_use_internal_errors (bool $use_errors = false): bool {}
|
||||
|
||||
/**
|
||||
* Retrieve last error from libxml
|
||||
* @link https://php.net/manual/en/function.libxml-get-last-error.php
|
||||
* @return LibXMLError a LibXMLError object if there is any error in the
|
||||
* @return LibXMLError|false a LibXMLError object if there is any error in the
|
||||
* buffer, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function libxml_get_last_error () {}
|
||||
function libxml_get_last_error (): LibXMLError|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Clear libxml error buffer
|
||||
* @link https://php.net/manual/en/function.libxml-clear-errors.php
|
||||
* @return void No value is returned.
|
||||
*/
|
||||
function libxml_clear_errors () {}
|
||||
function libxml_clear_errors (): void {}
|
||||
|
||||
/**
|
||||
* Retrieve array of errors
|
||||
|
@ -107,7 +108,8 @@ function libxml_clear_errors () {}
|
|||
* errors in the buffer, or an empty array otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function libxml_get_errors () {}
|
||||
function libxml_get_errors (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Disable the ability to load external entities
|
||||
|
@ -121,7 +123,8 @@ function libxml_get_errors () {}
|
|||
* @since 5.2.11
|
||||
*/
|
||||
#[Deprecated(since: "8.0")]
|
||||
function libxml_disable_entity_loader (bool $disable = true) {}
|
||||
function libxml_disable_entity_loader (bool $disable = true): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Changes the default external entity loader
|
||||
|
@ -132,10 +135,10 @@ function libxml_disable_entity_loader (bool $disable = true) {}
|
|||
* This callback should return a resource, a string from which a resource can be
|
||||
* opened, or <b>NULL</b>.
|
||||
* </p>
|
||||
* @return void No value is returned.
|
||||
* @return bool
|
||||
* @since 5.4
|
||||
*/
|
||||
function libxml_set_external_entity_loader (callable $resolver_function) {}
|
||||
function libxml_set_external_entity_loader (callable $resolver_function): bool {}
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -24,7 +24,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* way specified by mode.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_convert_case (string $string, int $mode, string $encoding) {}
|
||||
function mb_convert_case (string $string, int $mode, string $encoding): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Make a string uppercase
|
||||
|
@ -36,7 +37,8 @@ function mb_convert_case (string $string, int $mode, string $encoding) {}
|
|||
* @return string str with all alphabetic characters converted to uppercase.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strtoupper (string $string, string $encoding) {}
|
||||
function mb_strtoupper (string $string, string $encoding): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Make a string lowercase
|
||||
|
@ -48,7 +50,8 @@ function mb_strtoupper (string $string, string $encoding) {}
|
|||
* @return string str with all alphabetic characters converted to lowercase.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strtolower (string $string, string $encoding) {}
|
||||
function mb_strtolower (string $string, string $encoding): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set/Get current language
|
||||
|
@ -72,7 +75,8 @@ function mb_strtolower (string $string, string $encoding) {}
|
|||
* name as a string. If no language is set previously, it then returns
|
||||
* false.
|
||||
*/
|
||||
function mb_language (string $language) {}
|
||||
function mb_language (string $language): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set/Get internal character encoding
|
||||
|
@ -88,7 +92,8 @@ function mb_language (string $language) {}
|
|||
* If encoding is omitted, then
|
||||
* the current character encoding name is returned.
|
||||
*/
|
||||
function mb_internal_encoding (string $encoding) {}
|
||||
function mb_internal_encoding (string $encoding): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Detect HTTP input character encoding
|
||||
|
@ -99,12 +104,13 @@ function mb_internal_encoding (string $encoding) {}
|
|||
* "I" for the whole list (will return array).
|
||||
* If type is omitted, it returns the last input type processed.
|
||||
* </p>
|
||||
* @return false|string The character encoding name, as per the type.
|
||||
* @return array|false|string The character encoding name, as per the type.
|
||||
* If mb_http_input does not process specified
|
||||
* HTTP input, it returns false.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_http_input (string $type) {}
|
||||
function mb_http_input (string $type): array|string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set/Get HTTP output character encoding
|
||||
|
@ -124,7 +130,8 @@ function mb_http_input (string $type) {}
|
|||
* character encoding. Otherwise,
|
||||
* true on success or false on failure.
|
||||
*/
|
||||
function mb_http_output (string $encoding) {}
|
||||
function mb_http_output (string $encoding): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set/Get character encoding detection order
|
||||
|
@ -169,7 +176,8 @@ function mb_http_output (string $encoding) {}
|
|||
* When getting the encoding detection order, an ordered array
|
||||
* of the encodings is returned.
|
||||
*/
|
||||
function mb_detect_order (array|string $encoding = null) {}
|
||||
function mb_detect_order (array|string $encoding = null): array|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set/Get substitution character
|
||||
|
@ -185,7 +193,8 @@ function mb_detect_order (array|string $encoding = null) {}
|
|||
* If substchar is not set, it returns the Unicode value,
|
||||
* or "none" or "long".
|
||||
*/
|
||||
function mb_substitute_character (string|int $substitute_character = null) {}
|
||||
function mb_substitute_character (string|int $substitute_character = null): string|int|bool
|
||||
{}
|
||||
|
||||
#[PhpStormStubsElementAvailable(to: '7.4')]
|
||||
/**
|
||||
|
@ -199,7 +208,7 @@ function mb_substitute_character (string|int $substitute_character = null) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function mb_parse_str (string $string, &$result)
|
||||
function mb_parse_str (string $string, &$result): bool
|
||||
{}
|
||||
|
||||
#[PhpStormStubsElementAvailable('8.0')]
|
||||
|
@ -214,7 +223,8 @@ function mb_parse_str (string $string, &$result)
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function mb_parse_str (string $string, &$result) {}
|
||||
function mb_parse_str (string $string, &$result): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Callback function converts character encoding in output buffer
|
||||
|
@ -228,7 +238,8 @@ function mb_parse_str (string $string, &$result) {}
|
|||
* @return string The converted string.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_output_handler (string $string, int $status) {}
|
||||
function mb_output_handler (string $string, int $status): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get MIME charset string
|
||||
|
@ -236,11 +247,12 @@ function mb_output_handler (string $string, int $status) {}
|
|||
* @param string $encoding <p>
|
||||
* The encoding being checked.
|
||||
* </p>
|
||||
* @return string The MIME charset string for character encoding
|
||||
* @return string|false The MIME charset string for character encoding
|
||||
* encoding.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_preferred_mime_name (string $encoding) {}
|
||||
function mb_preferred_mime_name (string $encoding): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get string length
|
||||
|
@ -255,7 +267,8 @@ function mb_preferred_mime_name (string $encoding) {}
|
|||
* counted as 1.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strlen (string $string, string $encoding) {}
|
||||
function mb_strlen (string $string, string $encoding): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find position of first occurrence of string in a string
|
||||
|
@ -276,7 +289,8 @@ function mb_strlen (string $string, string $encoding) {}
|
|||
* needle is not found, it returns false.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strpos (string $haystack, string $needle, int $offset = 0, string $encoding) {}
|
||||
function mb_strpos (string $haystack, string $needle, int $offset = 0, string $encoding): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find position of last occurrence of a string in a string
|
||||
|
@ -298,7 +312,8 @@ function mb_strpos (string $haystack, string $needle, int $offset = 0, string $e
|
|||
* needle is not found, it returns false.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strrpos (string $haystack, string $needle, int $offset = 0, string $encoding) {}
|
||||
function mb_strrpos (string $haystack, string $needle, int $offset = 0, string $encoding): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds position of first occurrence of a string within another, case insensitive
|
||||
|
@ -323,7 +338,7 @@ function mb_strrpos (string $haystack, string $needle, int $offset = 0, string $
|
|||
* string, or false if needle is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_stripos (string $haystack, string $needle, int $offset = 0, string $encoding)
|
||||
function mb_stripos (string $haystack, string $needle, int $offset = 0, string $encoding): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -350,7 +365,7 @@ function mb_stripos (string $haystack, string $needle, int $offset = 0, string $
|
|||
* if needle is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strripos (string $haystack, string $needle, int $offset = 0, string $encoding)
|
||||
function mb_strripos (string $haystack, string $needle, int $offset = 0, string $encoding): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -379,7 +394,7 @@ function mb_strripos (string $haystack, string $needle, int $offset = 0, string
|
|||
* or false if needle is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strstr (string $haystack, string $needle, bool $before_needle = false, string $encoding)
|
||||
function mb_strstr (string $haystack, string $needle, bool $before_needle = false, string $encoding): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -408,7 +423,7 @@ function mb_strstr (string $haystack, string $needle, bool $before_needle = fals
|
|||
* or false if needle is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strrchr (string $haystack, string $needle, bool $before_needle = false, string $encoding)
|
||||
function mb_strrchr (string $haystack, string $needle, bool $before_needle = false, string $encoding): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -437,7 +452,7 @@ function mb_strrchr (string $haystack, string $needle, bool $before_needle = fal
|
|||
* or false if needle is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_stristr (string $haystack, string $needle, bool $before_needle = false, string $encoding)
|
||||
function mb_stristr (string $haystack, string $needle, bool $before_needle = false, string $encoding): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -466,7 +481,7 @@ function mb_stristr (string $haystack, string $needle, bool $before_needle = fal
|
|||
* or false if needle is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strrichr (string $haystack, string $needle, bool $before_needle = false, string $encoding)
|
||||
function mb_strrichr (string $haystack, string $needle, bool $before_needle = false, string $encoding): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -484,7 +499,8 @@ function mb_strrichr (string $haystack, string $needle, bool $before_needle = fa
|
|||
* haystack string.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_substr_count (string $haystack, string $needle, string $encoding) {}
|
||||
function mb_substr_count (string $haystack, string $needle, string $encoding): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get part of string
|
||||
|
@ -505,7 +521,7 @@ function mb_substr_count (string $haystack, string $needle, string $encoding) {}
|
|||
* length parameters.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_substr (string $string, int $start, int $length, string $encoding)
|
||||
function mb_substr (string $string, int $start, int $length, string $encoding): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -527,7 +543,7 @@ function mb_substr (string $string, int $start, int $length, string $encoding)
|
|||
* length parameters.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strcut (string $string, int $start, int $length, string $encoding)
|
||||
function mb_strcut (string $string, int $start, int $length, string $encoding): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -540,7 +556,8 @@ function mb_strcut (string $string, int $start, int $length, string $encoding)
|
|||
* @return int The width of string str.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strwidth (string $string, string $encoding) {}
|
||||
function mb_strwidth (string $string, string $encoding): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get truncated string with specified width
|
||||
|
@ -564,7 +581,7 @@ function mb_strwidth (string $string, string $encoding) {}
|
|||
* trimmarker is appended to the return value.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strimwidth (string $string, int $start, int $width, string $trim_marker, string $encoding)
|
||||
function mb_strimwidth (string $string, int $start, int $width, string $trim_marker, string $encoding): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -586,10 +603,10 @@ function mb_strimwidth (string $string, int $start, int $width, string $trim_mar
|
|||
* "auto" may be used, which expands to
|
||||
* "ASCII,JIS,UTF-8,EUC-JP,SJIS".
|
||||
* </p>
|
||||
* @return string The encoded string.
|
||||
* @return array|string|false The encoded string.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_convert_encoding (array|string $string, string $to_encoding, array|string $from_encoding = null)
|
||||
function mb_convert_encoding (array|string $string, string $to_encoding, array|string $from_encoding = null): array|string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -616,7 +633,7 @@ function mb_convert_encoding (array|string $string, string $to_encoding, array|s
|
|||
* detected from the given string.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_detect_encoding (string $string, array|string $encodings = null, bool $strict = false)
|
||||
function mb_detect_encoding (string $string, array|string $encodings = null, bool $strict = false): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -625,7 +642,8 @@ function mb_detect_encoding (string $string, array|string $encodings = null, boo
|
|||
* @return string[] a numerically indexed array.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_list_encodings () {}
|
||||
function mb_list_encodings (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get aliases of a known encoding type
|
||||
|
@ -634,7 +652,9 @@ function mb_list_encodings () {}
|
|||
* @link https://php.net/manual/en/function.mb-encoding-aliases.php
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_encoding_aliases (string $encoding) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")]
|
||||
function mb_encoding_aliases (string $encoding)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert "kana" one from another ("zen-kaku", "han-kaku" and more)
|
||||
|
@ -751,7 +771,7 @@ function mb_encoding_aliases (string $encoding) {}
|
|||
* @return string The converted string.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_convert_kana (string $string, string $mode, string $encoding)
|
||||
function mb_convert_kana (string $string, string $mode, string $encoding): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -787,7 +807,8 @@ function mb_convert_kana (string $string, string $mode, string $encoding)
|
|||
* @return string A converted version of the string represented in ASCII.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_encode_mimeheader (string $string, string $charset, string $transfer_encoding, string $newline, int $indent) {}
|
||||
function mb_encode_mimeheader (string $string, string $charset, string $transfer_encoding, string $newline, int $indent): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Decode string in MIME header field
|
||||
|
@ -798,7 +819,8 @@ function mb_encode_mimeheader (string $string, string $charset, string $transfer
|
|||
* @return string The decoded string in internal character encoding.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_decode_mimeheader (string $string) {}
|
||||
function mb_decode_mimeheader (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert character code in variable(s)
|
||||
|
@ -822,7 +844,8 @@ function mb_decode_mimeheader (string $string) {}
|
|||
* @return string|false The character encoding before conversion for success,
|
||||
* or false for failure.
|
||||
*/
|
||||
function mb_convert_variables (string $to_encoding, array|string $from_encoding, mixed &$var, mixed &...$vars) {}
|
||||
function mb_convert_variables (string $to_encoding, array|string $from_encoding, mixed &$var, mixed &...$vars): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Encode character to HTML numeric string reference
|
||||
|
@ -836,10 +859,11 @@ function mb_convert_variables (string $to_encoding, array|string $from_encoding,
|
|||
* </p>
|
||||
* @param string $encoding &mbstring.encoding.parameter;
|
||||
* @param bool $hex [optional]
|
||||
* @return string|false|null The converted string.
|
||||
* @return string The converted string.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_encode_numericentity (string $string, array $map, string $encoding, bool $hex = false) {}
|
||||
function mb_encode_numericentity (string $string, array $map, string $encoding, bool $hex = false): string
|
||||
{}
|
||||
|
||||
#[PhpStormStubsElementAvailable(to: '7.4')]
|
||||
/**
|
||||
|
@ -859,7 +883,8 @@ function mb_encode_numericentity (string $string, array $map, string $encoding,
|
|||
* @return string|false|null The converted string.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_decode_numericentity ($string, array $map, string $encoding, $is_hex = false) {}
|
||||
function mb_decode_numericentity ($string, array $map, string $encoding, $is_hex = false): string|false|null
|
||||
{}
|
||||
|
||||
#[PhpStormStubsElementAvailable('8.0')]
|
||||
/**
|
||||
|
@ -873,10 +898,11 @@ function mb_decode_numericentity ($string, array $map, string $encoding, $is_hex
|
|||
* the code area to convert.
|
||||
* </p>
|
||||
* @param string $encoding &mbstring.encoding.parameter;
|
||||
* @return string|false|null The converted string.
|
||||
* @return string The converted string.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_decode_numericentity ($string, array $map, string $encoding) {}
|
||||
function mb_decode_numericentity ($string, array $map, string $encoding): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Send encoded mail
|
||||
|
@ -907,7 +933,7 @@ function mb_decode_numericentity ($string, array $map, string $encoding) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function mb_send_mail (string $to, string $subject, string $message, array|string $additional_headers, string $additional_params)
|
||||
function mb_send_mail (string $to, string $subject, string $message, array|string $additional_headers, string $additional_params): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -924,11 +950,12 @@ function mb_send_mail (string $to, string $subject, string $message, array|strin
|
|||
* "http_input", "internal_encoding", "func_overload",
|
||||
* the specified setting parameter will be returned.
|
||||
* </p>
|
||||
* @return array|mixed An array of type information if type
|
||||
* @return array|string|int|false An array of type information if type
|
||||
* is not specified, otherwise a specific type.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_get_info (string $type) {}
|
||||
function mb_get_info (string $type): array|string|int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check if the string is valid for the specified encoding
|
||||
|
@ -944,7 +971,8 @@ function mb_get_info (string $type) {}
|
|||
* @since 5.1.3
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_check_encoding (array|string $value = null, string $encoding) {}
|
||||
function mb_check_encoding (array|string $value = null, string $encoding): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns current encoding for multibyte regex as string
|
||||
|
@ -955,7 +983,8 @@ function mb_check_encoding (array|string $value = null, string $encoding) {}
|
|||
* is NOT changed. If encoding is omitted, then the current character
|
||||
* encoding name for a multibyte regex is returned.
|
||||
*/
|
||||
function mb_regex_encoding (string $encoding) {}
|
||||
function mb_regex_encoding (string $encoding): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set/Get the default options for mbregex functions
|
||||
|
@ -966,7 +995,8 @@ function mb_regex_encoding (string $encoding) {}
|
|||
* @return string The previous options. If options is omitted,
|
||||
* it returns the string that describes the current options.
|
||||
*/
|
||||
function mb_regex_set_options (string $options) {}
|
||||
function mb_regex_set_options (string $options): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Regular expression match with multibyte support
|
||||
|
@ -980,9 +1010,10 @@ function mb_regex_set_options (string $options) {}
|
|||
* @param string[] &$matches [optional] <p>
|
||||
* Contains a substring of the matched string.
|
||||
* </p>
|
||||
* @return int
|
||||
* @return bool
|
||||
*/
|
||||
function mb_ereg (string $pattern, string $string, &$matches) {}
|
||||
function mb_ereg (string $pattern, string $string, &$matches): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Regular expression match ignoring case with multibyte support
|
||||
|
@ -996,9 +1027,10 @@ function mb_ereg (string $pattern, string $string, &$matches) {}
|
|||
* @param string[] &$matches [optional] <p>
|
||||
* Contains a substring of the matched string.
|
||||
* </p>
|
||||
* @return int
|
||||
* @return bool
|
||||
*/
|
||||
function mb_eregi (string $pattern, string $string, &$matches) {}
|
||||
function mb_eregi (string $pattern, string $string, &$matches): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Replace regular expression with multibyte support
|
||||
|
@ -1026,10 +1058,11 @@ function mb_eregi (string $pattern, string $string, &$matches) {}
|
|||
* is specified, replacement string will be
|
||||
* evaluated as PHP expression.
|
||||
* <p>PHP 7.1: The <i>e</i> modifier has been deprecated.</p>
|
||||
* @return string|false The resultant string on success, or false on error.
|
||||
* @return string|false|null The resultant string on success, or false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_ereg_replace (string $pattern, string $replacement, string $string, string $options = "msr") {}
|
||||
function mb_ereg_replace (string $pattern, string $replacement, string $string, string $options = "msr"): string|false|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Perform a regular expresssion seach and replace with multibyte support using a callback
|
||||
|
@ -1069,12 +1102,13 @@ function mb_ereg_replace (string $pattern, string $replacement, string $string,
|
|||
* will be considered as normal character. Note that <em>e</em>
|
||||
* cannot be used for <b>mb_ereg_replace_callback()</b>.
|
||||
* </p>
|
||||
* @return string|false <p>
|
||||
* @return string|false|null <p>
|
||||
* The resultant string on success, or <b>FALSE</b> on error.
|
||||
* </p>
|
||||
* @since 5.4.1
|
||||
*/
|
||||
function mb_ereg_replace_callback (string $pattern, callable $callback, string $string, string $options = "msr") {}
|
||||
function mb_ereg_replace_callback (string $pattern, callable $callback, string $string, string $options = "msr"): string|false|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Replace regular expression with multibyte support ignoring case
|
||||
|
@ -1091,10 +1125,11 @@ function mb_ereg_replace_callback (string $pattern, callable $callback, string $
|
|||
* @param string $options [optional] option has the same meaning as in
|
||||
* mb_ereg_replace.
|
||||
* <p>PHP 7.1: The <i>e</i> modifier has been deprecated.</p>
|
||||
* @return string|false The resultant string or false on error.
|
||||
* @return string|false|null The resultant string or false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_eregi_replace (string $pattern, string $replacement, string $string, string $options = "msr") {}
|
||||
function mb_eregi_replace (string $pattern, string $replacement, string $string, string $options = "msr"): string|false|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Split multibyte string using regular expression
|
||||
|
@ -1108,10 +1143,10 @@ function mb_eregi_replace (string $pattern, string $replacement, string $string,
|
|||
* @param int $limit [optional] If optional parameter limit is specified,
|
||||
* it will be split in limit elements as
|
||||
* maximum.
|
||||
* @return string[] The result as an array.
|
||||
* @return string[]|false The result as an array.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_split (string $pattern, string $string, int $limit)
|
||||
function mb_split (string $pattern, string $string, int $limit): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1128,7 +1163,7 @@ function mb_split (string $pattern, string $string, int $limit)
|
|||
* @return bool
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_ereg_match (string $pattern, string $string, string $options)
|
||||
function mb_ereg_match (string $pattern, string $string, string $options): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1143,7 +1178,8 @@ function mb_ereg_match (string $pattern, string $string, string $options)
|
|||
* @return bool
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_ereg_search (string $pattern, string $options) {}
|
||||
function mb_ereg_search (string $pattern, string $options): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns position and length of a matched part of the multibyte regular expression for a predefined multibyte string
|
||||
|
@ -1160,7 +1196,8 @@ function mb_ereg_search (string $pattern, string $options) {}
|
|||
* length in bytes of the match. If an error occurs, FALSE is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_ereg_search_pos (string $pattern, string $options) {}
|
||||
function mb_ereg_search_pos (string $pattern, string $options): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the matched part of a multibyte regular expression
|
||||
|
@ -1178,7 +1215,8 @@ function mb_ereg_search_pos (string $pattern, string $options) {}
|
|||
* part as third element, and so on. It returns FALSE on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_ereg_search_regs (string $pattern, string $options) {}
|
||||
function mb_ereg_search_regs (string $pattern, string $options): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Setup string and regular expression for a multibyte regular expression match
|
||||
|
@ -1194,7 +1232,7 @@ function mb_ereg_search_regs (string $pattern, string $options) {}
|
|||
* </p>
|
||||
* @return bool
|
||||
*/
|
||||
function mb_ereg_search_init (string $string, string $pattern, string $options)
|
||||
function mb_ereg_search_init (string $string, string $pattern, string $options): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1208,7 +1246,8 @@ function mb_ereg_search_init (string $string, string $pattern, string $options)
|
|||
* brackets, and so on. It returns FALSE on error;
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_ereg_search_getregs () {}
|
||||
function mb_ereg_search_getregs (): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns start point for next regular expression match
|
||||
|
@ -1217,7 +1256,8 @@ function mb_ereg_search_getregs () {}
|
|||
*/
|
||||
#[Pure]
|
||||
#[Deprecated(since: '7.3')]
|
||||
function mb_ereg_search_getpos () {}
|
||||
function mb_ereg_search_getpos (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set start point of next regular expression match
|
||||
|
@ -1228,7 +1268,8 @@ function mb_ereg_search_getpos () {}
|
|||
* @return bool
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_ereg_search_setpos (int $offset) {}
|
||||
function mb_ereg_search_setpos (int $offset): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* @param $encoding [optional]
|
||||
|
@ -1279,7 +1320,8 @@ function mbereg_replace ($pattern, $replacement, $string, $option) {}
|
|||
* @removed 8.0
|
||||
*/
|
||||
#[Deprecated(replacement: "mb_eregi_replace(%parametersList%)", since: "7.3")]
|
||||
function mberegi_replace ($pattern, $replacement, $string, string $option = "msri") {}
|
||||
function mberegi_replace ($pattern, $replacement, $string, string $option = "msri"): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* @param $pattern
|
||||
|
@ -1361,7 +1403,8 @@ function mbereg_search_getpos () {}
|
|||
* @since 7.2
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_chr (int $codepoint, string $encoding) {}
|
||||
function mb_chr (int $codepoint, string $encoding): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get code point of character
|
||||
|
@ -1372,7 +1415,8 @@ function mb_chr (int $codepoint, string $encoding) {}
|
|||
* @since 7.2
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_ord (string $string, string $encoding) {}
|
||||
function mb_ord (string $string, string $encoding): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Scrub broken multibyte strings.
|
||||
|
@ -1383,7 +1427,9 @@ function mb_ord (string $string, string $encoding) {}
|
|||
* @since 7.2
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_scrub (string $string, string $encoding) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function mb_scrub (string $string, string $encoding): bool|string
|
||||
{}
|
||||
|
||||
/**
|
||||
* @param $position
|
||||
|
@ -1410,6 +1456,7 @@ function mbereg_search_setpos ($position) {}
|
|||
* @since 7.4
|
||||
*/
|
||||
#[Pure]
|
||||
#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")]
|
||||
function mb_str_split (string $string, int $length = 1, string $encoding)
|
||||
{}
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -12,7 +12,7 @@ use JetBrains\PhpStorm\Deprecated;
|
|||
* @return void
|
||||
*/
|
||||
#[Deprecated(since: '8.0')]
|
||||
function openssl_pkey_free(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] $key) { }
|
||||
function openssl_pkey_free(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] $key): void { }
|
||||
|
||||
/**
|
||||
* Generates a new private key
|
||||
|
@ -23,10 +23,12 @@ function openssl_pkey_free(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetric
|
|||
* <b>openssl_csr_new</b> for more information about
|
||||
* <i>configargs</i>.
|
||||
* </p>
|
||||
* @return resource|false a resource identifier for the pkey on success, or false on
|
||||
* @return OpenSSLAsymmetricKey|resource|false a resource identifier for the pkey on success, or false on
|
||||
* error.
|
||||
*/
|
||||
function openssl_pkey_new(array $options) { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey|false"], default: "resource|false")]
|
||||
function openssl_pkey_new(array $options): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Gets an exportable representation of a key into a string
|
||||
|
@ -44,7 +46,8 @@ function openssl_pkey_new(array $options) { }
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_pkey_export($key, &$output, string $passphrase, array $options) { }
|
||||
function openssl_pkey_export($key, &$output, string $passphrase, array $options): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Gets an exportable representation of a key into a file
|
||||
|
@ -65,7 +68,8 @@ function openssl_pkey_export($key, &$output, string $passphrase, array $options)
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_pkey_export_to_file($key, string $output_filename, string $passphrase, array $options) { }
|
||||
function openssl_pkey_export_to_file($key, string $output_filename, string $passphrase, array $options): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Get a private key
|
||||
|
@ -84,9 +88,11 @@ function openssl_pkey_export_to_file($key, string $output_filename, string $pass
|
|||
* The optional parameter <b><em>passphrase</em></b> must be used
|
||||
* if the specified key is encrypted (protected by a passphrase).
|
||||
* </p>
|
||||
* @return resource|false Returns a positive key resource identifier on success, or <b>FALSE</b> on error.
|
||||
* @return OpenSSLAsymmetricKey|resource|false Returns a positive key resource identifier on success, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function openssl_pkey_get_private($private_key, string $passphrase = "") { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey|false"], default: "resource|false")]
|
||||
function openssl_pkey_get_private($private_key, string $passphrase = ""): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Extract public key from certificate and prepare it for use
|
||||
|
@ -101,9 +107,11 @@ function openssl_pkey_get_private($private_key, string $passphrase = "") { }
|
|||
* </li>
|
||||
* <li>A PEM formatted public key.</li>
|
||||
* </ol></p>
|
||||
* @return resource|false a positive key resource identifier on success, or false on error.
|
||||
* @return OpenSSLAsymmetricKey|resource|false a positive key resource identifier on success, or false on error.
|
||||
*/
|
||||
function openssl_pkey_get_public($public_key) { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey|false"], default: "resource|false")]
|
||||
function openssl_pkey_get_public($public_key): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Returns an array with the key details
|
||||
|
@ -124,7 +132,8 @@ function openssl_pkey_get_public($public_key) { }
|
|||
* Depending on the key type used, additional details may be returned. Note that
|
||||
* some elements may not always be available.
|
||||
*/
|
||||
function openssl_pkey_get_details(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] $key) { }
|
||||
function openssl_pkey_get_details(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] $key): array|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Free key resource
|
||||
|
@ -133,7 +142,7 @@ function openssl_pkey_get_details(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsy
|
|||
* @return void
|
||||
*/
|
||||
#[Deprecated(since: '8.0')]
|
||||
function openssl_free_key(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] $key) { }
|
||||
function openssl_free_key(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] $key): void { }
|
||||
|
||||
/**
|
||||
* Alias of <b>openssl_pkey_get_private</b>
|
||||
|
@ -152,9 +161,11 @@ function openssl_free_key(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricK
|
|||
* The optional parameter <b><em>passphrase</em></b> must be used
|
||||
* if the specified key is encrypted (protected by a passphrase).
|
||||
* </p>
|
||||
* @return resource|false Returns a positive key resource identifier on success, or <b>FALSE</b> on error.
|
||||
* @return OpenSSLAsymmetricKey|resource|false Returns a positive key resource identifier on success, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function openssl_get_privatekey($private_key, string $passphrase) { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey|false"], default: "resource|false")]
|
||||
function openssl_get_privatekey($private_key, string $passphrase): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Alias of <b>openssl_pkey_get_public</b>
|
||||
|
@ -170,9 +181,11 @@ function openssl_get_privatekey($private_key, string $passphrase) { }
|
|||
* </li>
|
||||
* <li>A PEM formatted public key.</li>
|
||||
* </ol> </p>
|
||||
* @return resource|false a positive key resource identifier on success, or FALSE on error.
|
||||
* @return OpenSSLAsymmetricKey|false a positive key resource identifier on success, or FALSE on error.
|
||||
*/
|
||||
function openssl_get_publickey($public_key) { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey|false"], default: "resource|false")]
|
||||
function openssl_get_publickey($public_key): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Generate a new signed public key and challenge
|
||||
|
@ -186,10 +199,11 @@ function openssl_get_publickey($public_key) { }
|
|||
* </p>
|
||||
* @param string &$challenge <p>The challenge associated to associate with the SPKAC</p>
|
||||
* @param int $digest_algo <p>The digest algorithm. See openssl_get_md_method().</p>
|
||||
* @return string|null Returns a signed public key and challenge string or NULL on failure.
|
||||
* @return string|false Returns a signed public key and challenge string or NULL on failure.
|
||||
* @since 5.6
|
||||
*/
|
||||
function openssl_spki_new(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] &$private_key, string &$challenge, int $digest_algo = 0) {}
|
||||
function openssl_spki_new(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] &$private_key, string &$challenge, int $digest_algo = 0): string|false
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
|
@ -199,33 +213,38 @@ function openssl_spki_new(#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricK
|
|||
* @return bool Returns a boolean on success or failure.
|
||||
* @since 5.6
|
||||
*/
|
||||
function openssl_spki_verify(string &$spki) {}
|
||||
function openssl_spki_verify(string &$spki): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Exports the challenge associated with a signed public key and challenge
|
||||
* @link https://php.net/manual/en/function.openssl-spki-export-challenge.php
|
||||
* @param string &$spki <p>Expects a valid signed public key and challenge</p>
|
||||
* @return string|null Returns the associated challenge string or NULL on failure.
|
||||
* @return string|false Returns the associated challenge string or NULL on failure.
|
||||
* @since 5.6
|
||||
*/
|
||||
function openssl_spki_export_challenge (string &$spki) {}
|
||||
function openssl_spki_export_challenge (string &$spki): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Exports a valid PEM formatted public key signed public key and challenge
|
||||
* @link https://php.net/manual/en/function.openssl-spki-export.php
|
||||
* @param string &$spki <p>Expects a valid signed public key and challenge</p>
|
||||
* @return string|null Returns the associated PEM formatted public key or NULL on failure.
|
||||
* @return string|false Returns the associated PEM formatted public key or NULL on failure.
|
||||
* @since 5.6
|
||||
*/
|
||||
function openssl_spki_export (string &$spki ) {}
|
||||
function openssl_spki_export (string &$spki ): string|false
|
||||
{}
|
||||
/**
|
||||
* Parse an X.509 certificate and return a resource identifier for
|
||||
* it
|
||||
* @link https://php.net/manual/en/function.openssl-x509-read.php
|
||||
* @param OpenSSLCertificate|string|resource $certificate
|
||||
* @return resource|false a resource identifier on success or false on failure.
|
||||
* @return OpenSSLCertificate|resource|false a resource identifier on success or false on failure.
|
||||
*/
|
||||
function openssl_x509_read(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate) { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|false"], default: "resource|false")]
|
||||
function openssl_x509_read(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate)
|
||||
{ }
|
||||
|
||||
/**
|
||||
* @param string $certificate
|
||||
|
@ -234,7 +253,8 @@ function openssl_x509_read(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificat
|
|||
* @return string|false <b>FALSE</b> on failure
|
||||
* @since 5.6
|
||||
*/
|
||||
function openssl_x509_fingerprint(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, string $digest_algo, bool $binary) {}
|
||||
function openssl_x509_fingerprint(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, string $digest_algo, bool $binary): string|false
|
||||
{}
|
||||
/**
|
||||
* Free certificate resource
|
||||
* @link https://php.net/manual/en/function.openssl-x509-free.php
|
||||
|
@ -242,7 +262,7 @@ function openssl_x509_fingerprint(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCer
|
|||
* @return void
|
||||
*/
|
||||
#[Deprecated(since: '8.0')]
|
||||
function openssl_x509_free(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate"], default: "resource|string")] $certificate) { }
|
||||
function openssl_x509_free(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate"], default: "resource|string")] $certificate): void { }
|
||||
|
||||
/**
|
||||
* Parse an X509 certificate and return the information as an array
|
||||
|
@ -257,7 +277,8 @@ function openssl_x509_free(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificat
|
|||
* @return array|false The structure of the returned data is (deliberately) not
|
||||
* yet documented, as it is still subject to change.
|
||||
*/
|
||||
function openssl_x509_parse(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, bool $short_names = true) { }
|
||||
function openssl_x509_parse(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, bool $short_names = true): array|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Verifies if a certificate can be used for a particular purpose
|
||||
|
@ -319,7 +340,8 @@ function openssl_x509_parse(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertifica
|
|||
* @return int|bool true if the certificate can be used for the intended purpose,
|
||||
* false if it cannot, or -1 on error.
|
||||
*/
|
||||
function openssl_x509_checkpurpose(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, int $purpose, array $ca_info, string $untrusted_certificates_file) { }
|
||||
function openssl_x509_checkpurpose(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, int $purpose, array $ca_info, string $untrusted_certificates_file): int|bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Checks if a private key corresponds to a certificate
|
||||
|
@ -333,7 +355,8 @@ function openssl_x509_checkpurpose(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCe
|
|||
* @return bool true if <i>key</i> is the private key that
|
||||
* corresponds to <i>cert</i>, or false otherwise.
|
||||
*/
|
||||
function openssl_x509_check_private_key(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, $private_key) { }
|
||||
function openssl_x509_check_private_key(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, $private_key): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Exports a certificate as a string
|
||||
|
@ -345,7 +368,8 @@ function openssl_x509_check_private_key(#[LanguageLevelTypeAware(["8.0" => "Open
|
|||
* @param bool $no_text [optional] ¬e.openssl.param-notext;
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_x509_export(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, &$output, bool $no_text = true) { }
|
||||
function openssl_x509_export(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, &$output, bool $no_text = true): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Exports a certificate to file
|
||||
|
@ -357,7 +381,8 @@ function openssl_x509_export(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertific
|
|||
* @param bool $no_text [optional] ¬e.openssl.param-notext;
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_x509_export_to_file(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, string $output_filename, bool $no_text = true) { }
|
||||
function openssl_x509_export_to_file(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, string $output_filename, bool $no_text = true): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Verifies digital signature of x509 certificate against a public key
|
||||
|
@ -386,7 +411,8 @@ function openssl_x509_verify(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertific
|
|||
* @return bool true on success or false on failure.
|
||||
* @since 5.2.2
|
||||
*/
|
||||
function openssl_pkcs12_export(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, &$output, $private_key, string $passphrase, array $options) { }
|
||||
function openssl_pkcs12_export(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, &$output, $private_key, string $passphrase, array $options): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Exports a PKCS#12 Compatible Certificate Store File
|
||||
|
@ -405,7 +431,8 @@ function openssl_pkcs12_export(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertif
|
|||
* @return bool true on success or false on failure.
|
||||
* @since 5.2.2
|
||||
*/
|
||||
function openssl_pkcs12_export_to_file(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, string $output_filename, $private_key, string $passphrase, array $options) { }
|
||||
function openssl_pkcs12_export_to_file(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, string $output_filename, $private_key, string $passphrase, array $options): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Parse a PKCS#12 Certificate Store into an array
|
||||
|
@ -420,7 +447,8 @@ function openssl_pkcs12_export_to_file(#[LanguageLevelTypeAware(["8.0" => "OpenS
|
|||
* @return bool true on success or false on failure.
|
||||
* @since 5.2.2
|
||||
*/
|
||||
function openssl_pkcs12_read(string $pkcs12, &$certificates, string $passphrase) { }
|
||||
function openssl_pkcs12_read(string $pkcs12, &$certificates, string $passphrase): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Generates a CSR
|
||||
|
@ -513,9 +541,11 @@ function openssl_pkcs12_read(string $pkcs12, &$certificates, string $passphrase)
|
|||
* <i>extraattribs</i> are associative arrays whose keys are
|
||||
* converted to OIDs and applied to the relevant part of the request.
|
||||
* </p>
|
||||
* @return false|resource the CSR.
|
||||
* @return OpenSSLCertificateSigningRequest|false|resource the CSR.
|
||||
*/
|
||||
function openssl_csr_new(array $distinguished_names, &$private_key, array $options, array $extra_attributes) { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|false"], default: "resource|false")]
|
||||
function openssl_csr_new(array $distinguished_names, &$private_key, array $options, array $extra_attributes)
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Exports a CSR as a string
|
||||
|
@ -525,7 +555,8 @@ function openssl_csr_new(array $distinguished_names, &$private_key, array $optio
|
|||
* @param bool $no_text [optional] ¬e.openssl.param-notext;
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_csr_export(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, &$output, bool $no_text = true) { }
|
||||
function openssl_csr_export(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, &$output, bool $no_text = true): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Exports a CSR to a file
|
||||
|
@ -537,7 +568,8 @@ function openssl_csr_export(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertifica
|
|||
* @param bool $no_text [optional] ¬e.openssl.param-notext;
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_csr_export_to_file(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, string $output_filename, bool $no_text = true) { }
|
||||
function openssl_csr_export_to_file(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, string $output_filename, bool $no_text = true): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Sign a CSR with another certificate (or itself) and generate a certificate
|
||||
|
@ -570,9 +602,11 @@ function openssl_csr_export_to_file(#[LanguageLevelTypeAware(["8.0" => "OpenSSLC
|
|||
* An optional the serial number of issued certificate. If not specified
|
||||
* it will default to 0.
|
||||
* </p>
|
||||
* @return resource|false an x509 certificate resource on success, false on failure.
|
||||
* @return OpenSSLCertificate|resource|false an x509 certificate resource on success, false on failure.
|
||||
*/
|
||||
function openssl_csr_sign(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, #[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string|null"], default: "resource|string|null")] $ca_certificate, $private_key, int $days, array $options, int $serial = 0) { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|false"], default: "resource|false")]
|
||||
function openssl_csr_sign(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, #[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string|null"], default: "resource|string|null")] $ca_certificate, $private_key, int $days, array $options, int $serial = 0)
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Returns the subject of a CERT
|
||||
|
@ -581,16 +615,19 @@ function openssl_csr_sign(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate
|
|||
* @param bool $short_names [optional]
|
||||
* @return array|false
|
||||
*/
|
||||
function openssl_csr_get_subject(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, bool $short_names = true) { }
|
||||
function openssl_csr_get_subject(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, bool $short_names = true): array|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Returns the public key of a CERT
|
||||
* @link https://php.net/manual/en/function.openssl-csr-get-public-key.php
|
||||
* @param OpenSSLCertificateSigningRequest|string|resource $csr
|
||||
* @param bool $short_names [optional]
|
||||
* @return resource|false
|
||||
* @return OpenSSLAsymmetricKey|resource|false
|
||||
*/
|
||||
function openssl_csr_get_public_key(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, bool $short_names = true) { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey|false"], default: "resource|false")]
|
||||
function openssl_csr_get_public_key(#[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificateSigningRequest|string"], default: "resource|string")] $csr, bool $short_names = true): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Computes a digest
|
||||
|
@ -607,7 +644,8 @@ function openssl_csr_get_public_key(#[LanguageLevelTypeAware(["8.0" => "OpenSSLC
|
|||
* </p>
|
||||
* @return string|false the digested hash value on success or false on failure.
|
||||
*/
|
||||
function openssl_digest(string $data, string $digest_algo, bool $binary = false) { }
|
||||
function openssl_digest(string $data, string $digest_algo, bool $binary = false): string|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Encrypts data
|
||||
|
@ -634,7 +672,8 @@ function openssl_digest(string $data, string $digest_algo, bool $binary = false)
|
|||
* </p>
|
||||
* @return string|false the encrypted string on success or false on failure.
|
||||
*/
|
||||
function openssl_encrypt(string $data, string $cipher_algo, string $passphrase, int $options = 0, string $iv = "", &$tag, string $aad = "", int $tag_length = 16) { }
|
||||
function openssl_encrypt(string $data, string $cipher_algo, string $passphrase, int $options = 0, string $iv = "", &$tag, string $aad = "", int $tag_length = 16): string|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Decrypts data
|
||||
|
@ -662,7 +701,8 @@ function openssl_encrypt(string $data, string $cipher_algo, string $passphrase,
|
|||
* @param string $aad [optional] <p>Additional authentication data.</p>
|
||||
* @return string|false The decrypted string on success or false on failure.
|
||||
*/
|
||||
function openssl_decrypt(string $data, string $cipher_algo, string $passphrase, int $options = 0, string $iv = "", string $tag = "", string $aad = "") { }
|
||||
function openssl_decrypt(string $data, string $cipher_algo, string $passphrase, int $options = 0, string $iv = "", string $tag = "", string $aad = ""): string|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* (PHP 5 >= PHP 5.3.3)<br/>
|
||||
|
@ -673,7 +713,8 @@ function openssl_decrypt(string $data, string $cipher_algo, string $passphrase,
|
|||
* </p>
|
||||
* @return int|false the cipher length on success, or false on failure.
|
||||
*/
|
||||
function openssl_cipher_iv_length(string $cipher_algo) { }
|
||||
function openssl_cipher_iv_length(string $cipher_algo): int|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Generate signature
|
||||
|
@ -689,7 +730,8 @@ function openssl_cipher_iv_length(string $cipher_algo) { }
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_sign(string $data, &$signature, $private_key, string|int $algorithm = OPENSSL_ALGO_SHA1) { }
|
||||
function openssl_sign(string $data, &$signature, $private_key, string|int $algorithm = OPENSSL_ALGO_SHA1): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Verify signature
|
||||
|
@ -700,10 +742,11 @@ function openssl_sign(string $data, &$signature, $private_key, string|int $algor
|
|||
* @param string|int $algorithm [optional] <p>
|
||||
* For more information see the list of Signature Algorithms.
|
||||
* </p>
|
||||
* @return int 1 if the signature is correct, 0 if it is incorrect, and
|
||||
* @return int|false 1 if the signature is correct, 0 if it is incorrect, and
|
||||
* -1 on error.
|
||||
*/
|
||||
function openssl_verify(string $data, string $signature, $public_key, string|int $algorithm = OPENSSL_ALGO_SHA1) { }
|
||||
function openssl_verify(string $data, string $signature, $public_key, string|int $algorithm = OPENSSL_ALGO_SHA1): int|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Seal (encrypt) data
|
||||
|
@ -719,7 +762,8 @@ function openssl_verify(string $data, string $signature, $public_key, string|int
|
|||
* <i>sealed_data</i>, and the envelope keys in
|
||||
* <i>env_keys</i>.
|
||||
*/
|
||||
function openssl_seal(string $data, &$sealed_data, &$encrypted_keys, array $public_key, string $cipher_algo, &$iv = '') { }
|
||||
function openssl_seal(string $data, &$sealed_data, &$encrypted_keys, array $public_key, string $cipher_algo, &$iv = ''): int|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Open sealed data
|
||||
|
@ -735,7 +779,8 @@ function openssl_seal(string $data, &$sealed_data, &$encrypted_keys, array $publ
|
|||
* @param string $iv [optional] The initialization vector.
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_open(string $data, &$output, string $encrypted_key, $private_key, string $cipher_algo = "RC4", string $iv) { }
|
||||
function openssl_open(string $data, &$output, string $encrypted_key, $private_key, string $cipher_algo = "RC4", string $iv): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Generates a PKCS5 v2 PBKDF2 string, defaults to SHA-1
|
||||
|
@ -748,7 +793,8 @@ function openssl_open(string $data, &$output, string $encrypted_key, $private_ke
|
|||
* @return string|false Returns string or FALSE on failure.
|
||||
* @since 5.5
|
||||
*/
|
||||
function openssl_pbkdf2(string $password, string $salt, int $key_length, int $iterations, string $digest_algo) { }
|
||||
function openssl_pbkdf2(string $password, string $salt, int $key_length, int $iterations, string $digest_algo): string|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Verifies the signature of an S/MIME signed message
|
||||
|
@ -786,7 +832,8 @@ function openssl_pbkdf2(string $password, string $salt, int $key_length, int $it
|
|||
* (the message has been tampered with, or the signing certificate is invalid),
|
||||
* or -1 on error.
|
||||
*/
|
||||
function openssl_pkcs7_verify(string $input_filename, int $flags, string $signers_certificates_filename, array $ca_info, string $untrusted_certificates_filename, string $content, string $output_filename) { }
|
||||
function openssl_pkcs7_verify(string $input_filename, int $flags, string $signers_certificates_filename, array $ca_info, string $untrusted_certificates_filename, string $content, string $output_filename): int|bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Decrypts an S/MIME encrypted message
|
||||
|
@ -800,7 +847,8 @@ function openssl_pkcs7_verify(string $input_filename, int $flags, string $signer
|
|||
* @param mixed $private_key [optional]
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_pkcs7_decrypt(string $input_filename, string $output_filename, $certificate, $private_key) { }
|
||||
function openssl_pkcs7_decrypt(string $input_filename, string $output_filename, $certificate, $private_key): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Sign an S/MIME message
|
||||
|
@ -825,7 +873,8 @@ function openssl_pkcs7_decrypt(string $input_filename, string $output_filename,
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_pkcs7_sign(string $input_filename, string $output_filename, #[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, $private_key, array $headers, int $flags = PKCS7_DETACHED, string $untrusted_certificates_filename) { }
|
||||
function openssl_pkcs7_sign(string $input_filename, string $output_filename, #[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")] $certificate, $private_key, array $headers, int $flags = PKCS7_DETACHED, string $untrusted_certificates_filename): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Encrypt an S/MIME message
|
||||
|
@ -854,7 +903,8 @@ function openssl_pkcs7_sign(string $input_filename, string $output_filename, #[L
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_pkcs7_encrypt(string $input_filename, string $output_filename, $certificate, array $headers, int $flags = 0, int $cipher_algo = OPENSSL_CIPHER_RC2_40) { }
|
||||
function openssl_pkcs7_encrypt(string $input_filename, string $output_filename, $certificate, array $headers, int $flags = 0, int $cipher_algo = OPENSSL_CIPHER_RC2_40): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Encrypts data with private key
|
||||
|
@ -869,7 +919,8 @@ function openssl_pkcs7_encrypt(string $input_filename, string $output_filename,
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_private_encrypt(string $data, &$encrypted_data, $private_key, int $padding = OPENSSL_PKCS1_PADDING) { }
|
||||
function openssl_private_encrypt(string $data, &$encrypted_data, $private_key, int $padding = OPENSSL_PKCS1_PADDING): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Decrypts data with private key
|
||||
|
@ -889,7 +940,8 @@ function openssl_private_encrypt(string $data, &$encrypted_data, $private_key, i
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_private_decrypt(string $data, &$decrypted_data, $private_key, int $padding = OPENSSL_PKCS1_PADDING) { }
|
||||
function openssl_private_decrypt(string $data, &$decrypted_data, $private_key, int $padding = OPENSSL_PKCS1_PADDING): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Encrypts data with public key
|
||||
|
@ -910,7 +962,8 @@ function openssl_private_decrypt(string $data, &$decrypted_data, $private_key, i
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_public_encrypt(string $data, &$encrypted_data, $public_key, int $padding = OPENSSL_PKCS1_PADDING) { }
|
||||
function openssl_public_encrypt(string $data, &$encrypted_data, $public_key, int $padding = OPENSSL_PKCS1_PADDING): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Decrypts data with public key
|
||||
|
@ -928,7 +981,8 @@ function openssl_public_encrypt(string $data, &$encrypted_data, $public_key, int
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_public_decrypt(string $data, &$decrypted_data, $public_key, int $padding = OPENSSL_PKCS1_PADDING) { }
|
||||
function openssl_public_decrypt(string $data, &$decrypted_data, $public_key, int $padding = OPENSSL_PKCS1_PADDING): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Gets available digest methods
|
||||
|
@ -939,7 +993,8 @@ function openssl_public_decrypt(string $data, &$decrypted_data, $public_key, int
|
|||
* </p>
|
||||
* @return array An array of available digest methods.
|
||||
*/
|
||||
function openssl_get_md_methods(bool $aliases = false) { }
|
||||
function openssl_get_md_methods(bool $aliases = false): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Gets available cipher methods
|
||||
|
@ -950,7 +1005,8 @@ function openssl_get_md_methods(bool $aliases = false) { }
|
|||
* </p>
|
||||
* @return array An array of available cipher methods.
|
||||
*/
|
||||
function openssl_get_cipher_methods(bool $aliases = false) { }
|
||||
function openssl_get_cipher_methods(bool $aliases = false): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* (No version information available, might only be in SVN)<br/>
|
||||
|
@ -964,7 +1020,8 @@ function openssl_get_cipher_methods(bool $aliases = false) { }
|
|||
* </p>
|
||||
* @return string|false computed key on success or false on failure.
|
||||
*/
|
||||
function openssl_dh_compute_key(string $public_key, #[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] $private_key) { }
|
||||
function openssl_dh_compute_key(string $public_key, #[LanguageLevelTypeAware(["8.0" => "OpenSSLAsymmetricKey"], default: "resource")] $private_key): string|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* @param $public_key
|
||||
|
@ -972,7 +1029,7 @@ function openssl_dh_compute_key(string $public_key, #[LanguageLevelTypeAware(["8
|
|||
* @param $key_length
|
||||
* @since 7.3
|
||||
*/
|
||||
function openssl_pkey_derive($public_key, $private_key, int $key_length) {}
|
||||
function openssl_pkey_derive($public_key, $private_key, int $key_length): string|false {}
|
||||
|
||||
/**
|
||||
* Generates a string of pseudo-random bytes, with the number of bytes determined by the length parameter.
|
||||
|
@ -990,7 +1047,9 @@ function openssl_pkey_derive($public_key, $private_key, int $key_length) {}
|
|||
* </p>
|
||||
* @return string|false the generated string of bytes on success, or false on failure.
|
||||
*/
|
||||
function openssl_random_pseudo_bytes(int $length, &$strong_result) { }
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function openssl_random_pseudo_bytes(int $length, &$strong_result)
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Return openSSL error message
|
||||
|
@ -998,7 +1057,8 @@ function openssl_random_pseudo_bytes(int $length, &$strong_result) { }
|
|||
* @return string|false an error message string, or false if there are no more error
|
||||
* messages to return.
|
||||
*/
|
||||
function openssl_error_string() { }
|
||||
function openssl_error_string(): string|false
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Retrieve the available certificate locations
|
||||
|
@ -1006,9 +1066,10 @@ function openssl_error_string() { }
|
|||
* @return array an array with the available certificate locations
|
||||
* @since 5.6
|
||||
*/
|
||||
function openssl_get_cert_locations() { }
|
||||
function openssl_get_cert_locations(): array
|
||||
{ }
|
||||
|
||||
function openssl_get_curve_names() {}
|
||||
function openssl_get_curve_names(): array|false {}
|
||||
|
||||
/**
|
||||
* @param string $input_filename
|
||||
|
@ -1016,7 +1077,8 @@ function openssl_get_curve_names() {}
|
|||
* @return bool
|
||||
* @since 7.2
|
||||
*/
|
||||
function openssl_pkcs7_read(string $input_filename, &$certificates) {}
|
||||
function openssl_pkcs7_read(string $input_filename, &$certificates): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Verifies that the data block is intact, the signer is who they say they are, and returns the certs of the signers.
|
||||
|
|
|
@ -12,7 +12,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* parent's context, no child process will be created, and a PHP
|
||||
* error is raised.
|
||||
*/
|
||||
function pcntl_fork () {}
|
||||
function pcntl_fork (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Waits on or returns the status of a forked child
|
||||
|
@ -93,7 +94,8 @@ function pcntl_fork () {}
|
|||
* child which exited, -1 on error or zero if <b>WNOHANG</b> was used and no
|
||||
* child was available
|
||||
*/
|
||||
function pcntl_waitpid (int $process_id, &$status, int $flags = 0, &$resource_usage) {}
|
||||
function pcntl_waitpid (int $process_id, &$status, int $flags = 0, &$resource_usage): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Waits on or returns the status of a forked child
|
||||
|
@ -139,7 +141,8 @@ function pcntl_waitpid (int $process_id, &$status, int $flags = 0, &$resource_us
|
|||
* child which exited, -1 on error or zero if WNOHANG was provided as an
|
||||
* option (on wait3-available systems) and no child was available.
|
||||
*/
|
||||
function pcntl_wait (&$status, int $flags = 0, &$resource_usage) {}
|
||||
function pcntl_wait (&$status, int $flags = 0, &$resource_usage): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Installs a signal handler
|
||||
|
@ -169,14 +172,16 @@ function pcntl_wait (&$status, int $flags = 0, &$resource_usage) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pcntl_signal (int $signal, $handler, bool $restart_syscalls = true) {}
|
||||
function pcntl_signal (int $signal, $handler, bool $restart_syscalls = true): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calls signal handlers for pending signals
|
||||
* @link https://php.net/manual/en/function.pcntl-signal-dispatch.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pcntl_signal_dispatch () {}
|
||||
function pcntl_signal_dispatch (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if status code represents a normal exit
|
||||
|
@ -188,7 +193,8 @@ function pcntl_signal_dispatch () {}
|
|||
* otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_wifexited (int $status) {}
|
||||
function pcntl_wifexited (int $status): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks whether the child process is currently stopped
|
||||
|
@ -200,7 +206,8 @@ function pcntl_wifexited (int $status) {}
|
|||
* currently stopped, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_wifstopped (int $status) {}
|
||||
function pcntl_wifstopped (int $status): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks whether the status code represents a termination due to a signal
|
||||
|
@ -212,7 +219,8 @@ function pcntl_wifstopped (int $status) {}
|
|||
* not caught, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_wifsignaled (int $status) {}
|
||||
function pcntl_wifsignaled (int $status): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the return code of a terminated child
|
||||
|
@ -220,17 +228,19 @@ function pcntl_wifsignaled (int $status) {}
|
|||
* @param int $status The <i>status</i>
|
||||
* parameter is the status parameter supplied to a successful
|
||||
* call to <b>pcntl_waitpid</b>.</p>
|
||||
* @return int the return code, as an integer.
|
||||
* @return int|false the return code, as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_wexitstatus (int $status) {}
|
||||
function pcntl_wexitstatus (int $status): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* @param int $status
|
||||
* @return bool
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_wifcontinued (int $status){}
|
||||
function pcntl_wifcontinued (int $status): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the signal which caused the child to terminate
|
||||
|
@ -238,10 +248,11 @@ function pcntl_wifcontinued (int $status){}
|
|||
* @param int $status The <i>status</i>
|
||||
* parameter is the status parameter supplied to a successful
|
||||
* call to <b>pcntl_waitpid</b>.</p>
|
||||
* @return int the signal number, as an integer.
|
||||
* @return int|false the signal number, as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_wtermsig (int $status) {}
|
||||
function pcntl_wtermsig (int $status): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the signal which caused the child to stop
|
||||
|
@ -249,10 +260,11 @@ function pcntl_wtermsig (int $status) {}
|
|||
* @param int $status The <i>status</i>
|
||||
* parameter is the status parameter supplied to a successful
|
||||
* call to <b>pcntl_waitpid</b>.</p>
|
||||
* @return int the signal number.
|
||||
* @return int|false the signal number.
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_wstopsig (int $status) {}
|
||||
function pcntl_wstopsig (int $status): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Executes specified program in current process space
|
||||
|
@ -273,9 +285,9 @@ function pcntl_wstopsig (int $status) {}
|
|||
* the key being the name of the environmental variable and the value being
|
||||
* the value of that variable.
|
||||
* </p>
|
||||
* @return void <b>FALSE</b> on error and does not return on success.
|
||||
* @return bool <b>FALSE</b> on error and does not return on success.
|
||||
*/
|
||||
function pcntl_exec (string $path, array $args, array $env_vars)
|
||||
function pcntl_exec (string $path, array $args, array $env_vars): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -289,7 +301,8 @@ function pcntl_exec (string $path, array $args, array $env_vars)
|
|||
* remaining before it was to be delivered, or 0 if there
|
||||
* was no previously scheduled alarm.
|
||||
*/
|
||||
function pcntl_alarm (int $seconds) {}
|
||||
function pcntl_alarm (int $seconds): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve the error number set by the last pcntl function which failed
|
||||
|
@ -298,7 +311,8 @@ function pcntl_alarm (int $seconds) {}
|
|||
* @since 5.3.4
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_get_last_error () {}
|
||||
function pcntl_get_last_error (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias of <b>pcntl_get_last_error</b>
|
||||
|
@ -307,7 +321,8 @@ function pcntl_get_last_error () {}
|
|||
* @since 5.3.4
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_errno () {}
|
||||
function pcntl_errno (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve the system error message associated with the given errno
|
||||
|
@ -318,7 +333,9 @@ function pcntl_errno () {}
|
|||
* @since 5.3.4
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_strerror (int $error_code) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function pcntl_strerror (int $error_code): bool|string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the priority of any process
|
||||
|
@ -330,12 +347,13 @@ function pcntl_strerror (int $error_code) {}
|
|||
* One of <b>PRIO_PGRP</b>, <b>PRIO_USER</b>
|
||||
* or <b>PRIO_PROCESS</b>.
|
||||
* </p>
|
||||
* @return int <b>pcntl_getpriority</b> returns the priority of the process
|
||||
* @return int|false <b>pcntl_getpriority</b> returns the priority of the process
|
||||
* or <b>FALSE</b> on error. A lower numerical value causes more favorable
|
||||
* scheduling.
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_getpriority (int $process_id, int $mode = PRIO_PROCESS) {}
|
||||
function pcntl_getpriority (int $process_id, int $mode = PRIO_PROCESS): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Change the priority of any process
|
||||
|
@ -357,7 +375,8 @@ function pcntl_getpriority (int $process_id, int $mode = PRIO_PROCESS) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pcntl_setpriority (int $priority, int $process_id, int $mode = PRIO_PROCESS) {}
|
||||
function pcntl_setpriority (int $priority, int $process_id, int $mode = PRIO_PROCESS): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets and retrieves blocked signals
|
||||
|
@ -381,7 +400,7 @@ function pcntl_setpriority (int $priority, int $process_id, int $mode = PRIO_PRO
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pcntl_sigprocmask (int $mode, array $signals, &$old_signals)
|
||||
function pcntl_sigprocmask (int $mode, array $signals, &$old_signals): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -420,9 +439,10 @@ function pcntl_sigprocmask (int $mode, array $signals, &$old_signals)
|
|||
* band: Band event
|
||||
* fd: File descriptor number
|
||||
* </p>
|
||||
* @return int On success, <b>pcntl_sigwaitinfo</b> returns a signal number.
|
||||
* @return int|false On success, <b>pcntl_sigwaitinfo</b> returns a signal number.
|
||||
*/
|
||||
function pcntl_sigwaitinfo (array $signals, &$info) {}
|
||||
function pcntl_sigwaitinfo (array $signals, &$info): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Waits for signals, with a timeout
|
||||
|
@ -441,9 +461,10 @@ function pcntl_sigwaitinfo (array $signals, &$info) {}
|
|||
* @param int $nanoseconds [optional] <p>
|
||||
* Timeout in nanoseconds.
|
||||
* </p>
|
||||
* @return int On success, <b>pcntl_sigtimedwait</b> returns a signal number.
|
||||
* @return int|false On success, <b>pcntl_sigtimedwait</b> returns a signal number.
|
||||
*/
|
||||
function pcntl_sigtimedwait (array $signals, &$info, int $seconds = 0, int $nanoseconds = 0) {}
|
||||
function pcntl_sigtimedwait (array $signals, &$info, int $seconds = 0, int $nanoseconds = 0): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Enable/disable asynchronous signal handling or return the old setting.<br>
|
||||
|
@ -458,7 +479,8 @@ function pcntl_sigtimedwait (array $signals, &$info, int $seconds = 0, int $nano
|
|||
* @return bool
|
||||
* @since 7.1
|
||||
*/
|
||||
function pcntl_async_signals(bool $enable) {}
|
||||
function pcntl_async_signals(bool $enable): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the current handler for specified signal.
|
||||
|
@ -468,18 +490,19 @@ function pcntl_async_signals(bool $enable) {}
|
|||
* The signal number.
|
||||
* </p>
|
||||
*
|
||||
* @return bool
|
||||
* @return bool|resource
|
||||
* @since 7.1
|
||||
*/
|
||||
|
||||
function pcntl_signal_get_handler(int $signal) {}
|
||||
function pcntl_signal_get_handler(int $signal)
|
||||
{}
|
||||
|
||||
/**
|
||||
* @param int $flags
|
||||
* @return bool
|
||||
* @since 7.4
|
||||
*/
|
||||
function pcntl_unshare(int $flags){}
|
||||
function pcntl_unshare(int $flags): bool{}
|
||||
|
||||
define ('WNOHANG', 1);
|
||||
define ('WUNTRACED', 2);
|
||||
|
|
|
@ -155,7 +155,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* matches given <i>subject</i>, 0 if it does not, or <b>FALSE</b>
|
||||
* if an error occurred.
|
||||
*/
|
||||
function preg_match (string $pattern, string $subject, &$matches, int $flags = 0, int $offset = 0) {}
|
||||
function preg_match (string $pattern, string $subject, &$matches, int $flags = 0, int $offset = 0): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Perform a global regular expression match
|
||||
|
@ -212,10 +213,11 @@ function preg_match (string $pattern, string $subject, &$matches, int $flags = 0
|
|||
* </p>
|
||||
* </p>
|
||||
* @param int $offset [optional]
|
||||
* @return int|false the number of full pattern matches (which might be zero),
|
||||
* @return int|false|null the number of full pattern matches (which might be zero),
|
||||
* or <b>FALSE</b> if an error occurred.
|
||||
*/
|
||||
function preg_match_all (string $pattern, string $subject, &$matches, int $flags = PREG_PATTERN_ORDER, int $offset = 0) {}
|
||||
function preg_match_all (string $pattern, string $subject, &$matches, int $flags = PREG_PATTERN_ORDER, int $offset = 0): int|false|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Perform a regular expression search and replace
|
||||
|
@ -303,7 +305,7 @@ function preg_match_all (string $pattern, string $subject, &$matches, int $flags
|
|||
* be returned, otherwise <i>subject</i> will be
|
||||
* returned unchanged or <b>NULL</b> if an error occurred.
|
||||
*/
|
||||
function preg_replace (array|string $pattern, array|string $replacement, array|string $subject, int $limit = -1, &$count)
|
||||
function preg_replace (array|string $pattern, array|string $replacement, array|string $subject, int $limit = -1, &$count): array|string|null
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -375,7 +377,7 @@ function preg_replace (array|string $pattern, array|string $replacement, array|s
|
|||
* If matches are found, the new subject will be returned, otherwise
|
||||
* <i>subject</i> will be returned unchanged.
|
||||
*/
|
||||
function preg_replace_callback (array|string $pattern, callable $callback, array|string $subject, int $limit = -1, &$count, int $flags = 0)
|
||||
function preg_replace_callback (array|string $pattern, callable $callback, array|string $subject, int $limit = -1, &$count, int $flags = 0): array|string|null
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -389,7 +391,8 @@ function preg_replace_callback (array|string $pattern, callable $callback, array
|
|||
* @return string|string[]|null <p>preg_replace_callback_array() returns an array if the subject parameter is an array, or a string otherwise. On errors the return value is NULL</p>
|
||||
* <p>If matches are found, the new subject will be returned, otherwise subject will be returned unchanged.</p>
|
||||
*/
|
||||
function preg_replace_callback_array (array $pattern, array|string $subject , int $limit = -1, &$count, int $flags = 0) {}
|
||||
function preg_replace_callback_array (array $pattern, array|string $subject , int $limit = -1, &$count, int $flags = 0): array|string|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Perform a regular expression search and replace
|
||||
|
@ -407,7 +410,8 @@ function preg_replace_callback_array (array $pattern, array|string $subject , in
|
|||
* is returned when <i>subject</i> is an array
|
||||
* or <b>NULL</b> otherwise.
|
||||
*/
|
||||
function preg_filter (array|string $pattern, array|string $replacement, array|string $subject, int $limit = -1, &$count) {}
|
||||
function preg_filter (array|string $pattern, array|string $replacement, array|string $subject, int $limit = -1, &$count): array|string|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Split string by a regular expression
|
||||
|
@ -436,7 +440,8 @@ function preg_filter (array|string $pattern, array|string $replacement, array|st
|
|||
* if an error occurred.
|
||||
*/
|
||||
#[Pure]
|
||||
function preg_split (string $pattern, string $subject, int $limit = -1, int $flags = 0) {}
|
||||
function preg_split (string $pattern, string $subject, int $limit = -1, int $flags = 0): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Quote regular expression characters
|
||||
|
@ -453,7 +458,7 @@ function preg_split (string $pattern, string $subject, int $limit = -1, int $fla
|
|||
* @return string the quoted (escaped) string.
|
||||
*/
|
||||
#[Pure]
|
||||
function preg_quote (string $str, string $delimiter)
|
||||
function preg_quote (string $str, string $delimiter): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -474,7 +479,8 @@ function preg_quote (string $str, string $delimiter)
|
|||
* <i>input</i> array or false when pattern cannot be compiled.
|
||||
*/
|
||||
#[Pure]
|
||||
function preg_grep (string $pattern, array $array, int $flags = 0) {}
|
||||
function preg_grep (string $pattern, array $array, int $flags = 0): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the error code of the last PCRE regex execution
|
||||
|
@ -488,7 +494,8 @@ function preg_grep (string $pattern, array $array, int $flags = 0) {}
|
|||
* <b>PREG_BAD_UTF8_OFFSET_ERROR</b> (since PHP 5.3.0)
|
||||
*/
|
||||
#[Pure]
|
||||
function preg_last_error () {}
|
||||
function preg_last_error (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the error message of the last PCRE regex execution
|
||||
|
|
134
posix/posix.php
134
posix/posix.php
|
@ -14,7 +14,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function posix_kill (int $process_id, int $signal) {}
|
||||
function posix_kill (int $process_id, int $signal): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the current process identifier
|
||||
|
@ -22,7 +23,8 @@ function posix_kill (int $process_id, int $signal) {}
|
|||
* @return int the identifier, as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getpid () {}
|
||||
function posix_getpid (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the parent process identifier
|
||||
|
@ -30,7 +32,8 @@ function posix_getpid () {}
|
|||
* @return int the identifier, as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getppid () {}
|
||||
function posix_getppid (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the real user ID of the current process
|
||||
|
@ -38,7 +41,8 @@ function posix_getppid () {}
|
|||
* @return int the user id, as an integer
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getuid () {}
|
||||
function posix_getuid (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set the UID of the current process
|
||||
|
@ -48,7 +52,8 @@ function posix_getuid () {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function posix_setuid (int $user_id) {}
|
||||
function posix_setuid (int $user_id): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the effective user ID of the current process
|
||||
|
@ -56,7 +61,8 @@ function posix_setuid (int $user_id) {}
|
|||
* @return int the user id, as an integer
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_geteuid () {}
|
||||
function posix_geteuid (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set the effective UID of the current process
|
||||
|
@ -66,7 +72,8 @@ function posix_geteuid () {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function posix_seteuid (int $user_id) {}
|
||||
function posix_seteuid (int $user_id): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set system resource limits
|
||||
|
@ -81,14 +88,16 @@ function posix_seteuid (int $user_id) {}
|
|||
* @return bool Returns TRUE on success or FALSE on failure.
|
||||
* @since 7.0
|
||||
*/
|
||||
function posix_setrlimit (int $resource, int $soft_limit, int $hard_limit) {}
|
||||
function posix_setrlimit (int $resource, int $soft_limit, int $hard_limit): bool
|
||||
{}
|
||||
/**
|
||||
* Return the real group ID of the current process
|
||||
* @link https://php.net/manual/en/function.posix-getgid.php
|
||||
* @return int the real group id, as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getgid () {}
|
||||
function posix_getgid (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set the GID of the current process
|
||||
|
@ -98,7 +107,8 @@ function posix_getgid () {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function posix_setgid (int $group_id) {}
|
||||
function posix_setgid (int $group_id): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the effective group ID of the current process
|
||||
|
@ -106,7 +116,8 @@ function posix_setgid (int $group_id) {}
|
|||
* @return int an integer of the effective group ID.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getegid () {}
|
||||
function posix_getegid (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set the effective GID of the current process
|
||||
|
@ -116,24 +127,27 @@ function posix_getegid () {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function posix_setegid (int $group_id) {}
|
||||
function posix_setegid (int $group_id): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the group set of the current process
|
||||
* @link https://php.net/manual/en/function.posix-getgroups.php
|
||||
* @return array an array of integers containing the numeric group ids of the group
|
||||
* @return array|false an array of integers containing the numeric group ids of the group
|
||||
* set of the current process.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getgroups () {}
|
||||
function posix_getgroups (): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return login name
|
||||
* @link https://php.net/manual/en/function.posix-getlogin.php
|
||||
* @return string the login name of the user, as a string.
|
||||
* @return string|false the login name of the user, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getlogin () {}
|
||||
function posix_getlogin (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the current process group identifier
|
||||
|
@ -141,14 +155,16 @@ function posix_getlogin () {}
|
|||
* @return int the identifier, as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getpgrp () {}
|
||||
function posix_getpgrp (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Make the current process a session leader
|
||||
* @link https://php.net/manual/en/function.posix-setsid.php
|
||||
* @return int the session id, or -1 on errors.
|
||||
*/
|
||||
function posix_setsid () {}
|
||||
function posix_setsid (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set process group id for job control
|
||||
|
@ -161,7 +177,8 @@ function posix_setsid () {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function posix_setpgid (int $process_id, int $process_group_id) {}
|
||||
function posix_setpgid (int $process_id, int $process_group_id): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get process group id for job control
|
||||
|
@ -169,10 +186,11 @@ function posix_setpgid (int $process_id, int $process_group_id) {}
|
|||
* @param int $process_id <p>
|
||||
* The process id.
|
||||
* </p>
|
||||
* @return int the identifier, as an integer.
|
||||
* @return int|false the identifier, as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getpgid (int $process_id) {}
|
||||
function posix_getpgid (int $process_id): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the current sid of the process
|
||||
|
@ -183,15 +201,16 @@ function posix_getpgid (int $process_id) {}
|
|||
* specified, then <b>FALSE</b> is returned and an error is set which
|
||||
* can be checked with <b>posix_get_last_error</b>.
|
||||
* </p>
|
||||
* @return int the identifier, as an integer.
|
||||
* @return int|false the identifier, as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getsid (int $process_id) {}
|
||||
function posix_getsid (int $process_id): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get system name
|
||||
* @link https://php.net/manual/en/function.posix-uname.php
|
||||
* @return array a hash of strings with information about the
|
||||
* @return array|false a hash of strings with information about the
|
||||
* system. The indices of the hash are
|
||||
* sysname - operating system name (e.g. Linux)
|
||||
* nodename - system name (e.g. valiant)
|
||||
|
@ -207,12 +226,13 @@ function posix_getsid (int $process_id) {}
|
|||
* libc.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_uname () {}
|
||||
function posix_uname (): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get process times
|
||||
* @link https://php.net/manual/en/function.posix-times.php
|
||||
* @return array a hash of strings with information about the current
|
||||
* @return array|false a hash of strings with information about the current
|
||||
* process CPU usage. The indices of the hash are:
|
||||
* ticks - the number of clock ticks that have elapsed since
|
||||
* reboot.
|
||||
|
@ -222,7 +242,8 @@ function posix_uname () {}
|
|||
* cstime - system time used by current process and children.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_times () {}
|
||||
function posix_times (): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get path name of controlling terminal
|
||||
|
@ -232,7 +253,8 @@ function posix_times () {}
|
|||
* is set, which can be checked with <b>posix_get_last_error</b>.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_ctermid () {}
|
||||
function posix_ctermid (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Determine terminal device name
|
||||
|
@ -244,7 +266,8 @@ function posix_ctermid () {}
|
|||
* <i>fd</i>. On failure, returns <b>FALSE</b>
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_ttyname ($file_descriptor) {}
|
||||
function posix_ttyname ($file_descriptor): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Determine if a file descriptor is an interactive terminal
|
||||
|
@ -259,17 +282,19 @@ function posix_ttyname ($file_descriptor) {}
|
|||
* to a terminal and <b>FALSE</b> otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_isatty ($file_descriptor) {}
|
||||
function posix_isatty ($file_descriptor): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Pathname of current directory
|
||||
* @link https://php.net/manual/en/function.posix-getcwd.php
|
||||
* @return string a string of the absolute pathname on success.
|
||||
* @return string|false a string of the absolute pathname on success.
|
||||
* On error, returns <b>FALSE</b> and sets errno which can be checked with
|
||||
* <b>posix_get_last_error</b>.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getcwd () {}
|
||||
function posix_getcwd (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Create a fifo special file (a named pipe)
|
||||
|
@ -286,7 +311,8 @@ function posix_getcwd () {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function posix_mkfifo (string $filename, int $permissions) {}
|
||||
function posix_mkfifo (string $filename, int $permissions): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Create a special or ordinary file (POSIX.1)
|
||||
|
@ -310,7 +336,8 @@ function posix_mkfifo (string $filename, int $permissions) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function posix_mknod (string $filename, int $flags, int $major = 0, int $minor = 0) {}
|
||||
function posix_mknod (string $filename, int $flags, int $major = 0, int $minor = 0): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Determine accessibility of a file
|
||||
|
@ -332,13 +359,14 @@ function posix_mknod (string $filename, int $flags, int $major = 0, int $minor =
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function posix_access (string $filename, int $flags = POSIX_F_OK) {}
|
||||
function posix_access (string $filename, int $flags = POSIX_F_OK): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return info about a group by name
|
||||
* @link https://php.net/manual/en/function.posix-getgrnam.php
|
||||
* @param string $name <p>The name of the group</p>
|
||||
* @return array The array elements returned are:
|
||||
* @return array|false The array elements returned are:
|
||||
* <table>
|
||||
* The group information array
|
||||
* <tr valign="top">
|
||||
|
@ -379,7 +407,8 @@ function posix_access (string $filename, int $flags = POSIX_F_OK) {}
|
|||
* </table>
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getgrnam (string $name) {}
|
||||
function posix_getgrnam (string $name): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return info about a group by group id
|
||||
|
@ -387,7 +416,7 @@ function posix_getgrnam (string $name) {}
|
|||
* @param int $group_id <p>
|
||||
* The group id.
|
||||
* </p>
|
||||
* @return array The array elements returned are:
|
||||
* @return array|false The array elements returned are:
|
||||
* <table>
|
||||
* The group information array
|
||||
* <tr valign="top">
|
||||
|
@ -428,7 +457,8 @@ function posix_getgrnam (string $name) {}
|
|||
* </table>
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getgrgid (int $group_id) {}
|
||||
function posix_getgrgid (int $group_id): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return info about a user by username
|
||||
|
@ -436,7 +466,7 @@ function posix_getgrgid (int $group_id) {}
|
|||
* @param string $username <p>
|
||||
* An alphanumeric username.
|
||||
* </p>
|
||||
* @return array On success an array with the following elements is returned, else
|
||||
* @return array|false On success an array with the following elements is returned, else
|
||||
* <b>FALSE</b> is returned:
|
||||
* <table>
|
||||
* The user information array
|
||||
|
@ -505,7 +535,8 @@ function posix_getgrgid (int $group_id) {}
|
|||
* </table>
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getpwnam (string $username) {}
|
||||
function posix_getpwnam (string $username): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return info about a user by user id
|
||||
|
@ -513,7 +544,7 @@ function posix_getpwnam (string $username) {}
|
|||
* @param int $user_id <p>
|
||||
* The user identifier.
|
||||
* </p>
|
||||
* @return array an associative array with the following elements:
|
||||
* @return array|false an associative array with the following elements:
|
||||
* <table>
|
||||
* The user information array
|
||||
* <tr valign="top">
|
||||
|
@ -581,12 +612,13 @@ function posix_getpwnam (string $username) {}
|
|||
* </table>
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getpwuid (int $user_id) {}
|
||||
function posix_getpwuid (int $user_id): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return info about system resource limits
|
||||
* @link https://php.net/manual/en/function.posix-getrlimit.php
|
||||
* @return array an associative array of elements for each
|
||||
* @return array|false an associative array of elements for each
|
||||
* limit that is defined. Each limit has a soft and a hard limit.
|
||||
* <table>
|
||||
* List of possible limits returned
|
||||
|
@ -666,7 +698,8 @@ function posix_getpwuid (int $user_id) {}
|
|||
* </table>
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_getrlimit () {}
|
||||
function posix_getrlimit (): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve the error number set by the last posix function that failed
|
||||
|
@ -675,14 +708,15 @@ function posix_getrlimit () {}
|
|||
* failed. If no errors exist, 0 is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_get_last_error () {}
|
||||
function posix_get_last_error (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias of <b>posix_get_last_error</b>
|
||||
* @link https://php.net/manual/en/function.posix-errno.php
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_errno () {}
|
||||
function posix_errno (): int {}
|
||||
|
||||
/**
|
||||
* Retrieve the system error message associated with the given errno
|
||||
|
@ -695,7 +729,8 @@ function posix_errno () {}
|
|||
* @return string the error message, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_strerror (int $error_code) {}
|
||||
function posix_strerror (int $error_code): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculate the group access list
|
||||
|
@ -709,7 +744,8 @@ function posix_strerror (int $error_code) {}
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function posix_initgroups (string $username, int $group_id) {}
|
||||
function posix_initgroups (string $username, int $group_id): bool
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
* @return string|false a single string from the user. The line returned has the ending newline removed.
|
||||
* If there is no more data to read, then FALSE is returned.
|
||||
*/
|
||||
function readline (string $prompt) {}
|
||||
function readline (string $prompt): string|false {}
|
||||
|
||||
/**
|
||||
* Gets/sets various internal readline variables
|
||||
|
@ -31,7 +31,7 @@ function readline (string $prompt) {}
|
|||
* <p>
|
||||
* If called with one or two parameters, the old value is returned.
|
||||
*/
|
||||
function readline_info (string $var_name, $value) {}
|
||||
function readline_info (string $var_name, $value): mixed {}
|
||||
|
||||
/**
|
||||
* Adds a line to the history
|
||||
|
@ -41,14 +41,16 @@ function readline_info (string $var_name, $value) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function readline_add_history (string $prompt) {}
|
||||
function readline_add_history (string $prompt): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Clears the history
|
||||
* @link https://php.net/manual/en/function.readline-clear-history.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function readline_clear_history () {}
|
||||
function readline_clear_history (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Lists the history
|
||||
|
@ -56,7 +58,8 @@ function readline_clear_history () {}
|
|||
* @return array an array of the entire command line history. The elements are
|
||||
* indexed by integers starting at zero.
|
||||
*/
|
||||
function readline_list_history () {}
|
||||
function readline_list_history (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Reads the history
|
||||
|
@ -66,7 +69,8 @@ function readline_list_history () {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function readline_read_history (string $filename) {}
|
||||
function readline_read_history (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Writes the history
|
||||
|
@ -76,7 +80,8 @@ function readline_read_history (string $filename) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function readline_write_history (string $filename) {}
|
||||
function readline_write_history (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Registers a completion function
|
||||
|
@ -87,7 +92,8 @@ function readline_write_history (string $filename) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function readline_completion_function (callable $callback) {}
|
||||
function readline_completion_function (callable $callback): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Initializes the readline callback interface and terminal, prints the prompt and returns immediately
|
||||
|
@ -101,14 +107,15 @@ function readline_completion_function (callable $callback) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function readline_callback_handler_install (string $prompt, callable $callback) {}
|
||||
function readline_callback_handler_install (string $prompt, callable $callback): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Reads a character and informs the readline callback interface when a line is received
|
||||
* @link https://php.net/manual/en/function.readline-callback-read-char.php
|
||||
* @return void No value is returned.
|
||||
*/
|
||||
function readline_callback_read_char () {}
|
||||
function readline_callback_read_char (): void {}
|
||||
|
||||
/**
|
||||
* Removes a previously installed callback handler and restores terminal settings
|
||||
|
@ -116,21 +123,22 @@ function readline_callback_read_char () {}
|
|||
* @return bool <b>TRUE</b> if a previously installed callback handler was removed, or
|
||||
* <b>FALSE</b> if one could not be found.
|
||||
*/
|
||||
function readline_callback_handler_remove () {}
|
||||
function readline_callback_handler_remove (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Redraws the display
|
||||
* @link https://php.net/manual/en/function.readline-redisplay.php
|
||||
* @return void No value is returned.
|
||||
*/
|
||||
function readline_redisplay () {}
|
||||
function readline_redisplay (): void {}
|
||||
|
||||
/**
|
||||
* Inform readline that the cursor has moved to a new line
|
||||
* @link https://php.net/manual/en/function.readline-on-new-line.php
|
||||
* @return void No value is returned.
|
||||
*/
|
||||
function readline_on_new_line () {}
|
||||
function readline_on_new_line (): void {}
|
||||
|
||||
define ('READLINE_LIB', "libedit");
|
||||
|
||||
|
|
|
@ -21,9 +21,10 @@ use JetBrains\PhpStorm\Deprecated;
|
|||
* must be present. Otherwise a new session id is generated every time.
|
||||
* </p>
|
||||
* </p>
|
||||
* @return string the name of the current session.
|
||||
* @return string|false the name of the current session.
|
||||
*/
|
||||
function session_name (string $name) {}
|
||||
function session_name (string $name): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get and/or set the current session module.<br/>
|
||||
|
@ -33,9 +34,10 @@ function session_name (string $name) {}
|
|||
* If <i>module</i> is specified, that module will be
|
||||
* used instead.
|
||||
* </p>
|
||||
* @return string the name of the current session module.
|
||||
* @return string|false the name of the current session module.
|
||||
*/
|
||||
function session_module_name (string $module) {}
|
||||
function session_module_name (string $module): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get and/or set the current session save path
|
||||
|
@ -52,9 +54,10 @@ function session_module_name (string $module) {}
|
|||
* on Linux, reiserfs may provide better performance than ext2fs.
|
||||
* </p>
|
||||
* </p>
|
||||
* @return string the path of the current directory used for data storage.
|
||||
* @return string|false the path of the current directory used for data storage.
|
||||
*/
|
||||
function session_save_path (string $path) {}
|
||||
function session_save_path (string $path): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get and/or set the current session id
|
||||
|
@ -71,11 +74,12 @@ function session_save_path (string $path) {}
|
|||
* for <b>session_id</b> will always send a new cookie
|
||||
* when <b>session_start</b> is called, regardless if the
|
||||
* current session id is identical to the one being set.
|
||||
* @return string <b>session_id</b> returns the session id for the current
|
||||
* @return string|false <b>session_id</b> returns the session id for the current
|
||||
* session or the empty string ("") if there is no current
|
||||
* session (no current session id exists).
|
||||
*/
|
||||
function session_id (string $id) {}
|
||||
function session_id (string $id): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Update the current session id with a newly generated one
|
||||
|
@ -85,7 +89,8 @@ function session_id (string $id) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function session_regenerate_id (bool $delete_old_session = false) {}
|
||||
function session_regenerate_id (bool $delete_old_session = false): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* PHP > 5.4.0 <br/>
|
||||
|
@ -93,7 +98,7 @@ function session_regenerate_id (bool $delete_old_session = false) {}
|
|||
* @link https://secure.php.net/manual/en/function.session-register-shutdown.php
|
||||
* @return void
|
||||
*/
|
||||
function session_register_shutdown () {}
|
||||
function session_register_shutdown (): void {}
|
||||
|
||||
/**
|
||||
* Decodes session data from a string
|
||||
|
@ -103,7 +108,8 @@ function session_register_shutdown () {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function session_decode (string $data) {}
|
||||
function session_decode (string $data): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Register one or more global variables with the current session
|
||||
|
@ -117,7 +123,8 @@ function session_decode (string $data) {}
|
|||
* @removed 5.4
|
||||
*/
|
||||
#[Deprecated(since: '5.3')]
|
||||
function session_register (mixed $name, ...$_) {}
|
||||
function session_register (mixed $name, ...$_): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Unregister a global variable from the current session
|
||||
|
@ -129,7 +136,8 @@ function session_register (mixed $name, ...$_) {}
|
|||
* @removed 5.4
|
||||
*/
|
||||
#[Deprecated(since: '5.3')]
|
||||
function session_unregister (string $name) {}
|
||||
function session_unregister (string $name): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find out whether a global variable is registered in a session
|
||||
|
@ -143,14 +151,16 @@ function session_unregister (string $name) {}
|
|||
* @removed 5.4
|
||||
*/
|
||||
#[Deprecated(since: '5.3')]
|
||||
function session_is_registered (string $name) {}
|
||||
function session_is_registered (string $name): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Encodes the current session data as a string
|
||||
* @link https://php.net/manual/en/function.session-encode.php
|
||||
* @return string the contents of the current session encoded.
|
||||
* @return string|false the contents of the current session encoded.
|
||||
*/
|
||||
function session_encode () {}
|
||||
function session_encode (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Initialize session data
|
||||
|
@ -160,7 +170,8 @@ function session_encode () {}
|
|||
* @return bool This function returns true if a session was successfully started,
|
||||
* otherwise false.
|
||||
*/
|
||||
function session_start (array $options = []) {}
|
||||
function session_start (array $options = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Create new session id
|
||||
|
@ -168,32 +179,36 @@ function session_start (array $options = []) {}
|
|||
* @param string $prefix [optional] If prefix is specified, new session id is prefixed by prefix.
|
||||
* Not all characters are allowed within the session id.
|
||||
* Characters in the range a-z A-Z 0-9 , (comma) and - (minus) are allowed.
|
||||
* @return string new collision free session id for the current session.
|
||||
* @return string|false new collision free session id for the current session.
|
||||
* If it is used without active session, it omits collision check.
|
||||
* @since 7.1
|
||||
*/
|
||||
function session_create_id(string $prefix) {}
|
||||
function session_create_id(string $prefix): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Perform session data garbage collection
|
||||
* @return int|false number of deleted session data for success, false for failure.
|
||||
* @since 7.1
|
||||
*/
|
||||
function session_gc() {}
|
||||
function session_gc(): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Destroys all data registered to a session
|
||||
* @link https://php.net/manual/en/function.session-destroy.php
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function session_destroy () {}
|
||||
function session_destroy (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Free all session variables
|
||||
* @link https://php.net/manual/en/function.session-unset.php
|
||||
* @return void|bool since 7.2.0 returns true on success or false on failure.
|
||||
*/
|
||||
function session_unset () {}
|
||||
function session_unset (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets user-level session storage functions
|
||||
|
@ -243,7 +258,7 @@ function session_unset () {}
|
|||
* @param callback $update_timestamp [optional]
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function session_set_save_handler (callable $open, callable $close, callable $read, callable $write, callable $destroy, callable $gc, $create_sid, $validate_sid, $update_timestamp)
|
||||
function session_set_save_handler (callable $open, callable $close, callable $read, callable $write, callable $destroy, callable $gc, $create_sid, $validate_sid, $update_timestamp): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -256,7 +271,8 @@ function session_set_save_handler (callable $open, callable $close, callable $re
|
|||
* @param bool $register_shutdown [optional] Register session_write_close() as a register_shutdown_function() function.
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function session_set_save_handler (SessionHandlerInterface $session_handler, $register_shutdown = true) {}
|
||||
function session_set_save_handler (SessionHandlerInterface $session_handler, $register_shutdown = true): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get and/or set the current cache limiter
|
||||
|
@ -311,9 +327,10 @@ function session_set_save_handler (SessionHandlerInterface $session_handler, $re
|
|||
* </td>
|
||||
* </tr>
|
||||
* </table>
|
||||
* @return string the name of the current cache limiter.
|
||||
* @return string|false the name of the current cache limiter.
|
||||
*/
|
||||
function session_cache_limiter (string $value) {}
|
||||
function session_cache_limiter (string $value): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return current cache expire
|
||||
|
@ -327,10 +344,11 @@ function session_cache_limiter (string $value) {}
|
|||
* session.cache_limiter is set to a value
|
||||
* different from nocache.
|
||||
* </p>
|
||||
* @return int the current setting of session.cache_expire.
|
||||
* @return int|false the current setting of session.cache_expire.
|
||||
* The value returned should be read in minutes, defaults to 180.
|
||||
*/
|
||||
function session_cache_expire (int $value) {}
|
||||
function session_cache_expire (int $value): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set the session cookie parameters
|
||||
|
@ -347,7 +365,8 @@ function session_cache_expire (int $value) {}
|
|||
* @return bool returns true on success or false on failure.
|
||||
* @since 7.3
|
||||
*/
|
||||
function session_set_cookie_params (array $options) {}
|
||||
function session_set_cookie_params (array $options): bool
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
|
@ -378,7 +397,7 @@ function session_set_cookie_params (array $options) {}
|
|||
* </p>
|
||||
* @return void|bool since 7.2.0 returns true on success or false on failure.
|
||||
*/
|
||||
function session_set_cookie_params (array|int $lifetime_or_options, string $path, string $domain, bool $secure = false, bool $httponly = false)
|
||||
function session_set_cookie_params (array|int $lifetime_or_options, string $path, string $domain, bool $secure = false, bool $httponly = false): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -397,21 +416,24 @@ function session_set_cookie_params (array|int $lifetime_or_options, string $path
|
|||
* "httponly" - The
|
||||
* cookie can only be accessed through the HTTP protocol.
|
||||
*/
|
||||
function session_get_cookie_params () {}
|
||||
function session_get_cookie_params (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Write session data and end session
|
||||
* @link https://php.net/manual/en/function.session-write-close.php
|
||||
* @return void|bool since 7.2.0 returns true on success or false on failure.
|
||||
*/
|
||||
function session_write_close () {}
|
||||
function session_write_close (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias of <b>session_write_close</b>
|
||||
* @link https://php.net/manual/en/function.session-commit.php
|
||||
* @return void|bool since 7.2.0 returns true on success or false on failure.
|
||||
*/
|
||||
function session_commit () {}
|
||||
function session_commit (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.4.0)<br>
|
||||
|
@ -422,7 +444,8 @@ function session_commit () {}
|
|||
* <b>PHP_SESSION_ACTIVE</b> if sessions are enabled, and one exists.
|
||||
* @since 5.4
|
||||
*/
|
||||
function session_status () {}
|
||||
function session_status (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.6.0)<br>
|
||||
|
@ -431,7 +454,8 @@ function session_status () {}
|
|||
* @return void|bool since 7.2.0 returns true if a session was successfully reinitialized or false on failure.
|
||||
* @since 5.6
|
||||
*/
|
||||
function session_abort() {}
|
||||
function session_abort(): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.6.0)<br>
|
||||
|
@ -440,7 +464,8 @@ function session_abort() {}
|
|||
* @return void|bool since 7.2.0 returns true if a session was successfully reinitialized or false on failure.
|
||||
* @since 5.6
|
||||
*/
|
||||
function session_reset() {}
|
||||
function session_reset(): bool
|
||||
{}
|
||||
|
||||
// End of session v.
|
||||
?>
|
||||
|
|
|
@ -27,6 +27,7 @@ use JetBrains\PhpStorm\Deprecated;
|
|||
* use to access the shared memory segment you've created. <b>FALSE</b> is
|
||||
* returned on failure.
|
||||
*/
|
||||
#[LanguageLevelTypeAware(["8.0" => "Shmop|false"], default: "Shmop|false")]
|
||||
function shmop_open (int $key, string $mode, int $permissions, int $size) {}
|
||||
|
||||
/**
|
||||
|
@ -44,7 +45,7 @@ function shmop_open (int $key, string $mode, int $permissions, int $size) {}
|
|||
* </p>
|
||||
* @return string|false the data or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function shmop_read (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop, int $offset, int $size) {}
|
||||
function shmop_read (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop, int $offset, int $size): string {}
|
||||
|
||||
/**
|
||||
* Close shared memory block
|
||||
|
@ -56,7 +57,7 @@ function shmop_read (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "reso
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[Deprecated(since: '8.0')]
|
||||
function shmop_close (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop) {}
|
||||
function shmop_close (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop): void {}
|
||||
|
||||
/**
|
||||
* Get size of shared memory block
|
||||
|
@ -68,7 +69,7 @@ function shmop_close (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "res
|
|||
* @return int an int, which represents the number of bytes the shared memory
|
||||
* block occupies.
|
||||
*/
|
||||
function shmop_size (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop) {}
|
||||
function shmop_size (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop): int {}
|
||||
|
||||
/**
|
||||
* Write data into shared memory block
|
||||
|
@ -87,7 +88,7 @@ function shmop_size (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "reso
|
|||
* @return int|false The size of the written <i>data</i>, or <b>FALSE</b> on
|
||||
* failure.
|
||||
*/
|
||||
function shmop_write (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop, string $data, int $offset) {}
|
||||
function shmop_write (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop, string $data, int $offset): int {}
|
||||
|
||||
/**
|
||||
* Delete shared memory block
|
||||
|
@ -98,7 +99,7 @@ function shmop_write (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "res
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function shmop_delete (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop) {}
|
||||
function shmop_delete (#[LanguageLevelTypeAware(["8.0" => "Shmop"], default: "resource")] $shmop): bool {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
|
|
|
@ -906,7 +906,7 @@ class SoapHeader {
|
|||
* </p>
|
||||
* @return bool the original value.
|
||||
*/
|
||||
function use_soap_error_handler (bool $enable = true) {}
|
||||
function use_soap_error_handler (bool $enable = true): bool {}
|
||||
|
||||
/**
|
||||
* Checks if a SOAP call has failed
|
||||
|
@ -916,7 +916,7 @@ function use_soap_error_handler (bool $enable = true) {}
|
|||
* </p>
|
||||
* @return bool This will return <b>TRUE</b> on error, and <b>FALSE</b> otherwise.
|
||||
*/
|
||||
function is_soap_fault (mixed $object) {}
|
||||
function is_soap_fault (mixed $object): bool {}
|
||||
|
||||
define ('SOAP_1_1', 1);
|
||||
define ('SOAP_1_2', 2);
|
||||
|
|
|
@ -112,14 +112,7 @@ function sodium_crypto_aead_aes256gcm_is_available(): bool
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_crypto_aead_aes256gcm_decrypt(
|
||||
string $ciphertext,
|
||||
string $additional_data,
|
||||
string $nonce,
|
||||
string $key
|
||||
): string {
|
||||
unset($ciphertext, $additional_data, $nonce, $key);
|
||||
return '';
|
||||
function sodium_crypto_aead_aes256gcm_decrypt(string $ciphertext, string $additional_data, string $nonce, string $key): string|false {
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -148,7 +141,7 @@ function sodium_crypto_aead_aes256gcm_encrypt(string $message, string $additiona
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_crypto_aead_chacha20poly1305_decrypt(string $ciphertext, string $additional_data, string $nonce, string $key): string {}
|
||||
function sodium_crypto_aead_chacha20poly1305_decrypt(string $ciphertext, string $additional_data, string $nonce, string $key): string|false {}
|
||||
|
||||
/**
|
||||
* Authenticated Encryption with Associated Data (encrypt)
|
||||
|
@ -176,12 +169,7 @@ function sodium_crypto_aead_chacha20poly1305_encrypt(string $message, string $ad
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_crypto_aead_chacha20poly1305_ietf_decrypt(
|
||||
string $ciphertext,
|
||||
string $additional_data,
|
||||
string $nonce,
|
||||
string $key
|
||||
): string {
|
||||
function sodium_crypto_aead_chacha20poly1305_ietf_decrypt(string $ciphertext, string $additional_data, string $nonce, string $key): string|false {
|
||||
unset($ciphertext, $additional_data, $nonce, $key);
|
||||
return '';
|
||||
}
|
||||
|
@ -431,7 +419,7 @@ function sodium_crypto_box_keypair_from_secretkey_and_publickey(string $secret_k
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_crypto_box_open(string $ciphertext, string $nonce, string $key_pair): string {}
|
||||
function sodium_crypto_box_open(string $ciphertext, string $nonce, string $key_pair): string|false {}
|
||||
|
||||
/**
|
||||
* Get an X25519 public key from an X25519 keypair
|
||||
|
@ -480,7 +468,7 @@ function sodium_crypto_box_seal(string $message, string $key_pair): string {}
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_crypto_box_seal_open(string $ciphertext, string $key_pair): string {}
|
||||
function sodium_crypto_box_seal_open(string $ciphertext, string $key_pair): string|false {}
|
||||
|
||||
/**
|
||||
* Extract the X25519 secret key from an X25519 keypair
|
||||
|
@ -692,13 +680,7 @@ function sodium_crypto_secretbox(string $message, string $nonce, string $key): s
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_crypto_secretbox_open(
|
||||
string $ciphertext,
|
||||
string $nonce,
|
||||
string $key
|
||||
): string {
|
||||
unset($ciphertext, $nonce, $key);
|
||||
return '';
|
||||
function sodium_crypto_secretbox_open(string $ciphertext, string $nonce, string $key): string|false {
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -796,7 +778,7 @@ function sodium_crypto_sign_keypair_from_secretkey_and_publickey(
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_crypto_sign_open(string $ciphertext, string $public_key): string {}
|
||||
function sodium_crypto_sign_open(string $ciphertext, string $public_key): string|false {}
|
||||
|
||||
/**
|
||||
* Get the public key from an Ed25519 keypair
|
||||
|
@ -976,7 +958,7 @@ function sodium_hex2bin(string $string, string $ignore): string {}
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_increment(string &$string) {}
|
||||
function sodium_increment(string &$string): void {}
|
||||
|
||||
/**
|
||||
* Add the right operand to the left
|
||||
|
@ -986,7 +968,7 @@ function sodium_increment(string &$string) {}
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_add(string &$string1, string $string2) {}
|
||||
function sodium_add(string &$string1, string $string2): void {}
|
||||
|
||||
/**
|
||||
* Get the true major version of libsodium
|
||||
|
@ -1024,9 +1006,7 @@ function sodium_memcmp(string $string1, string $string2): int {}
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_memzero(
|
||||
&$reference
|
||||
) {
|
||||
function sodium_memzero(&$reference): void {
|
||||
$target = '';
|
||||
}
|
||||
|
||||
|
@ -1104,7 +1084,7 @@ function sodium_crypto_aead_chacha20poly1305_ietf_keygen(): string {}
|
|||
* @since 7.2
|
||||
* @see https://www.php.net/manual/en/function.sodium-crypto-aead-xchacha20poly1305-ietf-decrypt.php
|
||||
*/
|
||||
function sodium_crypto_aead_xchacha20poly1305_ietf_decrypt(string $ciphertext, string $additional_data, string $nonce, string $key): string {}
|
||||
function sodium_crypto_aead_xchacha20poly1305_ietf_decrypt(string $ciphertext, string $additional_data, string $nonce, string $key): string|false {}
|
||||
|
||||
/**
|
||||
* @throws SodiumException
|
||||
|
@ -1161,7 +1141,7 @@ function sodium_crypto_secretstream_xchacha20poly1305_init_pull(string $header,
|
|||
* @since 7.2
|
||||
* @see https://www.php.net/manual/en/function.sodium-crypto-secretstream-xchacha20poly1305-pull.php
|
||||
*/
|
||||
function sodium_crypto_secretstream_xchacha20poly1305_pull(string &$state, string $ciphertext, string $additional_data = ''): array {}
|
||||
function sodium_crypto_secretstream_xchacha20poly1305_pull(string &$state, string $ciphertext, string $additional_data = ''): array|false {}
|
||||
|
||||
/**
|
||||
* @throws SodiumException
|
||||
|
@ -1183,7 +1163,7 @@ function sodium_bin2base64(string $string, int $id): string {}
|
|||
* @see https://www.php.net/manual/en/function.sodium-base642bin.php
|
||||
* @return string
|
||||
*/
|
||||
function sodium_base642bin(string $string, int $id, string $ignore = ''){}
|
||||
function sodium_base642bin(string $string, int $id, string $ignore = ''): string {}
|
||||
|
||||
class SodiumException extends Exception {
|
||||
|
||||
|
|
|
@ -7,7 +7,8 @@
|
|||
* @since 7.0
|
||||
* @throws Exception if it was not possible to gather sufficient entropy.
|
||||
*/
|
||||
function random_bytes (int $length) {}
|
||||
function random_bytes (int $length): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generates cryptographically secure pseudo-random integers
|
||||
|
@ -18,4 +19,5 @@ function random_bytes (int $length) {}
|
|||
* @since 7.0
|
||||
* @throws Exception if it was not possible to gather sufficient entropy.
|
||||
*/
|
||||
function random_int (int $min, int $max) {}
|
||||
function random_int (int $min, int $max): int
|
||||
{}
|
||||
|
|
|
@ -32,11 +32,13 @@ define("__COMPILER_HALT_OFFSET__",0);
|
|||
* @see unpack()
|
||||
* @since 5.4
|
||||
*/
|
||||
function hex2bin(string $string) {};
|
||||
function hex2bin(string $string): string|false
|
||||
{};
|
||||
|
||||
/**
|
||||
* Get or Set the HTTP response code
|
||||
* @param int $response_code [optional] The optional response_code will set the response code.
|
||||
* @return int The current response code. By default the return value is int(200).
|
||||
* @return int|bool The current response code. By default the return value is int(200).
|
||||
*/
|
||||
function http_response_code(int $response_code) {}
|
||||
function http_response_code(int $response_code): int|bool
|
||||
{}
|
||||
|
|
|
@ -16,7 +16,8 @@ namespace {
|
|||
* </p>
|
||||
* @return array an array of the parameters. The parameters can be given an index with the => operator.
|
||||
*/
|
||||
function PS_UNRESERVE_PREFIX_array(...$_){};
|
||||
function PS_UNRESERVE_PREFIX_array(...$_): array
|
||||
{};
|
||||
|
||||
/**
|
||||
* Assigns a list of variables in one operation.
|
||||
|
@ -25,7 +26,8 @@ namespace {
|
|||
* @param mixed ...$_ [optional] <p>Another variable ...</p>
|
||||
* @return array the assigned array.
|
||||
*/
|
||||
function PS_UNRESERVE_PREFIX_list(mixed $var1, ...$_){};
|
||||
function PS_UNRESERVE_PREFIX_list(mixed $var1, ...$_): array
|
||||
{};
|
||||
|
||||
/**
|
||||
* <p>Terminates execution of the script. Shutdown functions and object destructors will always be executed even if exit is called.</p>
|
||||
|
@ -90,7 +92,8 @@ namespace {
|
|||
* </ul>
|
||||
* </p>
|
||||
*/
|
||||
function PS_UNRESERVE_PREFIX_empty(mixed $var){};
|
||||
function PS_UNRESERVE_PREFIX_empty(mixed $var): bool
|
||||
{};
|
||||
|
||||
/**
|
||||
* <p>Determine if a variable is set and is not <b>NULL</b>.</p>
|
||||
|
@ -103,7 +106,8 @@ namespace {
|
|||
* @param mixed ...$_ [optional] <p>Another variable ...</p>
|
||||
* @return bool Returns <b>TRUE</b> if var exists and has value other than <b>NULL</b>, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
function PS_UNRESERVE_PREFIX_isset(mixed $var, ...$_){};
|
||||
function PS_UNRESERVE_PREFIX_isset(mixed $var, ...$_): bool
|
||||
{};
|
||||
|
||||
/**
|
||||
* <p>Destroys the specified variables.</p>
|
||||
|
@ -145,7 +149,8 @@ namespace {
|
|||
* case <b>eval()</b> returned <b>FALSE</b> and execution of the following code continued normally. It is not possible to catch a parse
|
||||
* error in <b>eval()</b> using set_error_handler().
|
||||
*/
|
||||
function PS_UNRESERVE_PREFIX_eval(string $code){};
|
||||
function PS_UNRESERVE_PREFIX_eval(string $code): mixed
|
||||
{};
|
||||
|
||||
/**
|
||||
* Generator objects are returned from generators, cannot be instantiated via new.
|
||||
|
@ -259,7 +264,8 @@ class object {
|
|||
* @return mixed
|
||||
* @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.methods
|
||||
*/
|
||||
public function __call(string $name, array $arguments) {}
|
||||
public function __call(string $name, array $arguments): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* is triggered when invoking inaccessible methods in a static context.
|
||||
|
@ -269,7 +275,8 @@ class object {
|
|||
* @return mixed
|
||||
* @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.methods
|
||||
*/
|
||||
public static function __callStatic(string $name, array $arguments) {}
|
||||
public static function __callStatic(string $name, array $arguments): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* is utilized for reading data from inaccessible members.
|
||||
|
@ -278,7 +285,8 @@ class object {
|
|||
* @return mixed
|
||||
* @link https://php.net/manual/en/language.oop5.overloading.php#language.oop5.overloading.members
|
||||
*/
|
||||
public function __get(string $name) {}
|
||||
public function __get(string $name): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* run when writing data to inaccessible members.
|
||||
|
@ -345,7 +353,8 @@ class object {
|
|||
* @return mixed
|
||||
* @link https://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.invoke
|
||||
*/
|
||||
public function __invoke() {}
|
||||
public function __invoke(): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* This method is called by var_dump() when dumping an object to get the properties that should be shown.
|
||||
|
|
|
@ -38,7 +38,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @link https://php.net/manual/en/function.dl.php
|
||||
*/
|
||||
#[Deprecated(since: '5.3')]
|
||||
function dl (string $extension_filename) {}
|
||||
function dl (string $extension_filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets the process title
|
||||
|
@ -49,7 +50,8 @@ function dl (string $extension_filename) {}
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @since 5.5
|
||||
*/
|
||||
function cli_set_process_title (string $title) {}
|
||||
function cli_set_process_title (string $title): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the current process title
|
||||
|
@ -58,7 +60,8 @@ function cli_set_process_title (string $title) {}
|
|||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function cli_get_process_title () {}
|
||||
function cli_get_process_title (): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Verify that the contents of a variable is accepted by the iterable pseudo-type, i.e. that it is an array or an object implementing Traversable
|
||||
|
@ -68,7 +71,8 @@ function cli_get_process_title () {}
|
|||
* @link https://php.net/manual/en/function.is-iterable.php
|
||||
*/
|
||||
#[Pure]
|
||||
function is_iterable(mixed $value) {}
|
||||
function is_iterable(mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Encodes an ISO-8859-1 string to UTF-8
|
||||
|
@ -79,7 +83,8 @@ function is_iterable(mixed $value) {}
|
|||
* @return string the UTF-8 translation of <i>data</i>.
|
||||
*/
|
||||
#[Pure]
|
||||
function utf8_encode (string $string) {}
|
||||
function utf8_encode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a string with ISO-8859-1 characters encoded with UTF-8
|
||||
|
@ -91,7 +96,8 @@ function utf8_encode (string $string) {}
|
|||
* @return string the ISO-8859-1 translation of <i>data</i>.
|
||||
*/
|
||||
#[Pure]
|
||||
function utf8_decode (string $string) {}
|
||||
function utf8_decode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Clear the most recent error
|
||||
|
@ -99,7 +105,7 @@ function utf8_decode (string $string) {}
|
|||
* @return void
|
||||
* @since 7.0
|
||||
*/
|
||||
function error_clear_last () {}
|
||||
function error_clear_last (): void {}
|
||||
|
||||
/**
|
||||
* Get process codepage
|
||||
|
@ -107,7 +113,8 @@ function error_clear_last () {}
|
|||
* @return int
|
||||
* @since 7.1
|
||||
*/
|
||||
function sapi_windows_cp_get(string $kind) {}
|
||||
function sapi_windows_cp_get(string $kind): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set process codepage
|
||||
|
@ -115,7 +122,8 @@ function sapi_windows_cp_get(string $kind) {}
|
|||
* @return bool
|
||||
* @since 7.1
|
||||
*/
|
||||
function sapi_windows_cp_set(int $cp) {}
|
||||
function sapi_windows_cp_set(int $cp): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert string from one codepage to another
|
||||
|
@ -125,14 +133,16 @@ function sapi_windows_cp_set(int $cp) {}
|
|||
* @return string
|
||||
* @since 7.1
|
||||
*/
|
||||
function sapi_windows_cp_conv(int|string $in_codepage, int|string $out_codepage, string $subject) {}
|
||||
function sapi_windows_cp_conv(int|string $in_codepage, int|string $out_codepage, string $subject): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Indicates whether the codepage is utf-8 compatible
|
||||
* @return bool
|
||||
* @since 7.1
|
||||
*/
|
||||
function sapi_windows_cp_is_utf8() {}
|
||||
function sapi_windows_cp_is_utf8(): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get or set VT100 support for the specified stream associated to an output buffer of a Windows console.
|
||||
|
@ -155,7 +165,8 @@ function sapi_windows_cp_is_utf8() {}
|
|||
* If <i>enable</i> is specified: Returns TRUE on success or FALSE on failure.
|
||||
* @since 7.2
|
||||
*/
|
||||
function sapi_windows_vt100_support ($stream, bool $enable) {}
|
||||
function sapi_windows_vt100_support ($stream, bool $enable): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set or remove a CTRL event handler.
|
||||
|
@ -166,7 +177,8 @@ function sapi_windows_vt100_support ($stream, bool $enable) {}
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @since 7.4
|
||||
*/
|
||||
function sapi_windows_set_ctrl_handler (callable $callable, bool $add = true) {}
|
||||
function sapi_windows_set_ctrl_handler (callable $callable, bool $add = true): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Send a CTRL event to another process.
|
||||
|
@ -177,7 +189,8 @@ function sapi_windows_set_ctrl_handler (callable $callable, bool $add = true) {}
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @since 7.4
|
||||
*/
|
||||
function sapi_windows_generate_ctrl_event (int $event, int $pid = 0) {}
|
||||
function sapi_windows_generate_ctrl_event (int $event, int $pid = 0): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* The full path and filename of the file. If used inside an include,
|
||||
|
|
|
@ -161,7 +161,8 @@ define('PASSWORD_ARGON2_PROVIDER', 'standard');
|
|||
* @since 5.5
|
||||
*/
|
||||
#[ArrayShape(["algo" => "int", "algoName" => "string", "options" => "array"])]
|
||||
function password_get_info (string $hash) {}
|
||||
function password_get_info (string $hash): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.5.0, PHP 5)<br/>
|
||||
|
@ -180,7 +181,9 @@ function password_get_info (string $hash) {}
|
|||
* @return string|false|null Returns the hashed password, or FALSE on failure, or null if the algorithm is invalid
|
||||
* @since 5.5
|
||||
*/
|
||||
function password_hash (string $password, string|int|null $algo, array $options = []) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false|null")]
|
||||
function password_hash (string $password, string|int|null $algo, array $options = [])
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if the given hash matches the given options.
|
||||
|
@ -191,7 +194,8 @@ function password_hash (string $password, string|int|null $algo, array $options
|
|||
* @return bool Returns TRUE if the hash should be rehashed to match the given algo and options, or FALSE otherwise.
|
||||
* @since 5.5
|
||||
*/
|
||||
function password_needs_rehash (string $hash, string|int|null $algo, array $options = []) {}
|
||||
function password_needs_rehash (string $hash, string|int|null $algo, array $options = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if the given hash matches the given options.
|
||||
|
@ -201,12 +205,14 @@ function password_needs_rehash (string $hash, string|int|null $algo, array $opti
|
|||
* @return bool Returns TRUE if the password and hash match, or FALSE otherwise.
|
||||
* @since 5.5
|
||||
*/
|
||||
function password_verify (string $password, string $hash) {}
|
||||
function password_verify (string $password, string $hash): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return a complete list of all registered password hashing algorithms.
|
||||
* @return string[]
|
||||
* @since 7.4
|
||||
*/
|
||||
function password_algos(){}
|
||||
function password_algos(): array
|
||||
{}
|
||||
// End of password v.
|
||||
|
|
|
@ -132,7 +132,8 @@ class Directory {
|
|||
* defined.
|
||||
*/
|
||||
#[Pure]
|
||||
function constant (string $name) {}
|
||||
function constant (string $name): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert binary data into hexadecimal representation
|
||||
|
@ -143,7 +144,8 @@ function constant (string $name) {}
|
|||
* @return string the hexadecimal representation of the given string.
|
||||
*/
|
||||
#[Pure]
|
||||
function bin2hex (string $string) {}
|
||||
function bin2hex (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Delay execution
|
||||
|
@ -155,7 +157,9 @@ function bin2hex (string $string) {}
|
|||
* by a signal, sleep returns the number of seconds left
|
||||
* to sleep.
|
||||
*/
|
||||
function sleep (int $seconds) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function sleep (int $seconds)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Delay execution in microseconds
|
||||
|
@ -166,7 +170,7 @@ function sleep (int $seconds) {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function usleep (int $microseconds) {}
|
||||
function usleep (int $microseconds): void {}
|
||||
|
||||
/**
|
||||
* Delay for a number of seconds and nanoseconds
|
||||
|
@ -187,7 +191,8 @@ function usleep (int $microseconds) {}
|
|||
* nanoseconds - number of nanoseconds
|
||||
* remaining in the delay
|
||||
*/
|
||||
function time_nanosleep (int $seconds, int $nanoseconds) {}
|
||||
function time_nanosleep (int $seconds, int $nanoseconds): array|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Make the script sleep until the specified time
|
||||
|
@ -197,7 +202,8 @@ function time_nanosleep (int $seconds, int $nanoseconds) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function time_sleep_until (float $timestamp) {}
|
||||
function time_sleep_until (float $timestamp): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parse a time/date generated with <function>strftime</function>
|
||||
|
@ -262,14 +268,15 @@ function time_sleep_until (float $timestamp) {}
|
|||
* </table>
|
||||
*/
|
||||
#[Pure]
|
||||
function strptime (string $timestamp, string $format) {}
|
||||
function strptime (string $timestamp, string $format): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Flush the output buffer
|
||||
* @link https://php.net/manual/en/function.flush.php
|
||||
* @return void
|
||||
*/
|
||||
function flush () {}
|
||||
function flush (): void {}
|
||||
|
||||
/**
|
||||
* Wraps a string to a given number of characters
|
||||
|
@ -293,7 +300,8 @@ function flush () {}
|
|||
* @return string the given string wrapped at the specified column.
|
||||
*/
|
||||
#[Pure]
|
||||
function wordwrap (string $string, int $width = 75, string $break = "\n", bool $cut_long_words = false) {}
|
||||
function wordwrap (string $string, int $width = 75, string $break = "\n", bool $cut_long_words = false): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert special characters to HTML entities
|
||||
|
@ -412,7 +420,7 @@ function wordwrap (string $string, int $width = 75, string $break = "\n", bool $
|
|||
* @return string The converted string.
|
||||
*/
|
||||
#[Pure]
|
||||
function htmlspecialchars (string $string, int $flags = ENT_COMPAT | ENT_HTML401, string $encoding = 'UTF-8', bool $double_encode = true)
|
||||
function htmlspecialchars (string $string, int $flags = ENT_COMPAT | ENT_HTML401, string $encoding = 'UTF-8', bool $double_encode = true): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -460,7 +468,7 @@ function htmlspecialchars (string $string, int $flags = ENT_COMPAT | ENT_HTML401
|
|||
* @return string the encoded string.
|
||||
*/
|
||||
#[Pure]
|
||||
function htmlentities (string $string, int $flags, string $encoding, bool $double_encode = true)
|
||||
function htmlentities (string $string, int $flags, string $encoding, bool $double_encode = true): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -503,7 +511,7 @@ function htmlentities (string $string, int $flags, string $encoding, bool $doubl
|
|||
* @return string the decoded string.
|
||||
*/
|
||||
#[Pure]
|
||||
function html_entity_decode (string $string, int $flags, string $encoding)
|
||||
function html_entity_decode (string $string, int $flags, string $encoding): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -538,7 +546,7 @@ function html_entity_decode (string $string, int $flags, string $encoding)
|
|||
* @return string the decoded string.
|
||||
*/
|
||||
#[Pure]
|
||||
function htmlspecialchars_decode (string $string, int $flags)
|
||||
function htmlspecialchars_decode (string $string, int $flags): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -717,7 +725,8 @@ function htmlspecialchars_decode (string $string, int $flags)
|
|||
* @return array the translation table as an array.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_html_translation_table (int $table, int $flags, string $encoding = "UTF-8") {}
|
||||
function get_html_translation_table (int $table, int $flags, string $encoding = "UTF-8"): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculate the sha1 hash of a string
|
||||
|
@ -734,7 +743,8 @@ function get_html_translation_table (int $table, int $flags, string $encoding =
|
|||
* @return string the sha1 hash as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function sha1 (string $string, bool $binary = false) {}
|
||||
function sha1 (string $string, bool $binary = false): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculate the sha1 hash of a file
|
||||
|
@ -749,7 +759,8 @@ function sha1 (string $string, bool $binary = false) {}
|
|||
* @return string|false a string on success, false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function sha1_file (string $filename, bool $binary = false) {}
|
||||
function sha1_file (string $filename, bool $binary = false): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculate the md5 hash of a string
|
||||
|
@ -765,7 +776,8 @@ function sha1_file (string $filename, bool $binary = false) {}
|
|||
* @return string the hash as a 32-character hexadecimal number.
|
||||
*/
|
||||
#[Pure]
|
||||
function md5 (string $string, bool $binary = false) {}
|
||||
function md5 (string $string, bool $binary = false): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculates the md5 hash of a given file
|
||||
|
@ -780,7 +792,8 @@ function md5 (string $string, bool $binary = false) {}
|
|||
* @return string|false a string on success, false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function md5_file (string $filename, bool $binary = false) {}
|
||||
function md5_file (string $filename, bool $binary = false): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculates the crc32 polynomial of a string
|
||||
|
@ -791,7 +804,8 @@ function md5_file (string $filename, bool $binary = false) {}
|
|||
* @return int the crc32 checksum of str as an integer..1
|
||||
*/
|
||||
#[Pure]
|
||||
function crc32 (string $string) {}
|
||||
function crc32 (string $string): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parse a binary IPTC block into single tags.
|
||||
|
@ -804,7 +818,8 @@ function crc32 (string $string) {}
|
|||
* value. It returns false on error or if no IPTC data was found.
|
||||
*/
|
||||
#[Pure]
|
||||
function iptcparse (string $iptc_block) {}
|
||||
function iptcparse (string $iptc_block): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Embeds binary IPTC data into a JPEG image.
|
||||
|
@ -823,7 +838,7 @@ function iptcparse (string $iptc_block) {}
|
|||
* @return string|bool If success and spool flag is lower than 2 then the JPEG will not be
|
||||
* returned as a string, false on errors.
|
||||
*/
|
||||
function iptcembed (string $iptc_data, string $filename, int $spool)
|
||||
function iptcembed (string $iptc_data, string $filename, int $spool): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -887,7 +902,7 @@ function iptcembed (string $iptc_data, string $filename, int $spool)
|
|||
* <p>
|
||||
* On failure, false is returned.
|
||||
*/
|
||||
function getimagesize (string $filename, &$image_info)
|
||||
function getimagesize (string $filename, &$image_info): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -976,7 +991,8 @@ function getimagesize (string $filename, &$image_info)
|
|||
* </table>
|
||||
*/
|
||||
#[Pure]
|
||||
function image_type_to_mime_type (int $image_type) {}
|
||||
function image_type_to_mime_type (int $image_type): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get file extension for image type
|
||||
|
@ -988,10 +1004,11 @@ function image_type_to_mime_type (int $image_type) {}
|
|||
* Removed since 8.0.
|
||||
* Whether to prepend a dot to the extension or not. Default to true.
|
||||
* </p>
|
||||
* @return string A string with the extension corresponding to the given image type.
|
||||
* @return string|false A string with the extension corresponding to the given image type.
|
||||
*/
|
||||
#[Pure]
|
||||
function image_type_to_extension (int $image_type, $include_dot = true) {}
|
||||
function image_type_to_extension (int $image_type, $include_dot = true): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Outputs information about PHP's configuration
|
||||
|
@ -1077,7 +1094,8 @@ function image_type_to_extension (int $image_type, $include_dot = true) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function phpinfo (int $flags) {}
|
||||
function phpinfo (int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the current PHP version
|
||||
|
@ -1085,13 +1103,14 @@ function phpinfo (int $flags) {}
|
|||
* @param string $extension [optional] <p>
|
||||
* An optional extension name.
|
||||
* </p>
|
||||
* @return string If the optional extension parameter is
|
||||
* @return string|false If the optional extension parameter is
|
||||
* specified, phpversion returns the version of that
|
||||
* extension, or false if there is no version information associated or
|
||||
* the extension isn't enabled.
|
||||
*/
|
||||
#[Pure]
|
||||
function phpversion (string $extension) {}
|
||||
function phpversion (string $extension): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Prints out the credits for PHP
|
||||
|
@ -1156,7 +1175,8 @@ function phpversion (string $extension) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function phpcredits (int $flags) {}
|
||||
function phpcredits (int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the logo guid
|
||||
|
@ -1165,7 +1185,8 @@ function phpcredits (int $flags) {}
|
|||
* @return string PHPE9568F34-D428-11d2-A769-00AA001ACF42.
|
||||
*/
|
||||
#[Pure]
|
||||
function php_logo_guid () {}
|
||||
function php_logo_guid (): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* @removed 5.5
|
||||
|
@ -1183,12 +1204,13 @@ function php_egg_logo_guid () {}
|
|||
* @link https://php.net/manual/en/function.zend-logo-guid.php
|
||||
* @return string PHPE9568F35-D428-11d2-A769-00AA001ACF42.
|
||||
*/
|
||||
function zend_logo_guid () {}
|
||||
function zend_logo_guid (): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the type of interface between web server and PHP
|
||||
* @link https://php.net/manual/en/function.php-sapi-name.php
|
||||
* @return string the interface type, as a lowercase string.
|
||||
* @return string|false the interface type, as a lowercase string.
|
||||
* </p>
|
||||
* <p>
|
||||
* Although not exhaustive, the possible return values include
|
||||
|
@ -1203,7 +1225,8 @@ function zend_logo_guid () {}
|
|||
* thttpd, tux, and webjames.
|
||||
*/
|
||||
#[Pure]
|
||||
function php_sapi_name () {}
|
||||
function php_sapi_name (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns information about the operating system PHP is running on
|
||||
|
@ -1216,7 +1239,8 @@ function php_sapi_name () {}
|
|||
* @return string the description, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function php_uname (string $mode) {}
|
||||
function php_uname (string $mode): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return a list of .ini files parsed from the additional ini dir
|
||||
|
@ -1230,7 +1254,8 @@ function php_uname (string $mode) {}
|
|||
* php_ini_scanned_files.
|
||||
*/
|
||||
#[Pure]
|
||||
function php_ini_scanned_files () {}
|
||||
function php_ini_scanned_files (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve a path to the loaded php.ini file
|
||||
|
@ -1239,7 +1264,8 @@ function php_ini_scanned_files () {}
|
|||
* @since 5.2.4
|
||||
*/
|
||||
#[Pure]
|
||||
function php_ini_loaded_file () {}
|
||||
function php_ini_loaded_file (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* String comparisons using a "natural order" algorithm
|
||||
|
@ -1256,7 +1282,8 @@ function php_ini_loaded_file () {}
|
|||
* str2, and 0 if they are equal.
|
||||
*/
|
||||
#[Pure]
|
||||
function strnatcmp (string $string1, string $string2) {}
|
||||
function strnatcmp (string $string1, string $string2): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Case insensitive string comparisons using a "natural order" algorithm
|
||||
|
@ -1273,7 +1300,8 @@ function strnatcmp (string $string1, string $string2) {}
|
|||
* str2, and 0 if they are equal.
|
||||
*/
|
||||
#[Pure]
|
||||
function strnatcasecmp (string $string1, string $string2) {}
|
||||
function strnatcasecmp (string $string1, string $string2): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Count the number of substring occurrences
|
||||
|
@ -1295,7 +1323,7 @@ function strnatcasecmp (string $string1, string $string2) {}
|
|||
* @return int This functions returns an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function substr_count (string $haystack, string $needle, int $offset, int $length)
|
||||
function substr_count (string $haystack, string $needle, int $offset, int $length): int
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1349,7 +1377,7 @@ function substr_count (string $haystack, string $needle, int $offset, int $lengt
|
|||
* which consists entirely of characters in str2.
|
||||
*/
|
||||
#[Pure]
|
||||
function strspn (string $string, string $characters, int $offset, int $length)
|
||||
function strspn (string $string, string $characters, int $offset, int $length): int
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1370,7 +1398,7 @@ function strspn (string $string, string $characters, int $offset, int $length)
|
|||
* @return int the length of the segment as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function strcspn (string $string, string $characters, int $offset, int $length)
|
||||
function strcspn (string $string, string $characters, int $offset, int $length): int
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1387,7 +1415,7 @@ function strcspn (string $string, string $characters, int $offset, int $length)
|
|||
* @param string $token <p>
|
||||
* The delimiter used when splitting up str.
|
||||
* </p>
|
||||
* @return string A string token.
|
||||
* @return string|false A string token.
|
||||
*/
|
||||
function strtok (string $string, string $token)
|
||||
function strtok (string $string, string $token): string|false
|
||||
{}
|
||||
|
|
|
@ -14,7 +14,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @return string the uppercased string.
|
||||
*/
|
||||
#[Pure]
|
||||
function strtoupper (string $string) {}
|
||||
function strtoupper (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Make a string lowercase
|
||||
|
@ -25,7 +26,8 @@ function strtoupper (string $string) {}
|
|||
* @return string the lowercased string.
|
||||
*/
|
||||
#[Pure]
|
||||
function strtolower (string $string) {}
|
||||
function strtolower (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find the position of the first occurrence of a substring in a string
|
||||
|
@ -52,7 +54,8 @@ function strtolower (string $string) {}
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function strpos (string $haystack, string $needle, int $offset = 0) {}
|
||||
function strpos (string $haystack, string $needle, int $offset = 0): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find position of first occurrence of a case-insensitive string
|
||||
|
@ -78,7 +81,7 @@ function strpos (string $haystack, string $needle, int $offset = 0) {}
|
|||
* stripos will return boolean false.
|
||||
*/
|
||||
#[Pure]
|
||||
function stripos (string $haystack, string $needle, int $offset)
|
||||
function stripos (string $haystack, string $needle, int $offset): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -104,7 +107,8 @@ function stripos (string $haystack, string $needle, int $offset)
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function strrpos (string $haystack, string $needle, int $offset = 0) {}
|
||||
function strrpos (string $haystack, string $needle, int $offset = 0): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find position of last occurrence of a case-insensitive string in a string
|
||||
|
@ -133,7 +137,7 @@ function strrpos (string $haystack, string $needle, int $offset = 0) {}
|
|||
* If needle is not found, false is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function strripos (string $haystack, string $needle, int $offset)
|
||||
function strripos (string $haystack, string $needle, int $offset): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -145,7 +149,8 @@ function strripos (string $haystack, string $needle, int $offset)
|
|||
* @return string the reversed string.
|
||||
*/
|
||||
#[Pure]
|
||||
function strrev (string $string) {}
|
||||
function strrev (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert logical Hebrew text to visual text
|
||||
|
@ -160,7 +165,7 @@ function strrev (string $string) {}
|
|||
* @return string the visual string.
|
||||
*/
|
||||
#[Pure]
|
||||
function hebrev (string $string, int $max_chars_per_line)
|
||||
function hebrev (string $string, int $max_chars_per_line): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -177,7 +182,7 @@ function hebrev (string $string, int $max_chars_per_line)
|
|||
* @removed 8.0
|
||||
*/
|
||||
#[Deprecated(replacement: 'nl2br(hebrev(%parameter0%))', since: '7.4')]
|
||||
function hebrevc (string $hebrew_text, $max_chars_per_line)
|
||||
function hebrevc (string $hebrew_text, $max_chars_per_line): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -192,7 +197,8 @@ function hebrevc (string $hebrew_text, $max_chars_per_line)
|
|||
* @return string the altered string.
|
||||
*/
|
||||
#[Pure]
|
||||
function nl2br (string $string, bool $use_xhtml = true) {}
|
||||
function nl2br (string $string, bool $use_xhtml = true): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns trailing name component of path
|
||||
|
@ -212,7 +218,7 @@ function nl2br (string $string, bool $use_xhtml = true) {}
|
|||
* @return string the base name of the given path.
|
||||
*/
|
||||
#[Pure]
|
||||
function basename (string $path, string $suffix)
|
||||
function basename (string $path, string $suffix): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -237,7 +243,8 @@ function basename (string $path, string $suffix)
|
|||
* /component removed.
|
||||
*/
|
||||
#[Pure]
|
||||
function dirname (string $path, int $levels = 1) {}
|
||||
function dirname (string $path, int $levels = 1): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns information about a file path
|
||||
|
@ -263,7 +270,7 @@ function dirname (string $path, int $levels = 1) {}
|
|||
* string if not all elements are requested.
|
||||
*/
|
||||
#[Pure]
|
||||
function pathinfo (string $path, int $flags)
|
||||
function pathinfo (string $path, int $flags): array|string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -278,7 +285,8 @@ function pathinfo (string $path, int $flags)
|
|||
* backslash (\).
|
||||
*/
|
||||
#[Pure]
|
||||
function stripslashes (string $string) {}
|
||||
function stripslashes (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Un-quote string quoted with <function>addcslashes</function>
|
||||
|
@ -289,7 +297,8 @@ function stripslashes (string $string) {}
|
|||
* @return string the unescaped string.
|
||||
*/
|
||||
#[Pure]
|
||||
function stripcslashes (string $string) {}
|
||||
function stripcslashes (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find the first occurrence of a string
|
||||
|
@ -310,7 +319,7 @@ function stripcslashes (string $string) {}
|
|||
* is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function strstr (string $haystack, string $needle, bool $before_needle)
|
||||
function strstr (string $haystack, string $needle, bool $before_needle): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -332,7 +341,7 @@ function strstr (string $haystack, string $needle, bool $before_needle)
|
|||
* found, returns false.
|
||||
*/
|
||||
#[Pure]
|
||||
function stristr (string $haystack, string $needle, bool $before_needle)
|
||||
function stristr (string $haystack, string $needle, bool $before_needle): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -355,7 +364,8 @@ function stristr (string $haystack, string $needle, bool $before_needle)
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function strrchr (string $haystack, string $needle) {}
|
||||
function strrchr (string $haystack, string $needle): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Randomly shuffles a string
|
||||
|
@ -366,7 +376,8 @@ function strrchr (string $haystack, string $needle) {}
|
|||
* @return string the shuffled string.
|
||||
*/
|
||||
#[Pure]
|
||||
function str_shuffle (string $string) {}
|
||||
function str_shuffle (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return information about words used in a string
|
||||
|
@ -386,7 +397,7 @@ function str_shuffle (string $string) {}
|
|||
* format chosen.
|
||||
*/
|
||||
#[Pure]
|
||||
function str_word_count (string $string, int $format, string $characters)
|
||||
function str_word_count (string $string, int $format, string $characters): array|int
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -411,7 +422,9 @@ function str_word_count (string $string, int $format, string $characters)
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function str_split (string $string, int $length = 1) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")]
|
||||
function str_split (string $string, int $length = 1): array|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Search a string for any of a set of characters
|
||||
|
@ -426,7 +439,8 @@ function str_split (string $string, int $length = 1) {}
|
|||
* not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function strpbrk (string $string, string $characters) {}
|
||||
function strpbrk (string $string, string $characters): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Binary safe comparison of two strings from an offset, up to length characters
|
||||
|
@ -448,7 +462,7 @@ function strpbrk (string $string, string $characters) {}
|
|||
* If case_insensitivity is true, comparison is
|
||||
* case insensitive.
|
||||
* </p>
|
||||
* @return int < 0 if main_str from position
|
||||
* @return int if less than 0 if main_str from position
|
||||
* offset is less than str, >
|
||||
* 0 if it is greater than str, and 0 if they are equal.
|
||||
* If offset is equal to or greater than the length of
|
||||
|
@ -457,7 +471,7 @@ function strpbrk (string $string, string $characters) {}
|
|||
* false.
|
||||
*/
|
||||
#[Pure]
|
||||
function substr_compare (string $haystack, string $needle, int $offset, int $length, bool $case_insensitive)
|
||||
function substr_compare (string $haystack, string $needle, int $offset, int $length, bool $case_insensitive): int
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -469,13 +483,14 @@ function substr_compare (string $haystack, string $needle, int $offset, int $len
|
|||
* @param string $string2 <p>
|
||||
* The second string.
|
||||
* </p>
|
||||
* @return int < 0 if str1 is less than
|
||||
* @return int if less than 0 if str1 is less than
|
||||
* str2; > 0 if
|
||||
* str1 is greater than
|
||||
* str2, and 0 if they are equal.
|
||||
*/
|
||||
#[Pure]
|
||||
function strcoll (string $string1, string $string2) {}
|
||||
function strcoll (string $string1, string $string2): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Formats a number as a currency string
|
||||
|
@ -494,7 +509,8 @@ function strcoll (string $string1, string $string2) {}
|
|||
* @see NumberFormatter
|
||||
*/
|
||||
#[Deprecated(reason: 'Use the NumberFormatter functionality', since: '7.4')]
|
||||
function money_format (string $format, float $number) {}
|
||||
function money_format (string $format, float $number): ?string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return part of a string
|
||||
|
@ -560,7 +576,8 @@ function money_format (string $format, float $number) {}
|
|||
* @return string|false the extracted part of string or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function substr (string $string, int $offset, int $length)
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function substr (string $string, int $offset, int $length): bool|string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -599,7 +616,7 @@ function substr (string $string, int $offset, int $length)
|
|||
* array then array is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function substr_replace (array|string $string, array|string $replace, array|int $offset, array|int $length = null)
|
||||
function substr_replace (array|string $string, array|string $replace, array|int $offset, array|int $length = null): array|string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -611,7 +628,8 @@ function substr_replace (array|string $string, array|string $replace, array|int
|
|||
* @return string the string with meta characters quoted.
|
||||
*/
|
||||
#[Pure]
|
||||
function quotemeta (string $string) {}
|
||||
function quotemeta (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Make a string's first character uppercase
|
||||
|
@ -622,7 +640,8 @@ function quotemeta (string $string) {}
|
|||
* @return string the resulting string.
|
||||
*/
|
||||
#[Pure]
|
||||
function ucfirst (string $string) {}
|
||||
function ucfirst (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Make a string's first character lowercase
|
||||
|
@ -633,7 +652,8 @@ function ucfirst (string $string) {}
|
|||
* @return string the resulting string.
|
||||
*/
|
||||
#[Pure]
|
||||
function lcfirst (string $string) {}
|
||||
function lcfirst (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Uppercase the first character of each word in a string
|
||||
|
@ -645,7 +665,8 @@ function lcfirst (string $string) {}
|
|||
* @return string the modified string.
|
||||
*/
|
||||
#[Pure]
|
||||
function ucwords (string $string, string $separators = " \t\r\n\f\v") {}
|
||||
function ucwords (string $string, string $separators = " \t\r\n\f\v"): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Translate characters or replace substrings
|
||||
|
@ -665,7 +686,8 @@ function ucwords (string $string, string $separators = " \t\r\n\f\v") {}
|
|||
* to.
|
||||
*/
|
||||
#[Pure]
|
||||
function strtr (string $string, string $from, string $to) {}
|
||||
function strtr (string $string, string $from, string $to): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Translate certain characters
|
||||
|
@ -675,7 +697,8 @@ function strtr (string $string, string $from, string $to) {}
|
|||
* @return string A copy of str, translating all occurrences of each character in from to the corresponding character in to.
|
||||
*/
|
||||
#[Pure]
|
||||
function strtr (string $str, array $replace_pairs) {}
|
||||
function strtr (string $str, array $replace_pairs): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Quote string with slashes
|
||||
|
@ -686,7 +709,8 @@ function strtr (string $str, array $replace_pairs) {}
|
|||
* @return string the escaped string.
|
||||
*/
|
||||
#[Pure]
|
||||
function addslashes (string $string) {}
|
||||
function addslashes (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Quote string with slashes in a C style
|
||||
|
@ -739,7 +763,8 @@ function addslashes (string $string) {}
|
|||
* @return string the escaped string.
|
||||
*/
|
||||
#[Pure]
|
||||
function addcslashes (string $string, string $characters) {}
|
||||
function addcslashes (string $string, string $characters): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Strip whitespace (or other characters) from the end of a string.
|
||||
|
@ -765,7 +790,8 @@ function addcslashes (string $string, string $characters) {}
|
|||
* @return string the modified string.
|
||||
*/
|
||||
#[Pure]
|
||||
function rtrim (string $string, string $characters = " \t\n\r\0\x0B") {}
|
||||
function rtrim (string $string, string $characters = " \t\n\r\0\x0B"): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Replace all occurrences of the search string with the replacement string
|
||||
|
@ -791,7 +817,8 @@ function rtrim (string $string, string $characters = " \t\n\r\0\x0B") {}
|
|||
* @param int &$count [optional] If passed, this will hold the number of matched and replaced needles.
|
||||
* @return string|string[] This function returns a string or an array with the replaced values.
|
||||
*/
|
||||
function str_replace (array|string $search, array|string $replace, array|string $subject, &$count) {}
|
||||
function str_replace (array|string $search, array|string $replace, array|string $subject, &$count): array|string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Case-insensitive version of <function>str_replace</function>.
|
||||
|
@ -815,7 +842,7 @@ function str_replace (array|string $search, array|string $replace, array|string
|
|||
* </p>
|
||||
* @return string|string[] a string or an array of replacements.
|
||||
*/
|
||||
function str_ireplace (array|string $search, array|string $replace, array|string $subject, &$count)
|
||||
function str_ireplace (array|string $search, array|string $replace, array|string $subject, &$count): array|string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -836,7 +863,8 @@ function str_ireplace (array|string $search, array|string $replace, array|string
|
|||
* @return string the repeated string.
|
||||
*/
|
||||
#[Pure]
|
||||
function str_repeat (string $string, int $times) {}
|
||||
function str_repeat (string $string, int $times): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return information about characters used in a string
|
||||
|
@ -859,7 +887,7 @@ function str_repeat (string $string, int $times) {}
|
|||
* 4 - a string containing all not used characters is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function count_chars (string $string, int $mode)
|
||||
function count_chars (string $string, int $mode): array|string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -877,7 +905,8 @@ function count_chars (string $string, int $mode)
|
|||
* @return string the chunked string.
|
||||
*/
|
||||
#[Pure]
|
||||
function chunk_split (string $string, int $length = 76, string $separator = "\r\n") {}
|
||||
function chunk_split (string $string, int $length = 76, string $separator = "\r\n"): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Strip whitespace (or other characters) from the beginning and end of a string
|
||||
|
@ -894,7 +923,8 @@ function chunk_split (string $string, int $length = 76, string $separator = "\r\
|
|||
* @return string The trimmed string.
|
||||
*/
|
||||
#[Pure]
|
||||
function trim (string $string, string $characters = " \t\n\r\0\x0B") {}
|
||||
function trim (string $string, string $characters = " \t\n\r\0\x0B"): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Strip whitespace (or other characters) from the beginning of a string
|
||||
|
@ -926,7 +956,8 @@ function trim (string $string, string $characters = " \t\n\r\0\x0B") {}
|
|||
* (0x0B)), a vertical tab.
|
||||
*/
|
||||
#[Pure]
|
||||
function ltrim (string $string, string $characters = " \t\n\r\0\x0B") {}
|
||||
function ltrim (string $string, string $characters = " \t\n\r\0\x0B"): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Strip HTML and PHP tags from a string
|
||||
|
@ -946,7 +977,7 @@ function ltrim (string $string, string $characters = " \t\n\r\0\x0B") {}
|
|||
* @return string the stripped string.
|
||||
*/
|
||||
#[Pure]
|
||||
function strip_tags (string $string, array|string $allowed_tags = null)
|
||||
function strip_tags (string $string, array|string $allowed_tags = null): string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -965,7 +996,7 @@ function strip_tags (string $string, array|string $allowed_tags = null)
|
|||
* </p>
|
||||
* @return int the number of matching chars in both strings.
|
||||
*/
|
||||
function similar_text (string $string1, string $string2, &$percent)
|
||||
function similar_text (string $string1, string $string2, &$percent): int
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -998,7 +1029,8 @@ function similar_text (string $string1, string $string2, &$percent)
|
|||
* string will be returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function explode (string $separator, string $string, int $limit)
|
||||
#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")]
|
||||
function explode (string $separator, string $string, int $limit): array|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1016,7 +1048,8 @@ function explode (string $separator, string $string, int $limit)
|
|||
* elements in the same order, with the glue string between each element.
|
||||
*/
|
||||
#[Pure]
|
||||
function implode (array|string $separator = "", array $array) {}
|
||||
function implode (array|string $separator = "", array $array): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>implode</function>
|
||||
|
@ -1033,7 +1066,8 @@ function implode (array|string $separator = "", array $array) {}
|
|||
* elements in the same order, with the glue string between each element.
|
||||
*/
|
||||
#[Pure]
|
||||
function join (array|string $separator = "", array $array) {}
|
||||
function join (array|string $separator = "", array $array): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set locale information
|
||||
|
@ -1105,7 +1139,8 @@ function join (array|string $separator = "", array $array) {}
|
|||
* on the system that PHP is running. It returns exactly
|
||||
* what the system setlocale function returns.
|
||||
*/
|
||||
function setlocale (int $category, array|string $locales, ...$rest) {}
|
||||
function setlocale (int $category, array|string $locales, ...$rest): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get numeric formatting information
|
||||
|
@ -1227,4 +1262,5 @@ function setlocale (int $category, array|string $locales, ...$rest) {}
|
|||
*/
|
||||
#[ArrayShape(["decimal_point" => "string", "thousands_sep" => "string", "grouping" => "array", "int_curr_symbol" => "string", "currency_symbol" => "string", "mon_decimal_point" => "string", "mon_thousands_sep" => "string", "mon_grouping" => "string", "positive_sign" => "string", "negative_sign" => "string", "int_frac_digits" => "string", "frac_digits" => "string", "p_cs_precedes" => "bool", "p_sep_by_space" => "bool", "n_cs_precedes" => "bool", "n_sep_by_space" => "bool", "p_sign_posn" => "int", "n_sign_posn" => "int",])]
|
||||
#[Pure]
|
||||
function localeconv () {}
|
||||
function localeconv (): array
|
||||
{}
|
||||
|
|
|
@ -147,7 +147,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* is not valid.
|
||||
*/
|
||||
#[Pure]
|
||||
function nl_langinfo (int $item) {}
|
||||
function nl_langinfo (int $item): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculate the soundex key of a string
|
||||
|
@ -158,7 +159,8 @@ function nl_langinfo (int $item) {}
|
|||
* @return string the soundex key as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function soundex (string $string) {}
|
||||
function soundex (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculate Levenshtein distance between two strings
|
||||
|
@ -188,7 +190,8 @@ function soundex (string $string) {}
|
|||
* two argument strings or -1, if one of the argument strings
|
||||
* is longer than the limit of 255 characters.
|
||||
*/
|
||||
function levenshtein (string $string1, string $string2, int $insertion_cost, int $repetition_cost, int $deletion_cost) {
|
||||
function levenshtein (string $string1, string $string2, int $insertion_cost, int $repetition_cost, int $deletion_cost): int
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -200,7 +203,8 @@ function levenshtein (string $string1, string $string2, int $insertion_cost, int
|
|||
* @return string the specified character.
|
||||
*/
|
||||
#[Pure]
|
||||
function chr (int $codepoint) {}
|
||||
function chr (int $codepoint): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert the first byte of a string to a value between 0 and 255
|
||||
|
@ -211,7 +215,8 @@ function chr (int $codepoint) {}
|
|||
* @return int the ASCII value as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function ord (string $character) {}
|
||||
function ord (string $character): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parses the string into variables
|
||||
|
@ -226,7 +231,7 @@ function ord (string $character) {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function parse_str (string $string, &$result)
|
||||
function parse_str (string $string, &$result): void
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -248,7 +253,8 @@ function parse_str (string $string, &$result)
|
|||
* @return array an indexed array containing the fields read.
|
||||
*/
|
||||
#[Pure]
|
||||
function str_getcsv (string $string, string $separator = ",", string $enclosure = '"', string $escape = "\\") {}
|
||||
function str_getcsv (string $string, string $separator = ",", string $enclosure = '"', string $escape = "\\"): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Pad a string to a certain length with another string
|
||||
|
@ -276,7 +282,8 @@ function str_getcsv (string $string, string $separator = ",", string $enclosure
|
|||
* @return string the padded string.
|
||||
*/
|
||||
#[Pure]
|
||||
function str_pad (string $string, int $length, string $pad_string = " ", int $pad_type = STR_PAD_RIGHT) {}
|
||||
function str_pad (string $string, int $length, string $pad_string = " ", int $pad_type = STR_PAD_RIGHT): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>rtrim</function>
|
||||
|
@ -287,7 +294,8 @@ function str_pad (string $string, int $length, string $pad_string = " ", int $pa
|
|||
* @see rtrim()
|
||||
*/
|
||||
#[Pure]
|
||||
function chop (string $string, string $characters) {}
|
||||
function chop (string $string, string $characters): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>strstr</function>
|
||||
|
@ -302,7 +310,8 @@ function chop (string $string, string $characters) {}
|
|||
* @return string|false Returns the portion of string, or FALSE if needle is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function strchr (string $haystack, string $needle, bool $before_needle = false) {}
|
||||
function strchr (string $haystack, string $needle, bool $before_needle = false): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return a formatted string
|
||||
|
@ -329,7 +338,8 @@ function strchr (string $haystack, string $needle, bool $before_needle = false)
|
|||
* format.
|
||||
*/
|
||||
#[Pure]
|
||||
function sprintf (string $format, ...$values) {}
|
||||
function sprintf (string $format, ...$values): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Output a formatted string
|
||||
|
@ -342,7 +352,8 @@ function sprintf (string $format, ...$values) {}
|
|||
* </p>
|
||||
* @return int the length of the outputted string.
|
||||
*/
|
||||
function printf (string $format, ...$values) {}
|
||||
function printf (string $format, ...$values): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Output a formatted string
|
||||
|
@ -355,7 +366,8 @@ function printf (string $format, ...$values) {}
|
|||
* </p>
|
||||
* @return int the length of the outputted string.
|
||||
*/
|
||||
function vprintf (string $format, array $values) {}
|
||||
function vprintf (string $format, array $values): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return a formatted string
|
||||
|
@ -371,7 +383,8 @@ function vprintf (string $format, array $values) {}
|
|||
* for sprintf).
|
||||
*/
|
||||
#[Pure]
|
||||
function vsprintf (string $format, array $values) {}
|
||||
function vsprintf (string $format, array $values): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Write a formatted string to a stream
|
||||
|
@ -385,7 +398,8 @@ function vsprintf (string $format, array $values) {}
|
|||
* </p>
|
||||
* @return int the length of the string written.
|
||||
*/
|
||||
function fprintf ($stream, string $format, ...$values) {}
|
||||
function fprintf ($stream, string $format, ...$values): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Write a formatted string to a stream
|
||||
|
@ -400,7 +414,8 @@ function fprintf ($stream, string $format, ...$values) {}
|
|||
* </p>
|
||||
* @return int the length of the outputted string.
|
||||
*/
|
||||
function vfprintf ($stream, string $format, array $values) {}
|
||||
function vfprintf ($stream, string $format, array $values): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parses input from a string according to a format
|
||||
|
@ -420,13 +435,14 @@ function vfprintf ($stream, string $format, array $values) {}
|
|||
* n stands for number of characters processed so far.
|
||||
* </p>
|
||||
* @param mixed &...$vars
|
||||
* @return array|int If only
|
||||
* @return array|int|null If only
|
||||
* two parameters were passed to this function, the values parsed
|
||||
* will be returned as an array. Otherwise, if optional parameters are passed,
|
||||
* the function will return the number of assigned values. The optional
|
||||
* parameters must be passed by reference.
|
||||
*/
|
||||
function sscanf (string $string, string $format, mixed &...$vars) {}
|
||||
function sscanf (string $string, string $format, mixed &...$vars): array|int|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parses input from a file according to a format
|
||||
|
@ -437,12 +453,13 @@ function sscanf (string $string, string $format, mixed &...$vars) {}
|
|||
* sprintf documentation.
|
||||
* </p>
|
||||
* @param mixed &...$vars [optional]
|
||||
* @return array|int If only two parameters were passed to this function, the values parsed will be
|
||||
* @return array|int|false|null If only two parameters were passed to this function, the values parsed will be
|
||||
* returned as an array. Otherwise, if optional parameters are passed, the
|
||||
* function will return the number of assigned values. The optional
|
||||
* parameters must be passed by reference.
|
||||
*/
|
||||
function fscanf ($stream, string $format, mixed &...$vars) {}
|
||||
function fscanf ($stream, string $format, mixed &...$vars): array|int|false|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parse a URL and return its components
|
||||
|
@ -486,7 +503,8 @@ function fscanf ($stream, string $format, mixed &...$vars) {}
|
|||
"fragment" => "string",
|
||||
])]
|
||||
#[Pure]
|
||||
function parse_url (string $url, int $component = -1) {}
|
||||
function parse_url (string $url, int $component = -1)
|
||||
{}
|
||||
|
||||
/**
|
||||
* URL-encodes string
|
||||
|
@ -505,7 +523,8 @@ function parse_url (string $url, int $component = -1) {}
|
|||
* are encoded as plus (+) signs.
|
||||
*/
|
||||
#[Pure]
|
||||
function urlencode (string $string) {}
|
||||
function urlencode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Decodes URL-encoded string
|
||||
|
@ -516,7 +535,8 @@ function urlencode (string $string) {}
|
|||
* @return string the decoded string.
|
||||
*/
|
||||
#[Pure]
|
||||
function urldecode (string $string) {}
|
||||
function urldecode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* URL-encode according to RFC 3986
|
||||
|
@ -533,7 +553,8 @@ function urldecode (string $string) {}
|
|||
* media with character conversions (like some email systems).
|
||||
*/
|
||||
#[Pure]
|
||||
function rawurlencode (string $string) {}
|
||||
function rawurlencode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Decode URL-encoded strings
|
||||
|
@ -544,7 +565,8 @@ function rawurlencode (string $string) {}
|
|||
* @return string the decoded URL, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function rawurldecode (string $string) {}
|
||||
function rawurldecode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generate URL-encoded query string
|
||||
|
@ -580,7 +602,8 @@ function rawurldecode (string $string) {}
|
|||
* @return string a URL-encoded string.
|
||||
*/
|
||||
#[Pure]
|
||||
function http_build_query (object|array $data, string $numeric_prefix = "", string $arg_separator = "&", int $encoding_type = PHP_QUERY_RFC1738){}
|
||||
function http_build_query (object|array $data, string $numeric_prefix = "", string $arg_separator = "&", int $encoding_type = PHP_QUERY_RFC1738): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the target of a symbolic link
|
||||
|
@ -590,7 +613,8 @@ function http_build_query (object|array $data, string $numeric_prefix = "", stri
|
|||
* </p>
|
||||
* @return string|false the contents of the symbolic link path or false on error.
|
||||
*/
|
||||
function readlink (string $path) {}
|
||||
function readlink (string $path): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets information about a link
|
||||
|
@ -598,12 +622,13 @@ function readlink (string $path) {}
|
|||
* @param string $path <p>
|
||||
* Path to the link.
|
||||
* </p>
|
||||
* @return int linkinfo returns the st_dev field
|
||||
* @return int|false linkinfo returns the st_dev field
|
||||
* of the Unix C stat structure returned by the lstat
|
||||
* system call. Returns 0 or false in case of error.
|
||||
*/
|
||||
#[Pure]
|
||||
function linkinfo (string $path) {}
|
||||
function linkinfo (string $path): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Creates a symbolic link
|
||||
|
@ -616,7 +641,8 @@ function linkinfo (string $path) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function symlink (string $target, string $link) {}
|
||||
function symlink (string $target, string $link): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Create a hard link
|
||||
|
@ -660,7 +686,7 @@ function unlink (string $filename, $context):bool {}
|
|||
* return status of the executed command will be written to this
|
||||
* variable.
|
||||
* </p>
|
||||
* @return string The last line from the result of the command. If you need to execute a
|
||||
* @return string|false The last line from the result of the command. If you need to execute a
|
||||
* command and have all the data from the command passed directly back without
|
||||
* any interference, use the passthru function.
|
||||
* </p>
|
||||
|
@ -668,7 +694,7 @@ function unlink (string $filename, $context):bool {}
|
|||
* To get the output of the executed command, be sure to set and use the
|
||||
* output parameter.
|
||||
*/
|
||||
function exec (string $command, &$output, &$result_code)
|
||||
function exec (string $command, &$output, &$result_code): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -685,7 +711,7 @@ function exec (string $command, &$output, &$result_code)
|
|||
* @return string|false the last line of the command output on success, and false
|
||||
* on failure.
|
||||
*/
|
||||
function system (string $command, &$result_code)
|
||||
function system (string $command, &$result_code): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -697,7 +723,8 @@ function system (string $command, &$result_code)
|
|||
* @return string The escaped string.
|
||||
*/
|
||||
#[Pure]
|
||||
function escapeshellcmd (string $command) {}
|
||||
function escapeshellcmd (string $command): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Escape a string to be used as a shell argument
|
||||
|
@ -708,7 +735,8 @@ function escapeshellcmd (string $command) {}
|
|||
* @return string The escaped string.
|
||||
*/
|
||||
#[Pure]
|
||||
function escapeshellarg (string $arg) {}
|
||||
function escapeshellarg (string $arg): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Execute an external program and display raw output
|
||||
|
@ -720,9 +748,9 @@ function escapeshellarg (string $arg) {}
|
|||
* If the return_var argument is present, the
|
||||
* return status of the Unix command will be placed here.
|
||||
* </p>
|
||||
* @return void
|
||||
* @return bool
|
||||
*/
|
||||
function passthru (string $command, &$result_code)
|
||||
function passthru (string $command, &$result_code): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -731,9 +759,10 @@ function passthru (string $command, &$result_code)
|
|||
* @param string $command <p>
|
||||
* The command that will be executed.
|
||||
* </p>
|
||||
* @return string|null The output from the executed command or NULL if an error occurred or the command produces no output.
|
||||
* @return string|false|null The output from the executed command or NULL if an error occurred or the command produces no output.
|
||||
*/
|
||||
function shell_exec (string $command) {}
|
||||
function shell_exec (string $command): string|false|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Execute a command and open file pointers for input/output
|
||||
|
@ -817,7 +846,8 @@ function proc_open (array|string $command, array $descriptor_spec, &$pipes, stri
|
|||
* </p>
|
||||
* @return int the termination status of the process that was run.
|
||||
*/
|
||||
function proc_close ($process) {}
|
||||
function proc_close ($process): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Kills a process opened by proc_open
|
||||
|
@ -834,7 +864,8 @@ function proc_close ($process) {}
|
|||
* </p>
|
||||
* @return bool the termination status of the process that was run.
|
||||
*/
|
||||
function proc_terminate ($process, int $signal = 15) {}
|
||||
function proc_terminate ($process, int $signal = 15): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get information about a process opened by {@see proc_open}
|
||||
|
@ -921,7 +952,9 @@ function proc_terminate ($process, int $signal = 15) {}
|
|||
"termsig" => "int",
|
||||
"stopsig" => "int",
|
||||
])]
|
||||
function proc_get_status ($process) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "array"], default: "array|false")]
|
||||
function proc_get_status ($process)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Change the priority of the current process. <br/>
|
||||
|
@ -934,7 +967,8 @@ function proc_get_status ($process) {}
|
|||
* If an error occurs, like the user lacks permission to change the priority,
|
||||
* an error of level E_WARNING is also generated.
|
||||
*/
|
||||
function proc_nice (int $priority) {}
|
||||
function proc_nice (int $priority): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generate a random integer
|
||||
|
@ -944,7 +978,8 @@ function proc_nice (int $priority) {}
|
|||
* @return int A pseudo random value between min
|
||||
* (or 0) and max (or getrandmax, inclusive).
|
||||
*/
|
||||
function rand (int $min = 0, int $max) {}
|
||||
function rand (int $min = 0, int $max): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Seed the random number generator
|
||||
|
@ -960,7 +995,7 @@ function rand (int $min = 0, int $max) {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function srand (int $seed, int $mode = MT_RAND_MT19937) {}
|
||||
function srand (int $seed, int $mode = MT_RAND_MT19937): void {}
|
||||
|
||||
/**
|
||||
* Show largest possible random value
|
||||
|
@ -968,7 +1003,8 @@ function srand (int $seed, int $mode = MT_RAND_MT19937) {}
|
|||
* @return int The largest possible random value returned by rand
|
||||
*/
|
||||
#[Pure]
|
||||
function getrandmax () {}
|
||||
function getrandmax (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generate a random value via the Mersenne Twister Random Number Generator
|
||||
|
@ -982,7 +1018,8 @@ function getrandmax () {}
|
|||
* @return int A random integer value between min (or 0)
|
||||
* and max (or mt_getrandmax, inclusive)
|
||||
*/
|
||||
function mt_rand (int $min = 0, int $max) {}
|
||||
function mt_rand (int $min = 0, int $max): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Seeds the Mersenne Twister Random Number Generator
|
||||
|
@ -995,7 +1032,7 @@ function mt_rand (int $min = 0, int $max) {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function mt_srand (int $seed, int $mode = MT_RAND_MT19937) {}
|
||||
function mt_srand (int $seed, int $mode = MT_RAND_MT19937): void {}
|
||||
|
||||
/**
|
||||
* Show largest possible random value
|
||||
|
@ -1003,7 +1040,8 @@ function mt_srand (int $seed, int $mode = MT_RAND_MT19937) {}
|
|||
* @return int the maximum random value returned by mt_rand
|
||||
*/
|
||||
#[Pure]
|
||||
function mt_getrandmax () {}
|
||||
function mt_getrandmax (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get port number associated with an Internet service and protocol
|
||||
|
@ -1019,7 +1057,8 @@ function mt_getrandmax () {}
|
|||
* protocol is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function getservbyname (string $service, string $protocol) {}
|
||||
function getservbyname (string $service, string $protocol): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get Internet service which corresponds to port and protocol
|
||||
|
@ -1031,10 +1070,11 @@ function getservbyname (string $service, string $protocol) {}
|
|||
* protocol is either "tcp"
|
||||
* or "udp" (in lowercase).
|
||||
* </p>
|
||||
* @return string the Internet service name as a string.
|
||||
* @return string|false the Internet service name as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function getservbyport (int $port, string $protocol) {}
|
||||
function getservbyport (int $port, string $protocol): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get protocol number associated with protocol name
|
||||
|
@ -1042,10 +1082,11 @@ function getservbyport (int $port, string $protocol) {}
|
|||
* @param string $protocol <p>
|
||||
* The protocol name.
|
||||
* </p>
|
||||
* @return int the protocol number or -1 if the protocol is not found.
|
||||
* @return int|false the protocol number or -1 if the protocol is not found.
|
||||
*/
|
||||
#[Pure]
|
||||
function getprotobyname (string $protocol) {}
|
||||
function getprotobyname (string $protocol): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get protocol name associated with protocol number
|
||||
|
@ -1053,10 +1094,11 @@ function getprotobyname (string $protocol) {}
|
|||
* @param int $protocol <p>
|
||||
* The protocol number.
|
||||
* </p>
|
||||
* @return string the protocol name as a string.
|
||||
* @return string|false the protocol name as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function getprotobynumber (int $protocol) {}
|
||||
function getprotobynumber (int $protocol): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets PHP script owner's UID
|
||||
|
@ -1064,7 +1106,8 @@ function getprotobynumber (int $protocol) {}
|
|||
* @return int|false the user ID of the current script, or false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function getmyuid () {}
|
||||
function getmyuid (): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get PHP script owner's GID
|
||||
|
@ -1072,7 +1115,8 @@ function getmyuid () {}
|
|||
* @return int|false the group ID of the current script, or false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function getmygid () {}
|
||||
function getmygid (): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets PHP's process ID
|
||||
|
@ -1080,7 +1124,8 @@ function getmygid () {}
|
|||
* @return int|false the current PHP process ID, or false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function getmypid () {}
|
||||
function getmypid (): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the inode of the current script
|
||||
|
@ -1088,4 +1133,5 @@ function getmypid () {}
|
|||
* @return int|false the current script's inode as an integer, or false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function getmyinode () {}
|
||||
function getmyinode (): int|false
|
||||
{}
|
||||
|
|
|
@ -7,12 +7,13 @@ use JetBrains\PhpStorm\Pure;
|
|||
/**
|
||||
* Gets time of last page modification
|
||||
* @link https://php.net/manual/en/function.getlastmod.php
|
||||
* @return int the time of the last modification of the current
|
||||
* @return int|false the time of the last modification of the current
|
||||
* page. The value returned is a Unix timestamp, suitable for
|
||||
* feeding to date. Returns false on error.
|
||||
*/
|
||||
#[Pure]
|
||||
function getlastmod () {}
|
||||
function getlastmod (): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Decodes data encoded with MIME base64
|
||||
|
@ -28,7 +29,7 @@ function getlastmod () {}
|
|||
* binary.
|
||||
*/
|
||||
#[Pure]
|
||||
function base64_decode (string $string, bool $strict)
|
||||
function base64_decode (string $string, bool $strict): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -40,7 +41,8 @@ function base64_decode (string $string, bool $strict)
|
|||
* @return string The encoded data, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function base64_encode (string $string) {}
|
||||
function base64_encode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Uuencode a string
|
||||
|
@ -51,7 +53,8 @@ function base64_encode (string $string) {}
|
|||
* @return string the uuencoded data.
|
||||
*/
|
||||
#[Pure]
|
||||
function convert_uuencode (string $string) {}
|
||||
function convert_uuencode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Decode a uuencoded string
|
||||
|
@ -59,10 +62,11 @@ function convert_uuencode (string $string) {}
|
|||
* @param string $string <p>
|
||||
* The uuencoded data.
|
||||
* </p>
|
||||
* @return string the decoded data as a string.
|
||||
* @return string|false the decoded data as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function convert_uudecode (string $string) {}
|
||||
function convert_uudecode (string $string): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Absolute value
|
||||
|
@ -77,7 +81,9 @@ function convert_uudecode (string $string) {}
|
|||
* bigger value range than integer).
|
||||
*/
|
||||
#[Pure]
|
||||
function abs (int|float $num) {}
|
||||
function abs (int|float $num): int|float
|
||||
{}
|
||||
|
||||
|
||||
/**
|
||||
* Round fractions up
|
||||
|
@ -92,8 +98,9 @@ function abs (int|float $num) {}
|
|||
* usually bigger than that of integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function ceil (int|float $num) {}
|
||||
|
||||
#[LanguageLevelTypeAware(["8.0" => "float"], default: "float|false")]
|
||||
function ceil (int|float $num)
|
||||
{}
|
||||
/**
|
||||
* Round fractions down
|
||||
* @link https://php.net/manual/en/function.floor.php
|
||||
|
@ -106,7 +113,9 @@ function ceil (int|float $num) {}
|
|||
* usually bigger than that of integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function floor (int|float $num) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "float"], default: "float|false")]
|
||||
function floor (int|float $num)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the rounded value of val to specified precision (number of digits after the decimal point).
|
||||
|
@ -128,7 +137,8 @@ function floor (int|float $num) {}
|
|||
* @return float The rounded value
|
||||
*/
|
||||
#[Pure]
|
||||
function round (int|float $num, int $precision = 0, int $mode = PHP_ROUND_HALF_UP) {}
|
||||
function round (int|float $num, int $precision = 0, int $mode = PHP_ROUND_HALF_UP): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sine
|
||||
|
@ -139,7 +149,8 @@ function round (int|float $num, int $precision = 0, int $mode = PHP_ROUND_HALF_U
|
|||
* @return float The sine of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function sin (float $num) {}
|
||||
function sin (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Cosine
|
||||
|
@ -150,7 +161,8 @@ function sin (float $num) {}
|
|||
* @return float The cosine of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function cos (float $num) {}
|
||||
function cos (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tangent
|
||||
|
@ -161,7 +173,8 @@ function cos (float $num) {}
|
|||
* @return float The tangent of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function tan (float $num) {}
|
||||
function tan (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Arc sine
|
||||
|
@ -172,7 +185,8 @@ function tan (float $num) {}
|
|||
* @return float The arc sine of arg in radians
|
||||
*/
|
||||
#[Pure]
|
||||
function asin (float $num) {}
|
||||
function asin (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Arc cosine
|
||||
|
@ -183,7 +197,8 @@ function asin (float $num) {}
|
|||
* @return float The arc cosine of arg in radians.
|
||||
*/
|
||||
#[Pure]
|
||||
function acos (float $num) {}
|
||||
function acos (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Arc tangent
|
||||
|
@ -194,7 +209,8 @@ function acos (float $num) {}
|
|||
* @return float The arc tangent of arg in radians.
|
||||
*/
|
||||
#[Pure]
|
||||
function atan (float $num) {}
|
||||
function atan (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Inverse hyperbolic tangent
|
||||
|
@ -205,7 +221,8 @@ function atan (float $num) {}
|
|||
* @return float Inverse hyperbolic tangent of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function atanh (float $num) {}
|
||||
function atanh (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Arc tangent of two variables
|
||||
|
@ -220,7 +237,8 @@ function atanh (float $num) {}
|
|||
* in radians.
|
||||
*/
|
||||
#[Pure]
|
||||
function atan2 (float $y, float $x) {}
|
||||
function atan2 (float $y, float $x): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Hyperbolic sine
|
||||
|
@ -231,7 +249,8 @@ function atan2 (float $y, float $x) {}
|
|||
* @return float The hyperbolic sine of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function sinh (float $num) {}
|
||||
function sinh (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Hyperbolic cosine
|
||||
|
@ -242,7 +261,8 @@ function sinh (float $num) {}
|
|||
* @return float The hyperbolic cosine of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function cosh (float $num) {}
|
||||
function cosh (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Hyperbolic tangent
|
||||
|
@ -253,7 +273,8 @@ function cosh (float $num) {}
|
|||
* @return float The hyperbolic tangent of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function tanh (float $num) {}
|
||||
function tanh (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Inverse hyperbolic sine
|
||||
|
@ -264,7 +285,8 @@ function tanh (float $num) {}
|
|||
* @return float The inverse hyperbolic sine of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function asinh (float $num) {}
|
||||
function asinh (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Inverse hyperbolic cosine
|
||||
|
@ -275,7 +297,8 @@ function asinh (float $num) {}
|
|||
* @return float The inverse hyperbolic cosine of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function acosh (float $num) {}
|
||||
function acosh (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns exp(number) - 1, computed in a way that is accurate even
|
||||
|
@ -287,7 +310,8 @@ function acosh (float $num) {}
|
|||
* @return float 'e' to the power of arg minus one
|
||||
*/
|
||||
#[Pure]
|
||||
function expm1(float $num) {}
|
||||
function expm1(float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns log(1 + number), computed in a way that is accurate even when
|
||||
|
@ -299,7 +323,8 @@ function expm1(float $num) {}
|
|||
* @return float log(1 + number)
|
||||
*/
|
||||
#[Pure]
|
||||
function log1p(float $num) {}
|
||||
function log1p(float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get value of pi
|
||||
|
@ -307,7 +332,8 @@ function log1p(float $num) {}
|
|||
* @return float The value of pi as float.
|
||||
*/
|
||||
#[Pure]
|
||||
function pi () {}
|
||||
function pi (): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether a value is a legal finite number
|
||||
|
@ -320,7 +346,8 @@ function pi () {}
|
|||
* else false.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_finite (float $num) {}
|
||||
function is_finite (float $num): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether a value is not a number
|
||||
|
@ -332,7 +359,8 @@ function is_finite (float $num) {}
|
|||
* else false.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_nan (float $num) {}
|
||||
function is_nan (float $num): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Integer division
|
||||
|
@ -347,7 +375,8 @@ function is_nan (float $num) {}
|
|||
* @since 7.0
|
||||
*/
|
||||
#[Pure]
|
||||
function intdiv (int $num1, int $num2) {}
|
||||
function intdiv (int $num1, int $num2): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether a value is infinite
|
||||
|
@ -358,7 +387,8 @@ function intdiv (int $num1, int $num2) {}
|
|||
* @return bool true if val is infinite, else false.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_infinite (float $num) {}
|
||||
function is_infinite (float $num): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Exponential expression
|
||||
|
@ -369,13 +399,14 @@ function is_infinite (float $num) {}
|
|||
* @param mixed $exponent <p>
|
||||
* The exponent
|
||||
* </p>
|
||||
* @return int|float base raised to the power of exp.
|
||||
* @return object|int|float base raised to the power of exp.
|
||||
* If the result can be represented as integer it will be returned as type
|
||||
* integer, else it will be returned as type float.
|
||||
* If the power cannot be computed false will be returned instead.
|
||||
*/
|
||||
#[Pure]
|
||||
function pow (mixed $num, mixed $exponent) {}
|
||||
function pow (mixed $num, mixed $exponent): object|int|float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculates the exponent of <constant>e</constant>
|
||||
|
@ -386,7 +417,8 @@ function pow (mixed $num, mixed $exponent) {}
|
|||
* @return float 'e' raised to the power of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function exp (float $num) {}
|
||||
function exp (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Natural logarithm
|
||||
|
@ -403,7 +435,7 @@ function exp (float $num) {}
|
|||
* natural logarithm.
|
||||
*/
|
||||
#[Pure]
|
||||
function log (float $num, float $base)
|
||||
function log (float $num, float $base): float
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -415,7 +447,8 @@ function log (float $num, float $base)
|
|||
* @return float The base-10 logarithm of arg
|
||||
*/
|
||||
#[Pure]
|
||||
function log10 (float $num) {}
|
||||
function log10 (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Square root
|
||||
|
@ -427,7 +460,8 @@ function log10 (float $num) {}
|
|||
* or the special value NAN for negative numbers.
|
||||
*/
|
||||
#[Pure]
|
||||
function sqrt (float $num) {}
|
||||
function sqrt (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculate the length of the hypotenuse of a right-angle triangle
|
||||
|
@ -441,7 +475,8 @@ function sqrt (float $num) {}
|
|||
* @return float Calculated length of the hypotenuse
|
||||
*/
|
||||
#[Pure]
|
||||
function hypot (float $x, float $y) {}
|
||||
function hypot (float $x, float $y): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts the number in degrees to the radian equivalent
|
||||
|
@ -452,7 +487,8 @@ function hypot (float $x, float $y) {}
|
|||
* @return float The radian equivalent of number
|
||||
*/
|
||||
#[Pure]
|
||||
function deg2rad (float $num) {}
|
||||
function deg2rad (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts the radian number to the equivalent number in degrees
|
||||
|
@ -463,7 +499,8 @@ function deg2rad (float $num) {}
|
|||
* @return float The equivalent of number in degrees
|
||||
*/
|
||||
#[Pure]
|
||||
function rad2deg (float $num) {}
|
||||
function rad2deg (float $num): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Binary to decimal
|
||||
|
@ -474,7 +511,8 @@ function rad2deg (float $num) {}
|
|||
* @return int|float The decimal value of binary_string
|
||||
*/
|
||||
#[Pure]
|
||||
function bindec (string $binary_string) {}
|
||||
function bindec (string $binary_string): int|float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Hexadecimal to decimal
|
||||
|
@ -485,7 +523,8 @@ function bindec (string $binary_string) {}
|
|||
* @return int|float The decimal representation of hex_string
|
||||
*/
|
||||
#[Pure]
|
||||
function hexdec (string $hex_string) {}
|
||||
function hexdec (string $hex_string): int|float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Octal to decimal
|
||||
|
@ -496,7 +535,8 @@ function hexdec (string $hex_string) {}
|
|||
* @return int|float The decimal representation of octal_string
|
||||
*/
|
||||
#[Pure]
|
||||
function octdec (string $octal_string) {}
|
||||
function octdec (string $octal_string): int|float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Decimal to binary
|
||||
|
@ -615,7 +655,8 @@ function octdec (string $octal_string) {}
|
|||
* @return string Binary string representation of number
|
||||
*/
|
||||
#[Pure]
|
||||
function decbin (int $num) {}
|
||||
function decbin (int $num): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Decimal to octal
|
||||
|
@ -626,7 +667,8 @@ function decbin (int $num) {}
|
|||
* @return string Octal string representation of number
|
||||
*/
|
||||
#[Pure]
|
||||
function decoct (int $num) {}
|
||||
function decoct (int $num): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Decimal to hexadecimal
|
||||
|
@ -637,7 +679,8 @@ function decoct (int $num) {}
|
|||
* @return string Hexadecimal string representation of number
|
||||
*/
|
||||
#[Pure]
|
||||
function dechex (int $num) {}
|
||||
function dechex (int $num): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert a number between arbitrary bases
|
||||
|
@ -654,7 +697,8 @@ function dechex (int $num) {}
|
|||
* @return string number converted to base tobase
|
||||
*/
|
||||
#[Pure]
|
||||
function base_convert (string $num, int $from_base, int $to_base) {}
|
||||
function base_convert (string $num, int $from_base, int $to_base): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Format a number with grouped thousands
|
||||
|
@ -670,7 +714,8 @@ function base_convert (string $num, int $from_base, int $to_base) {}
|
|||
* @return string A formatted version of number.
|
||||
*/
|
||||
#[Pure]
|
||||
function number_format (float $num , int $decimals = 0 , string $decimal_separator = '.' , string $thousands_separator = ',') {}
|
||||
function number_format (float $num , int $decimals = 0 , string $decimal_separator = '.' , string $thousands_separator = ','): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the floating point remainder (modulo) of the division
|
||||
|
@ -686,7 +731,8 @@ function number_format (float $num , int $decimals = 0 , string $decimal_separat
|
|||
* x/y
|
||||
*/
|
||||
#[Pure]
|
||||
function fmod(float $num1, float $num2) {}
|
||||
function fmod(float $num1, float $num2): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Performs a floating-point division under
|
||||
|
@ -706,7 +752,8 @@ function fdiv(float $num1, float $num2): float {}
|
|||
* @return string|false a string representation of the address or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function inet_ntop (string $ip) {}
|
||||
function inet_ntop (string $ip): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a human readable IP address to its packed in_addr representation
|
||||
|
@ -714,11 +761,12 @@ function inet_ntop (string $ip) {}
|
|||
* @param string $ip <p>
|
||||
* A human readable IPv4 or IPv6 address.
|
||||
* </p>
|
||||
* @return string the in_addr representation of the given
|
||||
* @return string|false the in_addr representation of the given
|
||||
* address
|
||||
*/
|
||||
#[Pure]
|
||||
function inet_pton (string $ip) {}
|
||||
function inet_pton (string $ip): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts a string containing an (IPv4) Internet Protocol dotted address into a long integer
|
||||
|
@ -730,7 +778,8 @@ function inet_pton (string $ip) {}
|
|||
* is invalid.
|
||||
*/
|
||||
#[Pure]
|
||||
function ip2long (string $ip) {}
|
||||
function ip2long (string $ip): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Converts an long integer address into a string in (IPv4) internet standard dotted format
|
||||
|
@ -738,10 +787,11 @@ function ip2long (string $ip) {}
|
|||
* @param int $ip <p>
|
||||
* A proper address representation.
|
||||
* </p>
|
||||
* @return string the Internet IP address as a string.
|
||||
* @return string|false the Internet IP address as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function long2ip (int $ip) {}
|
||||
function long2ip (int $ip): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the value of an environment variable
|
||||
|
@ -757,7 +807,8 @@ function long2ip (int $ip) {}
|
|||
* is provided, or false on an error.
|
||||
*/
|
||||
#[Pure]
|
||||
function getenv (string $name, bool $local_only = false) {}
|
||||
function getenv (string $name, bool $local_only = false): array|string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets the value of an environment variable
|
||||
|
@ -767,7 +818,8 @@ function getenv (string $name, bool $local_only = false) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function putenv (string $assignment) {}
|
||||
function putenv (string $assignment): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets options from the command line argument list
|
||||
|
@ -788,18 +840,19 @@ function putenv (string $assignment) {}
|
|||
* @return string[]|false[]|false This function will return an array of option / argument pairs or false on
|
||||
* failure.
|
||||
*/
|
||||
function getopt (string $short_options, array $long_options, &$rest_index)
|
||||
function getopt (string $short_options, array $long_options, &$rest_index): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets system load average
|
||||
* @link https://php.net/manual/en/function.sys-getloadavg.php
|
||||
* @return array an array with three samples (last 1, 5 and 15
|
||||
* @return array|false an array with three samples (last 1, 5 and 15
|
||||
* minutes).
|
||||
* @since 5.1.3
|
||||
*/
|
||||
#[Pure]
|
||||
function sys_getloadavg () {}
|
||||
function sys_getloadavg (): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return current Unix timestamp with microseconds
|
||||
|
@ -818,7 +871,8 @@ function sys_getloadavg () {}
|
|||
* @return string|float
|
||||
*/
|
||||
#[Pure]
|
||||
function microtime (bool $as_float) {}
|
||||
function microtime (bool $as_float): string|float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get current time
|
||||
|
@ -837,7 +891,8 @@ function microtime (bool $as_float) {}
|
|||
* "dsttime" - type of dst correction
|
||||
*/
|
||||
#[Pure]
|
||||
function gettimeofday (bool $as_float) {}
|
||||
function gettimeofday (bool $as_float): array|float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the current resource usages
|
||||
|
@ -846,11 +901,12 @@ function gettimeofday (bool $as_float) {}
|
|||
* If who is 1, getrusage will be called with
|
||||
* RUSAGE_CHILDREN.
|
||||
* </p>
|
||||
* @return array an associative array containing the data returned from the system
|
||||
* @return array|false an associative array containing the data returned from the system
|
||||
* call. All entries are accessible by using their documented field names.
|
||||
*/
|
||||
#[Pure]
|
||||
function getrusage (int $mode) {}
|
||||
function getrusage (int $mode): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generate a unique ID
|
||||
|
@ -873,7 +929,8 @@ function getrusage (int $mode) {}
|
|||
* @return string the unique identifier, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function uniqid (string $prefix = "", bool $more_entropy = false) {}
|
||||
function uniqid (string $prefix = "", bool $more_entropy = false): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert a quoted-printable string to an 8 bit string
|
||||
|
@ -884,7 +941,8 @@ function uniqid (string $prefix = "", bool $more_entropy = false) {}
|
|||
* @return string the 8-bit binary string.
|
||||
*/
|
||||
#[Pure]
|
||||
function quoted_printable_decode (string $string) {}
|
||||
function quoted_printable_decode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert a 8 bit string to a quoted-printable string
|
||||
|
@ -895,7 +953,8 @@ function quoted_printable_decode (string $string) {}
|
|||
* @return string the encoded string.
|
||||
*/
|
||||
#[Pure]
|
||||
function quoted_printable_encode (string $string) {}
|
||||
function quoted_printable_encode (string $string): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Convert from one Cyrillic character set to another
|
||||
|
@ -917,7 +976,8 @@ function quoted_printable_encode (string $string) {}
|
|||
*/
|
||||
#[Pure]
|
||||
#[Deprecated(since: '7.4',reason: 'Us mb_convert_string(), iconv() or UConverter instead.')]
|
||||
function convert_cyr_string (string $str, string $from, string $to) {}
|
||||
function convert_cyr_string (string $str, string $from, string $to): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the name of the owner of the current PHP script
|
||||
|
@ -925,7 +985,8 @@ function convert_cyr_string (string $str, string $from, string $to) {}
|
|||
* @return string the username as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_current_user () {}
|
||||
function get_current_user (): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Limits the maximum execution time
|
||||
|
@ -936,7 +997,8 @@ function get_current_user () {}
|
|||
* </p>
|
||||
* @return bool Returns TRUE on success, or FALSE on failure.
|
||||
*/
|
||||
function set_time_limit (int $seconds) {}
|
||||
function set_time_limit (int $seconds): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the value of a PHP configuration option
|
||||
|
@ -944,11 +1006,12 @@ function set_time_limit (int $seconds) {}
|
|||
* @param string $option <p>
|
||||
* The configuration option name.
|
||||
* </p>
|
||||
* @return string the current value of the PHP configuration variable specified by
|
||||
* @return array|string|false the current value of the PHP configuration variable specified by
|
||||
* option, or false if an error occurs.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_cfg_var (string $option) {}
|
||||
function get_cfg_var (string $option): array|string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>set_magic_quotes_runtime</function>
|
||||
|
@ -969,7 +1032,8 @@ function magic_quotes_runtime (bool $new_setting) {}
|
|||
* @removed 7.0
|
||||
*/
|
||||
#[Deprecated(reason: "This function has been DEPRECATED as of PHP 5.4.0. Raises an E_CORE_ERROR", since: "5.3")]
|
||||
function set_magic_quotes_runtime (bool $new_setting) {}
|
||||
function set_magic_quotes_runtime (bool $new_setting): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the current configuration setting of magic quotes gpc
|
||||
|
@ -978,7 +1042,8 @@ function set_magic_quotes_runtime (bool $new_setting) {}
|
|||
* @removed 8.0
|
||||
*/
|
||||
#[Deprecated(since: '7.4')]
|
||||
function get_magic_quotes_gpc () {}
|
||||
function get_magic_quotes_gpc (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the current active configuration setting of magic_quotes_runtime
|
||||
|
@ -986,7 +1051,8 @@ function get_magic_quotes_gpc () {}
|
|||
* @return int 0 if magic quotes runtime is off, 1 otherwise.
|
||||
*/
|
||||
#[Deprecated(since: '7.4')]
|
||||
function get_magic_quotes_runtime () {}
|
||||
function get_magic_quotes_runtime (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Import GET/POST/Cookie variables into the global scope
|
||||
|
@ -1022,7 +1088,7 @@ function get_magic_quotes_runtime () {}
|
|||
* @removed 5.4
|
||||
*/
|
||||
#[Deprecated(reason: "This function has been DEPRECATED as of PHP 5.3.0", since: "5.3")]
|
||||
function import_request_variables (string $types, $prefix = null)
|
||||
function import_request_variables (string $types, $prefix = null): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1091,5 +1157,6 @@ function import_request_variables (string $types, $prefix = null)
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function error_log (string $message, int $message_type, string $destination, string $additional_headers) {
|
||||
function error_log (string $message, int $message_type, string $destination, string $additional_headers): bool
|
||||
{
|
||||
}
|
||||
|
|
|
@ -18,7 +18,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
"line" => "int",
|
||||
])]
|
||||
#[Pure]
|
||||
function error_get_last () {}
|
||||
function error_get_last (): ?array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Call the callback given by the first parameter
|
||||
|
@ -41,7 +42,8 @@ function error_get_last () {}
|
|||
* </p>
|
||||
* @return mixed|false the function result, or false on error.
|
||||
*/
|
||||
function call_user_func (callable $callback, mixed ...$args) {}
|
||||
function call_user_func (callable $callback, mixed ...$args): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Call a callback with an array of parameters
|
||||
|
@ -54,7 +56,8 @@ function call_user_func (callable $callback, mixed ...$args) {}
|
|||
* </p>
|
||||
* @return mixed|false the function result, or false on error.
|
||||
*/
|
||||
function call_user_func_array (callable $callback, array $args) {}
|
||||
function call_user_func_array (callable $callback, array $args): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Call a user method on an specific object
|
||||
|
@ -67,7 +70,8 @@ function call_user_func_array (callable $callback, array $args) {}
|
|||
* @see call_user_func()
|
||||
*/
|
||||
#[Deprecated(reason: "use call_user_func() instead", since: "5.3")]
|
||||
function call_user_method (string $method_name, object &$obj, ...$parameter) {}
|
||||
function call_user_method (string $method_name, object &$obj, ...$parameter): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Call a user method given with an array of parameters
|
||||
|
@ -80,7 +84,8 @@ function call_user_method (string $method_name, object &$obj, ...$parameter) {}
|
|||
* @see call_user_func()
|
||||
*/
|
||||
#[Deprecated(reason: "use call_user_func() instead", since: "5.3")]
|
||||
function call_user_method_array (string $method_name, object &$obj, array $params) {}
|
||||
function call_user_method_array (string $method_name, object &$obj, array $params): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Call a static method
|
||||
|
@ -95,7 +100,8 @@ function call_user_method_array (string $method_name, object &$obj, array $param
|
|||
* </p>
|
||||
* @return mixed|false the function result, or false on error.
|
||||
*/
|
||||
function forward_static_call (callable $callback, ...$args) {}
|
||||
function forward_static_call (callable $callback, ...$args): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Call a static method and pass the arguments as array
|
||||
|
@ -108,7 +114,8 @@ function forward_static_call (callable $callback, ...$args) {}
|
|||
* @param array $args
|
||||
* @return mixed|false the function result, or false on error.
|
||||
*/
|
||||
function forward_static_call_array (callable $callback, array $args) {}
|
||||
function forward_static_call_array (callable $callback, array $args): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Generates a storable representation of a value
|
||||
|
@ -136,7 +143,8 @@ function forward_static_call_array (callable $callback, array $args) {}
|
|||
* @return string a string containing a byte-stream representation of
|
||||
* value that can be stored anywhere.
|
||||
*/
|
||||
function serialize (mixed $value) {}
|
||||
function serialize (mixed $value): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Creates a PHP value from a stored representation
|
||||
|
@ -179,7 +187,8 @@ function serialize (mixed $value) {}
|
|||
* In case the passed string is not unserializeable, false is returned and
|
||||
* E_NOTICE is issued.
|
||||
*/
|
||||
function unserialize (string $data, array $options = []) {}
|
||||
function unserialize (string $data, array $options = []): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Dumps information about a variable
|
||||
|
@ -190,7 +199,7 @@ function unserialize (string $data, array $options = []) {}
|
|||
* @param mixed ...$values [optional]
|
||||
* @return void
|
||||
*/
|
||||
function var_dump (mixed $value, ...$values) {}
|
||||
function var_dump (mixed $value, ...$values): void {}
|
||||
|
||||
/**
|
||||
* Outputs or returns a parsable string representation of a variable
|
||||
|
@ -207,7 +216,7 @@ function var_dump (mixed $value, ...$values) {}
|
|||
* parameter is used and evaluates to true. Otherwise, this function will
|
||||
* return null.
|
||||
*/
|
||||
function var_export (mixed $value, bool $return)
|
||||
function var_export (mixed $value, bool $return): ?string
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -219,7 +228,7 @@ function var_export (mixed $value, bool $return)
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function debug_zval_dump (mixed $value, mixed ...$values) {}
|
||||
function debug_zval_dump (mixed $value, mixed ...$values): void {}
|
||||
|
||||
/**
|
||||
* Prints human-readable information about a variable
|
||||
|
@ -233,12 +242,12 @@ function debug_zval_dump (mixed $value, mixed ...$values) {}
|
|||
* to true, print_r will return its output, instead of
|
||||
* printing it (which it does by default).
|
||||
* </p>
|
||||
* @return string|true If given a string, integer or float,
|
||||
* @return string|bool If given a string, integer or float,
|
||||
* the value itself will be printed. If given an array, values
|
||||
* will be presented in a format that shows keys and elements. Similar
|
||||
* notation is used for objects.
|
||||
*/
|
||||
function print_r (mixed $value, bool $return)
|
||||
function print_r (mixed $value, bool $return): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -252,7 +261,8 @@ function print_r (mixed $value, bool $return)
|
|||
* @return int the memory amount in bytes.
|
||||
*/
|
||||
#[Pure]
|
||||
function memory_get_usage (bool $real_usage = false) {}
|
||||
function memory_get_usage (bool $real_usage = false): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the peak of memory allocated by PHP
|
||||
|
@ -265,7 +275,8 @@ function memory_get_usage (bool $real_usage = false) {}
|
|||
* @return int the memory peak in bytes.
|
||||
*/
|
||||
#[Pure]
|
||||
function memory_get_peak_usage (bool $real_usage = false) {}
|
||||
function memory_get_peak_usage (bool $real_usage = false): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Register a function for execution on shutdown
|
||||
|
@ -288,9 +299,9 @@ function memory_get_peak_usage (bool $real_usage = false) {}
|
|||
* It is possible to pass parameters to the shutdown function by passing
|
||||
* additional parameters.
|
||||
* </p>
|
||||
* @return void
|
||||
* @return bool
|
||||
*/
|
||||
function register_shutdown_function (callable $callback, ...$args) {}
|
||||
function register_shutdown_function (callable $callback, ...$args): bool {}
|
||||
|
||||
/**
|
||||
* Register a function for execution on each tick
|
||||
|
@ -303,7 +314,8 @@ function register_shutdown_function (callable $callback, ...$args) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function register_tick_function (callable $callback, ...$args) {}
|
||||
function register_tick_function (callable $callback, ...$args): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* De-register a function for execution on each tick
|
||||
|
@ -314,7 +326,7 @@ function register_tick_function (callable $callback, ...$args) {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function unregister_tick_function (callable $callback) {}
|
||||
function unregister_tick_function (callable $callback): void {}
|
||||
|
||||
/**
|
||||
* Syntax highlighting of a file
|
||||
|
@ -330,7 +342,8 @@ function unregister_tick_function (callable $callback) {}
|
|||
* code as a string instead of printing it out. Otherwise, it will return
|
||||
* true on success, false on failure.
|
||||
*/
|
||||
function highlight_file (string $filename, bool $return = false) {}
|
||||
function highlight_file (string $filename, bool $return = false): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>highlight_file</function>
|
||||
|
@ -339,7 +352,8 @@ function highlight_file (string $filename, bool $return = false) {}
|
|||
* @param bool $return [optional]
|
||||
* @return string|bool
|
||||
*/
|
||||
function show_source (string $filename, bool $return = false) {}
|
||||
function show_source (string $filename, bool $return = false): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Syntax highlighting of a string
|
||||
|
@ -355,18 +369,20 @@ function show_source (string $filename, bool $return = false) {}
|
|||
* code as a string instead of printing it out. Otherwise, it will return
|
||||
* true on success, false on failure.
|
||||
*/
|
||||
function highlight_string (string $string, bool $return = false) {}
|
||||
function highlight_string (string $string, bool $return = false): string|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the system's high resolution time
|
||||
* @link https://secure.php.net/manual/en/function.hrtime.php
|
||||
* @param bool $as_number <p>Whether the high resolution time should be returned as array or number.<p>
|
||||
* @since 7.3
|
||||
* @return int[]|int|float Returns an array of integers in the form [seconds, nanoseconds], if the parameter get_as_number is false.
|
||||
* @return int[]|int|float|false Returns an array of integers in the form [seconds, nanoseconds], if the parameter get_as_number is false.
|
||||
* Otherwise the nanoseconds are returned as integer (64bit platforms) or float (32bit platforms).
|
||||
*/
|
||||
#[Pure]
|
||||
function hrtime(bool $as_number = false) {}
|
||||
function hrtime(bool $as_number = false): array|int|float|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return source with stripped comments and whitespace
|
||||
|
@ -384,7 +400,8 @@ function hrtime(bool $as_number = false) {}
|
|||
* #29606.
|
||||
*/
|
||||
#[Pure]
|
||||
function php_strip_whitespace (string $filename) {}
|
||||
function php_strip_whitespace (string $filename): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the value of a configuration option
|
||||
|
@ -393,11 +410,12 @@ function php_strip_whitespace (string $filename) {}
|
|||
* @param string $option <p>
|
||||
* The configuration option name.
|
||||
* </p>
|
||||
* @return string the value of the configuration option as a string on success, or
|
||||
* @return string|false the value of the configuration option as a string on success, or
|
||||
* an empty string on failure or for null values.
|
||||
*/
|
||||
#[Pure]
|
||||
function ini_get (string $option) {}
|
||||
function ini_get (string $option): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets all configuration options
|
||||
|
@ -411,7 +429,7 @@ function ini_get (string $option) {}
|
|||
* Retrieve details settings or only the current value for each setting.
|
||||
* Default is true (retrieve details).
|
||||
* </p>
|
||||
* @return array an associative array with directive name as the array key.
|
||||
* @return array|false an associative array with directive name as the array key.
|
||||
* </p>
|
||||
* <p>
|
||||
* When details is true (default) the array will
|
||||
|
@ -433,7 +451,8 @@ function ini_get (string $option) {}
|
|||
* why access shows the appropriate bitmask values.
|
||||
*/
|
||||
#[Pure]
|
||||
function ini_get_all (string $extension, bool $details) {}
|
||||
function ini_get_all (string $extension, bool $details): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets the value of a configuration option
|
||||
|
@ -451,7 +470,8 @@ function ini_get_all (string $extension, bool $details) {}
|
|||
* </p>
|
||||
* @return string|false the old value on success, false on failure.
|
||||
*/
|
||||
function ini_set (string $option, string $value) {}
|
||||
function ini_set (string $option, string $value): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>ini_set</function>
|
||||
|
@ -461,7 +481,8 @@ function ini_set (string $option, string $value) {}
|
|||
* @param string $value
|
||||
* @return string|false
|
||||
*/
|
||||
function ini_alter (string $option, string $value) {}
|
||||
function ini_alter (string $option, string $value): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Restores the value of a configuration option
|
||||
|
@ -472,15 +493,16 @@ function ini_alter (string $option, string $value) {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function ini_restore (string $option) {}
|
||||
function ini_restore (string $option): void {}
|
||||
|
||||
/**
|
||||
* Gets the current include_path configuration option
|
||||
* @link https://php.net/manual/en/function.get-include-path.php
|
||||
* @return string the path, as a string.
|
||||
* @return string|false the path, as a string.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_include_path () {}
|
||||
function get_include_path (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets the include_path configuration option
|
||||
|
@ -488,10 +510,11 @@ function get_include_path () {}
|
|||
* @param string $include_path <p>
|
||||
* The new value for the include_path
|
||||
* </p>
|
||||
* @return string|bool the old include_path on
|
||||
* @return string|false the old include_path on
|
||||
* success or false on failure.
|
||||
*/
|
||||
function set_include_path (string $include_path) {}
|
||||
function set_include_path (string $include_path): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Restores the value of the include_path configuration option
|
||||
|
@ -577,7 +600,8 @@ function restore_include_path () {}
|
|||
* setcookie successfully runs, it will return true.
|
||||
* This does not indicate whether the user accepted the cookie.
|
||||
*/
|
||||
function setcookie (string $name, $value = "", $expires_or_options = 0, $path = "", $domain = "", $secure = false, $httponly = false) {}
|
||||
function setcookie (string $name, $value = "", $expires_or_options = 0, $path = "", $domain = "", $secure = false, $httponly = false): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Send a cookie
|
||||
|
@ -600,7 +624,8 @@ function setcookie (string $name, $value = "", $expires_or_options = 0, $path =
|
|||
* This does not indicate whether the user accepted the cookie.
|
||||
* @since 7.3
|
||||
*/
|
||||
function setcookie(string $name, $value = '', array $options = []) {}
|
||||
function setcookie(string $name, $value = '', array $options = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Send a cookie without urlencoding the cookie value
|
||||
|
@ -614,7 +639,8 @@ function setcookie(string $name, $value = '', array $options = []) {}
|
|||
* @param bool $httponly [optional]
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function setrawcookie (string $name, $value = '', $expires_or_options = 0, $path = "", $domain = "", $secure = false, $httponly = false) {}
|
||||
function setrawcookie (string $name, $value = '', $expires_or_options = 0, $path = "", $domain = "", $secure = false, $httponly = false): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Send a cookie without urlencoding the cookie value
|
||||
|
@ -636,7 +662,8 @@ function setrawcookie (string $name, $value = '', $expires_or_options = 0, $path
|
|||
* setcookie successfully runs, it will return true.
|
||||
* This does not indicate whether the user accepted the cookie.
|
||||
*/
|
||||
function setrawcookie (string $name, $value = '', array $options = []) {}
|
||||
function setrawcookie (string $name, $value = '', array $options = []): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Send a raw HTTP header
|
||||
|
@ -672,7 +699,7 @@ function setrawcookie (string $name, $value = '', array $options = []) {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function header (string $header, bool $replace = true, int $response_code)
|
||||
function header (string $header, bool $replace = true, int $response_code): void
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -684,7 +711,7 @@ function header (string $header, bool $replace = true, int $response_code)
|
|||
* This parameter is case-insensitive.
|
||||
* @return void
|
||||
*/
|
||||
function header_remove (string $name) {}
|
||||
function header_remove (string $name): void {}
|
||||
|
||||
/**
|
||||
* Checks if or where headers have been sent
|
||||
|
@ -702,7 +729,8 @@ function header_remove (string $name) {}
|
|||
* @return bool headers_sent will return false if no HTTP headers
|
||||
* have already been sent or true otherwise.
|
||||
*/
|
||||
function headers_sent (&$filename, &$line) {}
|
||||
function headers_sent (&$filename, &$line): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns a list of response headers sent (or ready to send)
|
||||
|
@ -710,7 +738,8 @@ function headers_sent (&$filename, &$line) {}
|
|||
* @return array a numerically indexed array of headers.
|
||||
*/
|
||||
#[Pure]
|
||||
function headers_list () {}
|
||||
function headers_list (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Fetches all HTTP request headers from the current request
|
||||
|
@ -718,7 +747,8 @@ function headers_list () {}
|
|||
* @return array|false An associative array of all the HTTP headers in the current request, or <b>FALSE</b on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function apache_request_headers () {}
|
||||
function apache_request_headers (): bool|array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Fetches all HTTP headers from the current request.
|
||||
|
@ -727,7 +757,8 @@ function apache_request_headers () {}
|
|||
* @return array|false An associative array of all the HTTP headers in the current request, or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function getallheaders () {}
|
||||
function getallheaders (): bool|array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check whether client disconnected
|
||||
|
@ -735,7 +766,8 @@ function getallheaders () {}
|
|||
* @return int 1 if client disconnected, 0 otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function connection_aborted () {}
|
||||
function connection_aborted (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns connection status bitfield
|
||||
|
@ -745,7 +777,8 @@ function connection_aborted () {}
|
|||
* status.
|
||||
*/
|
||||
#[Pure]
|
||||
function connection_status () {}
|
||||
function connection_status (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set whether a client disconnect should abort script execution
|
||||
|
@ -757,7 +790,8 @@ function connection_status () {}
|
|||
* </p>
|
||||
* @return int the previous setting, as an integer.
|
||||
*/
|
||||
function ignore_user_abort (bool $enable) {}
|
||||
function ignore_user_abort (bool $enable): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parse a configuration file
|
||||
|
@ -787,7 +821,8 @@ function ignore_user_abort (bool $enable) {}
|
|||
* @return array|false The settings are returned as an associative array on success,
|
||||
* and false on failure.
|
||||
*/
|
||||
function parse_ini_file (string $filename, bool $process_sections = false, int $scanner_mode = INI_SCANNER_NORMAL) {}
|
||||
function parse_ini_file (string $filename, bool $process_sections = false, int $scanner_mode = INI_SCANNER_NORMAL): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parse a configuration string
|
||||
|
@ -810,7 +845,8 @@ function parse_ini_file (string $filename, bool $process_sections = false, int $
|
|||
* and false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function parse_ini_string (string $ini_string, bool $process_sections = false, int $scanner_mode = INI_SCANNER_NORMAL) {}
|
||||
function parse_ini_string (string $ini_string, bool $process_sections = false, int $scanner_mode = INI_SCANNER_NORMAL): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tells whether the file was uploaded via HTTP POST
|
||||
|
@ -821,7 +857,8 @@ function parse_ini_string (string $ini_string, bool $process_sections = false, i
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_uploaded_file (string $filename) {}
|
||||
function is_uploaded_file (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Moves an uploaded file to a new location
|
||||
|
@ -843,14 +880,16 @@ function is_uploaded_file (string $filename) {}
|
|||
* move_uploaded_file will return
|
||||
* false. Additionally, a warning will be issued.
|
||||
*/
|
||||
function move_uploaded_file (string $from, string $to) {}
|
||||
function move_uploaded_file (string $from, string $to): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* @return array|false
|
||||
* @since 7.3
|
||||
*/
|
||||
#[Pure]
|
||||
function net_get_interfaces() {}
|
||||
function net_get_interfaces(): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the Internet host name corresponding to a given IP address
|
||||
|
@ -858,11 +897,12 @@ function net_get_interfaces() {}
|
|||
* @param string $ip <p>
|
||||
* The host IP address.
|
||||
* </p>
|
||||
* @return string the host name or the unmodified ip_address
|
||||
* @return string|false the host name or the unmodified ip_address
|
||||
* on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function gethostbyaddr (string $ip) {}
|
||||
function gethostbyaddr (string $ip): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the IPv4 address corresponding to a given Internet host name
|
||||
|
@ -874,7 +914,8 @@ function gethostbyaddr (string $ip) {}
|
|||
* hostname on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function gethostbyname (string $hostname) {}
|
||||
function gethostbyname (string $hostname): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get a list of IPv4 addresses corresponding to a given Internet host
|
||||
|
@ -887,7 +928,8 @@ function gethostbyname (string $hostname) {}
|
|||
* hostname could not be resolved.
|
||||
*/
|
||||
#[Pure]
|
||||
function gethostbynamel(string $hostname) {}
|
||||
function gethostbynamel(string $hostname): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the host name
|
||||
|
@ -896,7 +938,8 @@ function gethostbynamel(string $hostname) {}
|
|||
* returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function gethostname () {}
|
||||
function gethostname (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>checkdnsrr</function>
|
||||
|
@ -911,7 +954,8 @@ function gethostname () {}
|
|||
* </p>
|
||||
* @return bool Returns <b>TRUE</b> if any records are found; returns <b>FALSE</b> if no records were found or if an error occurred.
|
||||
*/
|
||||
function dns_check_record (string $hostname, string $type = 'MX') {}
|
||||
function dns_check_record (string $hostname, string $type = 'MX'): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Check DNS records corresponding to a given Internet host name or IP address
|
||||
|
@ -928,7 +972,7 @@ function dns_check_record (string $hostname, string $type = 'MX') {}
|
|||
* were found or if an error occurred.
|
||||
*/
|
||||
#[Pure]
|
||||
function checkdnsrr (string $hostname, string $type)
|
||||
function checkdnsrr (string $hostname, string $type): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -939,7 +983,8 @@ function checkdnsrr (string $hostname, string $type)
|
|||
* @param array &$weights [optional]
|
||||
* @return bool
|
||||
*/
|
||||
function dns_get_mx (string $hostname, &$hosts, &$weights) {}
|
||||
function dns_get_mx (string $hostname, &$hosts, &$weights): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get MX records corresponding to a given Internet host name
|
||||
|
@ -958,7 +1003,7 @@ function dns_get_mx (string $hostname, &$hosts, &$weights) {}
|
|||
* @return bool true if any records are found; returns false if no records
|
||||
* were found or if an error occurred.
|
||||
*/
|
||||
function getmxrr (string $hostname, &$hosts, &$weights)
|
||||
function getmxrr (string $hostname, &$hosts, &$weights): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1008,7 +1053,7 @@ function getmxrr (string $hostname, &$hosts, &$weights)
|
|||
* In case of raw mode, we query only the requested type
|
||||
* instead of looping type by type before going with the additional info stuff.
|
||||
* </p>
|
||||
* @return array This function returns an array of associative arrays. Each associative array contains
|
||||
* @return array|false This function returns an array of associative arrays. Each associative array contains
|
||||
* at minimum the following keys:
|
||||
* <table>
|
||||
* Basic DNS attributes
|
||||
|
@ -1168,5 +1213,5 @@ function getmxrr (string $hostname, &$hosts, &$weights)
|
|||
* </tr>
|
||||
* </table>
|
||||
*/
|
||||
function dns_get_record (string $hostname, int $type = DNS_ANY, &$authoritative_name_servers, &$additional_records, bool $raw = false)
|
||||
function dns_get_record (string $hostname, int $type = DNS_ANY, &$authoritative_name_servers, &$additional_records, bool $raw = false): array|false
|
||||
{}
|
||||
|
|
|
@ -11,7 +11,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function boolval(mixed $value) {}
|
||||
function boolval(mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the integer value of a variable
|
||||
|
@ -40,7 +41,8 @@ function boolval(mixed $value) {}
|
|||
* apply.
|
||||
*/
|
||||
#[Pure]
|
||||
function intval (mixed $value, int $base = 10) {}
|
||||
function intval (mixed $value, int $base = 10): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get float value of a variable
|
||||
|
@ -49,7 +51,8 @@ function intval (mixed $value, int $base = 10) {}
|
|||
* @return float value of the given variable. Empty arrays return 0, non-empty arrays return 1.
|
||||
*/
|
||||
#[Pure]
|
||||
function floatval (mixed $value) {}
|
||||
function floatval (mixed $value): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 4.2.0, PHP 5)<br/>
|
||||
|
@ -61,7 +64,8 @@ function floatval (mixed $value) {}
|
|||
* @return float value of the given variable. Empty arrays return 0, non-empty arrays return 1.
|
||||
*/
|
||||
#[Pure]
|
||||
function doubleval (mixed $value) {}
|
||||
function doubleval (mixed $value): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get string value of a variable
|
||||
|
@ -76,7 +80,8 @@ function doubleval (mixed $value) {}
|
|||
* @return string The string value of var.
|
||||
*/
|
||||
#[Pure]
|
||||
function strval (mixed $value) {}
|
||||
function strval (mixed $value): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the type of a variable
|
||||
|
@ -99,7 +104,8 @@ function strval (mixed $value) {}
|
|||
* "resource (closed)" since 7.2.0
|
||||
*/
|
||||
#[Pure]
|
||||
function gettype (mixed $value) {}
|
||||
function gettype (mixed $value): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set the type of a variable
|
||||
|
@ -135,7 +141,8 @@ function gettype (mixed $value) {}
|
|||
* </ul>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function settype (mixed &$var, string $type) {}
|
||||
function settype (mixed &$var, string $type): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether a variable is null.
|
||||
|
@ -147,7 +154,8 @@ function settype (mixed &$var, string $type) {}
|
|||
* otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_null (mixed $value) {}
|
||||
function is_null (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether a variable is a resource
|
||||
|
@ -159,7 +167,8 @@ function is_null (mixed $value) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_resource (mixed $value) {}
|
||||
function is_resource (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds out whether a variable is a boolean
|
||||
|
@ -171,7 +180,8 @@ function is_resource (mixed $value) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_bool (mixed $value) {}
|
||||
function is_bool (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>is_int</function>
|
||||
|
@ -183,7 +193,8 @@ function is_bool (mixed $value) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_long (mixed $value) {}
|
||||
function is_long (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether the type of a variable is float
|
||||
|
@ -195,7 +206,8 @@ function is_long (mixed $value) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_float (mixed $value) {}
|
||||
function is_float (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find whether the type of a variable is integer
|
||||
|
@ -207,7 +219,8 @@ function is_float (mixed $value) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_int (mixed $value) {}
|
||||
function is_int (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>is_int</function>
|
||||
|
@ -219,7 +232,8 @@ function is_int (mixed $value) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_integer (mixed $value) {}
|
||||
function is_integer (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>is_float</function>
|
||||
|
@ -231,7 +245,8 @@ function is_integer (mixed $value) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_double (mixed $value) {}
|
||||
function is_double (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>is_float</function>
|
||||
|
@ -244,7 +259,8 @@ function is_double (mixed $value) {}
|
|||
*/
|
||||
#[Pure]
|
||||
#[Deprecated(since: '7.4')]
|
||||
function is_real (mixed $var) {}
|
||||
function is_real (mixed $var): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether a variable is a number or a numeric string
|
||||
|
@ -256,7 +272,8 @@ function is_real (mixed $var) {}
|
|||
* string, false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_numeric (mixed $value) {}
|
||||
function is_numeric (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find whether the type of a variable is string
|
||||
|
@ -268,7 +285,8 @@ function is_numeric (mixed $value) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_string (mixed $value) {}
|
||||
function is_string (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether a variable is an array
|
||||
|
@ -280,7 +298,8 @@ function is_string (mixed $value) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_array (mixed $value) {}
|
||||
function is_array (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether a variable is an object
|
||||
|
@ -292,7 +311,8 @@ function is_array (mixed $value) {}
|
|||
* Since 7.2.0 returns true for unserialized objects without a class definition (class of <b>__PHP_Incomplete_Class</b>).
|
||||
*/
|
||||
#[Pure]
|
||||
function is_object (mixed $value) {}
|
||||
function is_object (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Finds whether a variable is a scalar
|
||||
|
@ -304,7 +324,8 @@ function is_object (mixed $value) {}
|
|||
* otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_scalar (mixed $value) {}
|
||||
function is_scalar (mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Verify that the contents of a variable can be called as a function
|
||||
|
@ -329,7 +350,7 @@ function is_scalar (mixed $value) {}
|
|||
* @return bool <b>TRUE</b> if $var is callable, <b>FALSE</b>
|
||||
* otherwise.
|
||||
*/
|
||||
function is_callable (mixed $value, bool $syntax_only, &$callable_name)
|
||||
function is_callable (mixed $value, bool $syntax_only, &$callable_name): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -341,7 +362,8 @@ function is_callable (mixed $value, bool $syntax_only, &$callable_name)
|
|||
* @since 7.3
|
||||
*/
|
||||
#[Pure]
|
||||
function is_countable(mixed $value) {}
|
||||
function is_countable(mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Closes process file pointer
|
||||
|
@ -355,7 +377,8 @@ function is_countable(mixed $value) {}
|
|||
* <p>
|
||||
* If PHP has been compiled with <tt>--enable-sigchild</tt>, the return value of this function is undefined.
|
||||
*/
|
||||
function pclose ($handle) {}
|
||||
function pclose ($handle): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Opens process file pointer
|
||||
|
@ -376,7 +399,8 @@ function pclose ($handle) {}
|
|||
* <p>
|
||||
* If an error occurs, returns false.
|
||||
*/
|
||||
function popen (string $command, string $mode) {}
|
||||
function popen (string $command, string $mode)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Outputs a file
|
||||
|
@ -393,7 +417,7 @@ function popen (string $command, string $mode) {}
|
|||
* </p>
|
||||
* @return false|int the number of bytes read from the file, or FALSE on failure
|
||||
*/
|
||||
function readfile (string $filename, bool $use_include_path, $context)
|
||||
function readfile (string $filename, bool $use_include_path, $context): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -405,7 +429,8 @@ function readfile (string $filename, bool $use_include_path, $context)
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function rewind ($stream) {}
|
||||
function rewind ($stream): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Removes directory
|
||||
|
@ -416,7 +441,8 @@ function rewind ($stream) {}
|
|||
* @param resource $context [optional] ¬e.context-support;
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function rmdir (string $directory, $context) {}
|
||||
function rmdir (string $directory, $context): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Changes the current umask
|
||||
|
@ -427,7 +453,8 @@ function rmdir (string $directory, $context) {}
|
|||
* @return int umask without arguments simply returns the
|
||||
* current umask otherwise the old umask is returned.
|
||||
*/
|
||||
function umask (int $mask) {}
|
||||
function umask (int $mask): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Closes an open file pointer
|
||||
|
@ -438,7 +465,8 @@ function umask (int $mask) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function fclose ($stream) {}
|
||||
function fclose ($stream): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tests for end-of-file on a file pointer
|
||||
|
@ -447,7 +475,8 @@ function fclose ($stream) {}
|
|||
* @return bool true if the file pointer is at EOF or an error occurs
|
||||
* (including socket timeout); otherwise returns false.
|
||||
*/
|
||||
function feof ($stream) {}
|
||||
function feof ($stream): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets character from file pointer
|
||||
|
@ -456,7 +485,8 @@ function feof ($stream) {}
|
|||
* @return string|false a string containing a single character read from the file pointed
|
||||
* to by handle. Returns false on EOF.
|
||||
*/
|
||||
function fgetc ($stream) {}
|
||||
function fgetc ($stream): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets line from file pointer
|
||||
|
@ -480,7 +510,8 @@ function fgetc ($stream) {}
|
|||
* <p>
|
||||
* If an error occurs, returns false.
|
||||
*/
|
||||
function fgets ($stream, int $length) {}
|
||||
function fgets ($stream, int $length): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets line from file pointer and strip HTML tags
|
||||
|
@ -502,7 +533,8 @@ function fgets ($stream, int $length) {}
|
|||
* @removed 8.0
|
||||
*/
|
||||
#[Deprecated(since: '7.3')]
|
||||
function fgetss ($handle, int $length = null, $allowable_tags = null) {}
|
||||
function fgetss ($handle, int $length = null, $allowable_tags = null): bool|string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Binary-safe file read
|
||||
|
@ -513,7 +545,8 @@ function fgetss ($handle, int $length = null, $allowable_tags = null) {}
|
|||
* </p>
|
||||
* @return string|false the read string or false on failure.
|
||||
*/
|
||||
function fread ($stream, int $length) {}
|
||||
function fread ($stream, int $length): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Opens file or URL
|
||||
|
@ -696,7 +729,8 @@ function fread ($stream, int $length) {}
|
|||
* @param resource $context [optional] ¬e.context-support;
|
||||
* @return resource|false a file pointer resource on success, or false on error.
|
||||
*/
|
||||
function fopen (string $filename, string $mode, bool $use_include_path = false, $context) {}
|
||||
function fopen (string $filename, string $mode, bool $use_include_path = false, $context)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Output all remaining data on a file pointer
|
||||
|
@ -707,7 +741,9 @@ function fopen (string $filename, string $mode, bool $use_include_path = false,
|
|||
* the number of characters read from handle
|
||||
* and passed through to the output.
|
||||
*/
|
||||
function fpassthru ($stream) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function fpassthru ($stream)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Truncates a file to a given length
|
||||
|
@ -731,16 +767,18 @@ function fpassthru ($stream) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function ftruncate ($stream, int $size) {}
|
||||
function ftruncate ($stream, int $size): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets information about a file using an open file pointer
|
||||
* @link https://php.net/manual/en/function.fstat.php
|
||||
* @param resource $stream &fs.file.pointer;
|
||||
* @return array an array with the statistics of the file; the format of the array
|
||||
* @return array|false an array with the statistics of the file; the format of the array
|
||||
* is described in detail on the stat manual page.
|
||||
*/
|
||||
function fstat ($stream) {}
|
||||
function fstat ($stream): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Seeks on a file pointer
|
||||
|
@ -768,7 +806,8 @@ function fstat ($stream) {}
|
|||
* @return int Upon success, returns 0; otherwise, returns -1. Note that seeking
|
||||
* past EOF is not considered an error.
|
||||
*/
|
||||
function fseek ($stream, int $offset, int $whence = SEEK_SET) {}
|
||||
function fseek ($stream, int $offset, int $whence = SEEK_SET): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the current position of the file read/write pointer
|
||||
|
@ -785,7 +824,8 @@ function fseek ($stream, int $offset, int $whence = SEEK_SET) {}
|
|||
* <p>
|
||||
* If an error occurs, returns false.
|
||||
*/
|
||||
function ftell ($stream) {}
|
||||
function ftell ($stream): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Flushes the output to a file
|
||||
|
@ -793,7 +833,8 @@ function ftell ($stream) {}
|
|||
* @param resource $stream The file pointer must be valid, and must point to a file successfully opened by fopen() or fsockopen() (and not yet closed by fclose()).
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function fflush ($stream) {}
|
||||
function fflush ($stream): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Binary-safe file write
|
||||
|
@ -816,7 +857,7 @@ function fflush ($stream) {}
|
|||
* </p>
|
||||
* @return int|false the number of bytes written, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function fwrite ($stream, string $data, int $length)
|
||||
function fwrite ($stream, string $data, int $length): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -842,7 +883,7 @@ function fwrite ($stream, string $data, int $length)
|
|||
* @link https://php.net/manual/en/function.fputs.php
|
||||
* Binary-safe file write
|
||||
*/
|
||||
function fputs ($stream, string $data, int $length)
|
||||
function fputs ($stream, string $data, int $length): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -871,7 +912,8 @@ function fputs ($stream, string $data, int $length)
|
|||
* @param resource $context [optional] ¬e.context-support;
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function mkdir (string $directory, int $permissions = 0777, bool $recursive = false, $context) {}
|
||||
function mkdir (string $directory, int $permissions = 0777, bool $recursive = false, $context): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Renames a file or directory
|
||||
|
@ -889,7 +931,8 @@ function mkdir (string $directory, int $permissions = 0777, bool $recursive = fa
|
|||
* @param resource $context [optional] ¬e.context-support;
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function rename (string $from, string $to, $context) {}
|
||||
function rename (string $from, string $to, $context): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Copies file
|
||||
|
@ -911,7 +954,7 @@ function rename (string $from, string $to, $context) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function copy (string $from, string $to, $context)
|
||||
function copy (string $from, string $to, $context): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -927,7 +970,8 @@ function copy (string $from, string $to, $context)
|
|||
* @return string|false the new temporary filename, or false on
|
||||
* failure.
|
||||
*/
|
||||
function tempnam (string $directory, string $prefix) {}
|
||||
function tempnam (string $directory, string $prefix): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Creates a temporary file
|
||||
|
@ -935,7 +979,8 @@ function tempnam (string $directory, string $prefix) {}
|
|||
* @return resource|false a file handle, similar to the one returned by
|
||||
* fopen, for the new file or false on failure.
|
||||
*/
|
||||
function tmpfile () {}
|
||||
function tmpfile ()
|
||||
{}
|
||||
|
||||
/**
|
||||
* Reads entire file into an array
|
||||
|
@ -966,7 +1011,7 @@ function tmpfile () {}
|
|||
* use rtrim if you do not want the line ending
|
||||
* present.
|
||||
*/
|
||||
function file (string $filename, int $flags, $context)
|
||||
function file (string $filename, int $flags, $context): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -993,7 +1038,7 @@ function file (string $filename, int $flags, $context)
|
|||
* </p>
|
||||
* @return string|false The function returns the read data or false on failure.
|
||||
*/
|
||||
function file_get_contents (string $filename, bool $use_include_path = false, $context, int $offset = 0, int $length)
|
||||
function file_get_contents (string $filename, bool $use_include_path = false, $context, int $offset = 0, int $length): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1067,5 +1112,5 @@ function file_get_contents (string $filename, bool $use_include_path = false, $c
|
|||
* @return int|false The function returns the number of bytes that were written to the file, or
|
||||
* false on failure.
|
||||
*/
|
||||
function file_put_contents (string $filename, mixed $data, int $flags = 0, $context)
|
||||
function file_put_contents (string $filename, mixed $data, int $flags = 0, $context): int|false
|
||||
{}
|
||||
|
|
|
@ -71,13 +71,13 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @param int $microseconds [optional] <p>
|
||||
* See tv_sec description.
|
||||
* </p>
|
||||
* @return int On success stream_select returns the number of
|
||||
* @return int|false On success stream_select returns the number of
|
||||
* stream resources contained in the modified arrays, which may be zero if
|
||||
* the timeout expires before anything interesting happens. On error false
|
||||
* is returned and a warning raised (this can happen if the system call is
|
||||
* interrupted by an incoming signal).
|
||||
*/
|
||||
function stream_select (array &$read, array &$write, array &$except, int $seconds, int $microseconds)
|
||||
function stream_select (array &$read, array &$write, array &$except, int $seconds, int $microseconds): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -115,7 +115,8 @@ function stream_context_create (array $options, array $params) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function stream_context_set_params ($context, array $params) {}
|
||||
function stream_context_set_params ($context, array $params): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieves parameters from a context
|
||||
|
@ -126,7 +127,8 @@ function stream_context_set_params ($context, array $params) {}
|
|||
* </p>
|
||||
* @return array an associate array containing all context options and parameters.
|
||||
*/
|
||||
function stream_context_get_params ($context) {}
|
||||
function stream_context_get_params ($context): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets an option for a stream/wrapper/context
|
||||
|
@ -139,7 +141,8 @@ function stream_context_get_params ($context) {}
|
|||
* @param mixed $value
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function stream_context_set_option ($context, string $wrapper_or_options, string $option_name, mixed $value) {}
|
||||
function stream_context_set_option ($context, string $wrapper_or_options, string $option_name, mixed $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets an option for a stream/wrapper/context
|
||||
|
@ -148,7 +151,8 @@ function stream_context_set_option ($context, string $wrapper_or_options, string
|
|||
* @param array $options The options to set for the default context.
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function stream_context_set_option ($stream_or_context, array $options) {}
|
||||
function stream_context_set_option ($stream_or_context, array $options): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve options for a stream/wrapper/context
|
||||
|
@ -158,7 +162,8 @@ function stream_context_set_option ($stream_or_context, array $options) {}
|
|||
* </p>
|
||||
* @return array an associative array with the options.
|
||||
*/
|
||||
function stream_context_get_options ($stream_or_context) {}
|
||||
function stream_context_get_options ($stream_or_context): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retreive the default stream context
|
||||
|
@ -268,7 +273,8 @@ function stream_filter_append ($stream, string $filter_name, int $mode, mixed $p
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function stream_filter_remove ($stream_filter) {}
|
||||
function stream_filter_remove ($stream_filter): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Open Internet or Unix domain socket connection
|
||||
|
@ -310,7 +316,8 @@ function stream_filter_remove ($stream_filter) {}
|
|||
* fwrite, fclose, and
|
||||
* feof), false on failure.
|
||||
*/
|
||||
function stream_socket_client (string $address, &$error_code, &$error_message, float $timeout, int $flags, $context) {}
|
||||
function stream_socket_client (string $address, &$error_code, &$error_message, float $timeout, int $flags, $context)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Create an Internet or Unix domain server socket
|
||||
|
@ -360,7 +367,8 @@ function stream_socket_client (string $address, &$error_code, &$error_message, f
|
|||
* </p>
|
||||
* @return resource|false the created stream, or false on error.
|
||||
*/
|
||||
function stream_socket_server (string $address, &$error_code, &$error_message, int $flags, $context) {}
|
||||
function stream_socket_server (string $address, &$error_code, &$error_message, int $flags, $context)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Accept a connection on a socket created by {@see stream_socket_server}
|
||||
|
@ -380,7 +388,8 @@ function stream_socket_server (string $address, &$error_code, &$error_message, i
|
|||
* </p>
|
||||
* @return resource|false Returns a stream to the accepted socket connection or FALSE on failure.
|
||||
*/
|
||||
function stream_socket_accept ($socket, float $timeout, &$peer_name) {}
|
||||
function stream_socket_accept ($socket, float $timeout, &$peer_name)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve the name of the local or remote sockets
|
||||
|
@ -394,7 +403,8 @@ function stream_socket_accept ($socket, float $timeout, &$peer_name) {}
|
|||
* </p>
|
||||
* @return string|false The name of the socket or false on error.
|
||||
*/
|
||||
function stream_socket_get_name ($socket, bool $remote) {}
|
||||
function stream_socket_get_name ($socket, bool $remote): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Receives data from a socket, connected or not
|
||||
|
@ -433,7 +443,7 @@ function stream_socket_get_name ($socket, bool $remote) {}
|
|||
* </p>
|
||||
* @return string|false the read data, as a string, or false on error
|
||||
*/
|
||||
function stream_socket_recvfrom ($socket, int $length, int $flags, &$address)
|
||||
function stream_socket_recvfrom ($socket, int $length, int $flags, &$address): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -467,7 +477,7 @@ function stream_socket_recvfrom ($socket, int $length, int $flags, &$address)
|
|||
* </p>
|
||||
* @return int|false a result code, as an integer.
|
||||
*/
|
||||
function stream_socket_sendto ($socket, string $data, int $flags, string $address)
|
||||
function stream_socket_sendto ($socket, string $data, int $flags, string $address): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -490,7 +500,7 @@ function stream_socket_sendto ($socket, string $data, int $flags, string $addres
|
|||
* 0 if there isn't enough data and you should try again
|
||||
* (only for non-blocking sockets).
|
||||
*/
|
||||
function stream_socket_enable_crypto ($stream, bool $enable, int $crypto_method, $session_stream)
|
||||
function stream_socket_enable_crypto ($stream, bool $enable, int $crypto_method, $session_stream): int|bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -510,7 +520,8 @@ function stream_socket_enable_crypto ($stream, bool $enable, int $crypto_method,
|
|||
* @return bool true on success or false on failure.
|
||||
* @since 5.2.1
|
||||
*/
|
||||
function stream_socket_shutdown ($stream, int $mode) {}
|
||||
function stream_socket_shutdown ($stream, int $mode): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Creates a pair of connected, indistinguishable socket streams
|
||||
|
@ -538,7 +549,8 @@ function stream_socket_shutdown ($stream, int $mode) {}
|
|||
* @return array|false an array with the two socket resources on success, or
|
||||
* false on failure.
|
||||
*/
|
||||
function stream_socket_pair (int $domain, int $type, int $protocol) {}
|
||||
function stream_socket_pair (int $domain, int $type, int $protocol): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Copies data from one stream to another
|
||||
|
@ -557,7 +569,8 @@ function stream_socket_pair (int $domain, int $type, int $protocol) {}
|
|||
* </p>
|
||||
* @return int|false the total count of bytes copied, or false on failure.
|
||||
*/
|
||||
function stream_copy_to_stream ($from, $to, int $length, int $offset) {}
|
||||
function stream_copy_to_stream ($from, $to, int $length, int $offset): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Reads remainder of a stream into a string
|
||||
|
@ -574,7 +587,8 @@ function stream_copy_to_stream ($from, $to, int $length, int $offset) {}
|
|||
* </p>
|
||||
* @return string|false a string or false on failure.
|
||||
*/
|
||||
function stream_get_contents ($stream, int $length = -1, int $offset = -1) {}
|
||||
function stream_get_contents ($stream, int $length = -1, int $offset = -1): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tells whether the stream supports locking.
|
||||
|
@ -584,7 +598,8 @@ function stream_get_contents ($stream, int $length = -1, int $offset = -1) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function stream_supports_lock ($stream) {}
|
||||
function stream_supports_lock ($stream): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets line from file pointer and parse for CSV fields
|
||||
|
@ -610,7 +625,7 @@ function stream_supports_lock ($stream) {}
|
|||
* @param string $escape [optional] <p>
|
||||
* Set the escape character (one character only). Defaults as a backslash.
|
||||
* </p>
|
||||
* @return array|null|false an indexed array containing the fields read.
|
||||
* @return array|false an indexed array containing the fields read.
|
||||
* </p>
|
||||
* <p>
|
||||
* A blank line in a CSV file will be returned as an array
|
||||
|
@ -623,7 +638,8 @@ function stream_supports_lock ($stream) {}
|
|||
* handle is supplied or false on other errors,
|
||||
* including end of file.
|
||||
*/
|
||||
function fgetcsv ($stream, int $length = 0, string $separator = ',', string $enclosure = '"', string $escape = '\\') {}
|
||||
function fgetcsv ($stream, int $length = 0, string $separator = ',', string $enclosure = '"', string $escape = '\\'): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Format line as CSV and write to file pointer
|
||||
|
@ -643,7 +659,8 @@ function fgetcsv ($stream, int $length = 0, string $separator = ',', string $enc
|
|||
* @param string $escape The optional escape_char parameter sets the escape character (one character only).
|
||||
* @return int|false the length of the written string or false on failure.
|
||||
*/
|
||||
function fputcsv ($stream, array $fields, string $separator = ",", string $enclosure = '"', string $escape = "\\") {}
|
||||
function fputcsv ($stream, array $fields, string $separator = ",", string $enclosure = '"', string $escape = "\\"): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Portable advisory file locking
|
||||
|
@ -660,7 +677,7 @@ function fputcsv ($stream, array $fields, string $separator = ",", string $enclo
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function flock ($stream, int $operation, &$would_block)
|
||||
function flock ($stream, int $operation, &$would_block): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -690,7 +707,7 @@ function flock ($stream, int $operation, &$would_block)
|
|||
* the include_path directive.
|
||||
* This is used for local files, not URLs.
|
||||
* </p>
|
||||
* @return array an array with all the parsed meta tags.
|
||||
* @return array|false an array with all the parsed meta tags.
|
||||
* </p>
|
||||
* <p>
|
||||
* The value of the name property becomes the key, the value of the content
|
||||
|
@ -701,7 +718,7 @@ function flock ($stream, int $operation, &$would_block)
|
|||
* name, only the last one is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_meta_tags (string $filename, bool $use_include_path)
|
||||
function get_meta_tags (string $filename, bool $use_include_path): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -719,7 +736,8 @@ function get_meta_tags (string $filename, bool $use_include_path)
|
|||
* @return int 0 on success, or EOF if the request cannot be honored.
|
||||
* @see stream_set_read_buffer()
|
||||
*/
|
||||
function stream_set_write_buffer ($stream, int $size) {}
|
||||
function stream_set_write_buffer ($stream, int $size): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets read file buffering on the given stream
|
||||
|
@ -736,7 +754,8 @@ function stream_set_write_buffer ($stream, int $size) {}
|
|||
* @return int 0 on success, or EOF if the request cannot be honored.
|
||||
* @see stream_set_write_buffer()
|
||||
*/
|
||||
function stream_set_read_buffer ($stream, int $size) {}
|
||||
function stream_set_read_buffer ($stream, int $size): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>stream_set_write_buffer</function>
|
||||
|
@ -750,7 +769,8 @@ function stream_set_read_buffer ($stream, int $size) {}
|
|||
* This ensures that all writes with fwrite() are completed before other processes are allowed to write to that output stream.
|
||||
* @return int
|
||||
*/
|
||||
function set_file_buffer ($stream, int $size) {}
|
||||
function set_file_buffer ($stream, int $size): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>stream_set_blocking</function>
|
||||
|
@ -766,7 +786,8 @@ function set_file_buffer ($stream, int $size) {}
|
|||
* @see stream_set_blocking()
|
||||
*/
|
||||
#[Deprecated(replacement: "stream_set_blocking(%parametersList%)", since: 5.3)]
|
||||
function set_socket_blocking ($socket, bool $mode) {}
|
||||
function set_socket_blocking ($socket, bool $mode): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set blocking/non-blocking mode on a stream
|
||||
|
@ -786,7 +807,8 @@ function set_socket_blocking ($socket, bool $mode) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function stream_set_blocking ($stream, bool $enable) {}
|
||||
function stream_set_blocking ($stream, bool $enable): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>stream_set_blocking</function>
|
||||
|
@ -806,7 +828,8 @@ function stream_set_blocking ($stream, bool $enable) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function socket_set_blocking ($stream, bool $enable) {}
|
||||
function socket_set_blocking ($stream, bool $enable): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieves header/meta data from streams/file pointers
|
||||
|
@ -884,7 +907,8 @@ function socket_set_blocking ($stream, bool $enable) {}
|
|||
"crypto" => "array",
|
||||
"mediatype" => "string",
|
||||
])]
|
||||
function stream_get_meta_data ($stream) {}
|
||||
function stream_get_meta_data ($stream): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets line from stream resource up to a given delimiter
|
||||
|
@ -904,7 +928,7 @@ function stream_get_meta_data ($stream) {}
|
|||
* <p>
|
||||
* If an error occurs, returns false.
|
||||
*/
|
||||
function stream_get_line ($stream, int $length, string $ending)
|
||||
function stream_get_line ($stream, int $length, string $ending): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -927,7 +951,7 @@ function stream_get_line ($stream, int $length, string $ending)
|
|||
* stream_wrapper_register will return false if the
|
||||
* protocol already has a handler.
|
||||
*/
|
||||
function stream_wrapper_register (string $protocol, string $class, int $flags)
|
||||
function stream_wrapper_register (string $protocol, string $class, int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -951,7 +975,8 @@ function stream_wrapper_register (string $protocol, string $class, int $flags)
|
|||
* stream_wrapper_register will return false if the
|
||||
* protocol already has a handler.
|
||||
*/
|
||||
function stream_register_wrapper (string $protocol, string $class, int $flags = 0) {}
|
||||
function stream_register_wrapper (string $protocol, string $class, int $flags = 0): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Resolve filename against the include path according to the same rules as fopen()/include().
|
||||
|
@ -961,7 +986,8 @@ function stream_register_wrapper (string $protocol, string $class, int $flags =
|
|||
* @return string|false containing the resolved absolute filename, or FALSE on failure.
|
||||
* @since 5.3.2
|
||||
*/
|
||||
function stream_resolve_include_path (string $filename) {}
|
||||
function stream_resolve_include_path (string $filename): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Unregister a URL wrapper
|
||||
|
@ -970,7 +996,8 @@ function stream_resolve_include_path (string $filename) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function stream_wrapper_unregister (string $protocol) {}
|
||||
function stream_wrapper_unregister (string $protocol): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Restores a previously unregistered built-in wrapper
|
||||
|
@ -979,7 +1006,8 @@ function stream_wrapper_unregister (string $protocol) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function stream_wrapper_restore (string $protocol) {}
|
||||
function stream_wrapper_restore (string $protocol): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve list of registered streams
|
||||
|
@ -988,7 +1016,8 @@ function stream_wrapper_restore (string $protocol) {}
|
|||
* available on the running system.
|
||||
*/
|
||||
#[Pure]
|
||||
function stream_get_wrappers () {}
|
||||
function stream_get_wrappers (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Retrieve list of registered socket transports
|
||||
|
@ -996,7 +1025,8 @@ function stream_get_wrappers () {}
|
|||
* @return array an indexed array of socket transports names.
|
||||
*/
|
||||
#[Pure]
|
||||
function stream_get_transports () {}
|
||||
function stream_get_transports (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if a stream is a local stream
|
||||
|
@ -1008,7 +1038,8 @@ function stream_get_transports () {}
|
|||
* @since 5.2.4
|
||||
*/
|
||||
#[Pure]
|
||||
function stream_is_local ($stream) {}
|
||||
function stream_is_local ($stream): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Fetches all the headers sent by the server in response to an HTTP request
|
||||
|
@ -1026,7 +1057,7 @@ function stream_is_local ($stream) {}
|
|||
* failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_headers (string $url, bool $associative, $context)
|
||||
function get_headers (string $url, bool $associative, $context): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1043,7 +1074,7 @@ function get_headers (string $url, bool $associative, $context)
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function stream_set_timeout ($stream, int $seconds, int $microseconds)
|
||||
function stream_set_timeout ($stream, int $seconds, int $microseconds): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1061,7 +1092,8 @@ function stream_set_timeout ($stream, int $seconds, int $microseconds)
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function socket_set_timeout ($stream, int $seconds, int $microseconds = 0) {}
|
||||
function socket_set_timeout ($stream, int $seconds, int $microseconds = 0): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>stream_get_meta_data</function>
|
||||
|
@ -1126,7 +1158,8 @@ function socket_set_timeout ($stream, int $seconds, int $microseconds = 0) {}
|
|||
* uri (string) - the URI/filename associated with this
|
||||
* stream.
|
||||
*/
|
||||
function socket_get_status ($stream) {}
|
||||
function socket_get_status ($stream): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns canonicalized absolute pathname
|
||||
|
@ -1142,7 +1175,8 @@ function socket_get_status ($stream) {}
|
|||
* the file does not exist.
|
||||
*/
|
||||
#[Pure]
|
||||
function realpath (string $path) {}
|
||||
function realpath (string $path): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Match filename against a pattern
|
||||
|
@ -1200,6 +1234,6 @@ function realpath (string $path) {}
|
|||
* </p>
|
||||
* @return bool true if there is a match, false otherwise.
|
||||
*/
|
||||
function fnmatch (string $pattern, string $filename, int $flags)
|
||||
function fnmatch (string $pattern, string $filename, int $flags): bool
|
||||
{}
|
||||
?>
|
||||
|
|
|
@ -46,7 +46,8 @@ use JetBrains\PhpStorm\Pure;
|
|||
* fwrite, fclose, and
|
||||
* feof). If the call fails, it will return false
|
||||
*/
|
||||
function fsockopen (string $hostname, int $port, &$error_code, &$error_message, float $timeout) {}
|
||||
function fsockopen (string $hostname, int $port, &$error_code, &$error_message, float $timeout)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Open persistent Internet or Unix domain socket connection
|
||||
|
@ -59,7 +60,8 @@ function fsockopen (string $hostname, int $port, &$error_code, &$error_message,
|
|||
* @param float $timeout [optional]
|
||||
* @return resource|false
|
||||
*/
|
||||
function pfsockopen (string $hostname, int $port, &$error_code, &$error_message, float $timeout) {}
|
||||
function pfsockopen (string $hostname, int $port, &$error_code, &$error_message, float $timeout)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Pack data into binary string
|
||||
|
@ -166,7 +168,9 @@ function pfsockopen (string $hostname, int $port, &$error_code, &$error_message,
|
|||
* @return string|false a binary string containing data or false if the format string contains errors
|
||||
*/
|
||||
#[Pure]
|
||||
function pack (string $format, ...$values) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function pack (string $format, ...$values)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Unpack data from binary string
|
||||
|
@ -182,7 +186,8 @@ function pack (string $format, ...$values) {}
|
|||
* string or false if the format string contains errors
|
||||
*/
|
||||
#[Pure]
|
||||
function unpack (string $format, string $string, int $offset = 0) {}
|
||||
function unpack (string $format, string $string, int $offset = 0): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tells what the user's browser is capable of
|
||||
|
@ -212,7 +217,8 @@ function unpack (string $format, string $string, int $offset = 0) {}
|
|||
* reload, and check for the value.
|
||||
*/
|
||||
#[Pure]
|
||||
function get_browser (string $user_agent, bool $return_array) {}
|
||||
function get_browser (string $user_agent, bool $return_array): object|array|false
|
||||
{}
|
||||
|
||||
#[PhpStormStubsElementAvailable(to: '7.4')]
|
||||
/**
|
||||
|
@ -234,7 +240,7 @@ function get_browser (string $user_agent, bool $return_array) {}
|
|||
* @return string|null the encrypted string or <b>NULL</b> if an error occurs
|
||||
*/
|
||||
#[Pure]
|
||||
function crypt ($string, $salt = null)
|
||||
function crypt ($string, $salt = null): ?string
|
||||
{}
|
||||
|
||||
#[PhpStormStubsElementAvailable('8.0')]
|
||||
|
@ -257,7 +263,8 @@ function crypt ($string, $salt = null)
|
|||
* @return string|null the encrypted string or <b>NULL</b> if an error occurs
|
||||
*/
|
||||
#[Pure]
|
||||
function crypt (string $string, string $salt) {}
|
||||
function crypt (string $string, string $salt): ?string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Open directory handle
|
||||
|
@ -297,7 +304,7 @@ function opendir (string $directory, $context)
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function closedir ($dir_handle) {}
|
||||
function closedir ($dir_handle): void {}
|
||||
|
||||
/**
|
||||
* Change directory
|
||||
|
@ -307,7 +314,8 @@ function closedir ($dir_handle) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function chdir (string $directory) {}
|
||||
function chdir (string $directory): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Change the root directory
|
||||
|
@ -317,7 +325,8 @@ function chdir (string $directory) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function chroot (string $directory) {}
|
||||
function chroot (string $directory): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets the current working directory
|
||||
|
@ -334,7 +343,8 @@ function chroot (string $directory) {}
|
|||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function getcwd () {}
|
||||
function getcwd (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Rewind directory handle
|
||||
|
@ -347,7 +357,7 @@ function getcwd () {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function rewinddir ($dir_handle) {}
|
||||
function rewinddir ($dir_handle): void {}
|
||||
|
||||
/**
|
||||
* Read entry from directory handle
|
||||
|
@ -360,7 +370,8 @@ function rewinddir ($dir_handle) {}
|
|||
* </p>
|
||||
* @return string|false the filename on success or false on failure.
|
||||
*/
|
||||
function readdir ($dir_handle) {}
|
||||
function readdir ($dir_handle): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return an instance of the Directory class
|
||||
|
@ -369,10 +380,11 @@ function readdir ($dir_handle) {}
|
|||
* Directory to open
|
||||
* </p>
|
||||
* @param resource $context [optional]
|
||||
* @return Directory|null|false an instance of Directory, or <b>NULL</b> with wrong
|
||||
* @return Directory|false an instance of Directory, or <b>NULL</b> with wrong
|
||||
* parameters, or <b>FALSE</b> in case of another error
|
||||
*/
|
||||
function dir (string $directory, $context) {}
|
||||
function dir (string $directory, $context): Directory|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias of dir()
|
||||
|
@ -381,7 +393,8 @@ function dir (string $directory, $context) {}
|
|||
* @return Directory|false
|
||||
* @see dir()
|
||||
*/
|
||||
function getdir(string $directory, $context) {}
|
||||
function getdir(string $directory, $context): Directory|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* List files and directories inside the specified path
|
||||
|
@ -404,7 +417,7 @@ function getdir(string $directory, $context) {}
|
|||
* boolean false is returned, and an error of level
|
||||
* E_WARNING is generated.
|
||||
*/
|
||||
function scandir (string $directory, int $sorting_order, $context)
|
||||
function scandir (string $directory, int $sorting_order, $context): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -430,7 +443,7 @@ function scandir (string $directory, int $sorting_order, $context)
|
|||
* error.
|
||||
*/
|
||||
#[Pure]
|
||||
function glob (string $pattern, int $flags)
|
||||
function glob (string $pattern, int $flags): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -443,7 +456,8 @@ function glob (string $pattern, int $flags)
|
|||
* The time is returned as a Unix timestamp.
|
||||
*/
|
||||
#[Pure]
|
||||
function fileatime (string $filename) {}
|
||||
function fileatime (string $filename): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets inode change time of file
|
||||
|
@ -455,7 +469,8 @@ function fileatime (string $filename) {}
|
|||
* The time is returned as a Unix timestamp.
|
||||
*/
|
||||
#[Pure]
|
||||
function filectime (string $filename) {}
|
||||
function filectime (string $filename): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets file group
|
||||
|
@ -469,7 +484,8 @@ function filectime (string $filename) {}
|
|||
* Upon failure, false is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function filegroup (string $filename) {}
|
||||
function filegroup (string $filename): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets file inode
|
||||
|
@ -480,7 +496,8 @@ function filegroup (string $filename) {}
|
|||
* @return int|false the inode number of the file, or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function fileinode (string $filename) {}
|
||||
function fileinode (string $filename): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets file modification time
|
||||
|
@ -493,7 +510,8 @@ function fileinode (string $filename) {}
|
|||
* suitable for the date function.
|
||||
*/
|
||||
#[Pure]
|
||||
function filemtime (string $filename) {}
|
||||
function filemtime (string $filename): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets file owner
|
||||
|
@ -506,7 +524,8 @@ function filemtime (string $filename) {}
|
|||
* posix_getpwuid to resolve it to a username.
|
||||
*/
|
||||
#[Pure]
|
||||
function fileowner (string $filename) {}
|
||||
function fileowner (string $filename): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets file permissions
|
||||
|
@ -517,7 +536,8 @@ function fileowner (string $filename) {}
|
|||
* @return int|false the permissions on the file, or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function fileperms (string $filename) {}
|
||||
function fileperms (string $filename): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets file size
|
||||
|
@ -529,7 +549,8 @@ function fileperms (string $filename) {}
|
|||
* of level E_WARNING) in case of an error.
|
||||
*/
|
||||
#[Pure]
|
||||
function filesize (string $filename) {}
|
||||
function filesize (string $filename): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gets file type
|
||||
|
@ -546,7 +567,8 @@ function filesize (string $filename) {}
|
|||
* or if the file type is unknown.
|
||||
*/
|
||||
#[Pure]
|
||||
function filetype (string $filename) {}
|
||||
function filetype (string $filename): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks whether a file or directory exists
|
||||
|
@ -575,7 +597,8 @@ function filetype (string $filename) {}
|
|||
* The check is done using the real UID/GID instead of the effective one.
|
||||
*/
|
||||
#[Pure]
|
||||
function file_exists (string $filename) {}
|
||||
function file_exists (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tells whether the filename is writable
|
||||
|
@ -587,7 +610,8 @@ function file_exists (string $filename) {}
|
|||
* writable.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_writable (string $filename) {}
|
||||
function is_writable (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* &Alias; <function>is_writable</function>
|
||||
|
@ -599,7 +623,8 @@ function is_writable (string $filename) {}
|
|||
* writable.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_writeable (string $filename) {}
|
||||
function is_writeable (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tells whether a file or a directory exists and is readable
|
||||
|
@ -611,7 +636,8 @@ function is_writeable (string $filename) {}
|
|||
* filename exists and is readable, false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_readable (string $filename) {}
|
||||
function is_readable (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tells whether the filename is executable
|
||||
|
@ -623,7 +649,8 @@ function is_readable (string $filename) {}
|
|||
* error.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_executable (string $filename) {}
|
||||
function is_executable (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tells whether the filename is a regular file
|
||||
|
@ -635,7 +662,8 @@ function is_executable (string $filename) {}
|
|||
* otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_file (string $filename) {}
|
||||
function is_file (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tells whether the filename is a directory
|
||||
|
@ -650,7 +678,8 @@ function is_file (string $filename) {}
|
|||
* otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_dir (string $filename) {}
|
||||
function is_dir (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tells whether the filename is a symbolic link
|
||||
|
@ -662,7 +691,8 @@ function is_dir (string $filename) {}
|
|||
* otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function is_link (string $filename) {}
|
||||
function is_link (string $filename): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gives information about a file
|
||||
|
@ -754,7 +784,8 @@ function is_link (string $filename) {}
|
|||
* In case of error, stat returns false.
|
||||
*/
|
||||
#[Pure]
|
||||
function stat (string $filename) {}
|
||||
function stat (string $filename): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Gives information about a file or symbolic link
|
||||
|
@ -771,7 +802,8 @@ function stat (string $filename) {}
|
|||
* file pointed to by the symbolic link.
|
||||
*/
|
||||
#[Pure]
|
||||
function lstat (string $filename) {}
|
||||
function lstat (string $filename): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Changes file owner
|
||||
|
@ -784,7 +816,8 @@ function lstat (string $filename) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function chown (string $filename, string|int $user) {}
|
||||
function chown (string $filename, string|int $user): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Changes file group
|
||||
|
@ -797,7 +830,8 @@ function chown (string $filename, string|int $user) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function chgrp (string $filename, string|int $group) {}
|
||||
function chgrp (string $filename, string|int $group): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Changes user ownership of symlink
|
||||
|
@ -811,7 +845,8 @@ function chgrp (string $filename, string|int $group) {}
|
|||
* @return bool true on success or false on failure.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
function lchown (string $filename, string|int $user) {}
|
||||
function lchown (string $filename, string|int $user): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Changes group ownership of symlink
|
||||
|
@ -825,7 +860,8 @@ function lchown (string $filename, string|int $user) {}
|
|||
* @return bool true on success or false on failure.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
function lchgrp (string $filename, string|int $group) {}
|
||||
function lchgrp (string $filename, string|int $group): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Changes file mode
|
||||
|
@ -861,7 +897,8 @@ function lchgrp (string $filename, string|int $group) {}
|
|||
* <p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function chmod (string $filename, int $permissions) {}
|
||||
function chmod (string $filename, int $permissions): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sets access and modification time of file
|
||||
|
@ -880,7 +917,7 @@ function chmod (string $filename, int $permissions) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function touch (string $filename, int $mtime, int $atime)
|
||||
function touch (string $filename, int $mtime, int $atime): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -895,7 +932,7 @@ function touch (string $filename, int $mtime, int $atime)
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function clearstatcache (bool $clear_realpath_cache, string $filename) {}
|
||||
function clearstatcache (bool $clear_realpath_cache, string $filename): void {}
|
||||
|
||||
/**
|
||||
* Returns the total size of a filesystem or disk partition
|
||||
|
@ -906,7 +943,8 @@ function clearstatcache (bool $clear_realpath_cache, string $filename) {}
|
|||
* @return float|false the total number of bytes as a float
|
||||
* or false on failure.
|
||||
*/
|
||||
function disk_total_space (string $directory) {}
|
||||
function disk_total_space (string $directory): float|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns available space in directory
|
||||
|
@ -923,7 +961,8 @@ function disk_total_space (string $directory) {}
|
|||
* or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function disk_free_space (string $directory) {}
|
||||
function disk_free_space (string $directory): float|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Alias of {@see disk_free_space}
|
||||
|
@ -933,7 +972,8 @@ function disk_free_space (string $directory) {}
|
|||
* @return float|false
|
||||
*/
|
||||
#[Pure]
|
||||
function diskfreespace (string $directory) {}
|
||||
function diskfreespace (string $directory): float|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Send mail
|
||||
|
@ -1021,7 +1061,7 @@ function diskfreespace (string $directory) {}
|
|||
* It is important to note that just because the mail was accepted for delivery,
|
||||
* it does NOT mean the mail will actually reach the intended destination.
|
||||
*/
|
||||
function mail (string $to, string $subject, string $message, array|string $additional_headers, string $additional_params)
|
||||
function mail (string $to, string $subject, string $message, array|string $additional_headers, string $additional_params): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1034,7 +1074,8 @@ function mail (string $to, string $subject, string $message, array|string $addit
|
|||
* @removed 8.0
|
||||
*/
|
||||
#[Deprecated(since: '7.4')]
|
||||
function ezmlm_hash (string $addr) {}
|
||||
function ezmlm_hash (string $addr): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Open connection to system logger
|
||||
|
@ -1156,6 +1197,7 @@ function ezmlm_hash (string $addr) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openlog (string $prefix, int $flags, int $facility) {}
|
||||
function openlog (string $prefix, int $flags, int $facility): bool
|
||||
{}
|
||||
|
||||
?>
|
||||
|
|
|
@ -58,14 +58,16 @@ use JetBrains\PhpStorm\Pure;
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function syslog (int $priority, string $message) {}
|
||||
function syslog (int $priority, string $message): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Close connection to system logger
|
||||
* @link https://php.net/manual/en/function.closelog.php
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function closelog () {}
|
||||
function closelog (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Registers a function that will be called when PHP starts sending output.
|
||||
|
@ -75,7 +77,8 @@ function closelog () {}
|
|||
* @param callable $callback Function called just before the headers are sent.
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function header_register_callback ( callable $callback ) {}
|
||||
function header_register_callback ( callable $callback ): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the size of an image from a string.
|
||||
|
@ -97,7 +100,7 @@ function header_register_callback ( callable $callback ) {}
|
|||
* @link https://secure.php.net/manual/en/function.getimagesizefromstring.php
|
||||
* @since 5.4
|
||||
*/
|
||||
function getimagesizefromstring (string $string , &$image_info)
|
||||
function getimagesizefromstring (string $string , &$image_info): array|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -109,6 +112,7 @@ function getimagesizefromstring (string $string , &$image_info)
|
|||
* @link https://secure.php.net/manual/en/function.stream-set-chunk-size.php
|
||||
* @since 5.4
|
||||
*/
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function stream_set_chunk_size ($stream , int $size)
|
||||
{}
|
||||
|
||||
|
@ -126,7 +130,8 @@ function define_syslog_variables () {}
|
|||
* @link https://php.net/manual/en/function.lcg-value.php
|
||||
* @return float A pseudo random float value in the range of (0, 1)
|
||||
*/
|
||||
function lcg_value () {}
|
||||
function lcg_value (): float
|
||||
{}
|
||||
|
||||
/**
|
||||
* Calculate the metaphone key of a string
|
||||
|
@ -141,7 +146,9 @@ function lcg_value () {}
|
|||
* @return string|false the metaphone key as a string, or FALSE on failure
|
||||
*/
|
||||
#[Pure]
|
||||
function metaphone (string $string, int $max_phonemes = 0) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "string"], default: "string|false")]
|
||||
function metaphone (string $string, int $max_phonemes = 0): bool|string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Turn on output buffering
|
||||
|
@ -208,21 +215,22 @@ function metaphone (string $string, int $max_phonemes = 0) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function ob_start ($callback, int $chunk_size, int $flags = PHP_OUTPUT_HANDLER_STDFLAGS) {}
|
||||
function ob_start ($callback, int $chunk_size, int $flags = PHP_OUTPUT_HANDLER_STDFLAGS): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Flush (send) the output buffer
|
||||
* @link https://php.net/manual/en/function.ob-flush.php
|
||||
* @return void
|
||||
* @return bool
|
||||
*/
|
||||
function ob_flush () {}
|
||||
function ob_flush (): bool {}
|
||||
|
||||
/**
|
||||
* Clean (erase) the output buffer
|
||||
* @link https://php.net/manual/en/function.ob-clean.php
|
||||
* @return void
|
||||
* @return bool
|
||||
*/
|
||||
function ob_clean () {}
|
||||
function ob_clean (): bool {}
|
||||
|
||||
/**
|
||||
* Flush (send) the output buffer and turn off output buffering
|
||||
|
@ -231,7 +239,8 @@ function ob_clean () {}
|
|||
* function without an active buffer or that for some reason a buffer could
|
||||
* not be deleted (possible for special buffer).
|
||||
*/
|
||||
function ob_end_flush () {}
|
||||
function ob_end_flush (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Clean (erase) the output buffer and turn off output buffering
|
||||
|
@ -240,14 +249,16 @@ function ob_end_flush () {}
|
|||
* function without an active buffer or that for some reason a buffer could
|
||||
* not be deleted (possible for special buffer).
|
||||
*/
|
||||
function ob_end_clean () {}
|
||||
function ob_end_clean (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Flush the output buffer, return it as a string and turn off output buffering
|
||||
* @link https://php.net/manual/en/function.ob-get-flush.php
|
||||
* @return string|false the output buffer or false if no buffering is active.
|
||||
*/
|
||||
function ob_get_flush () {}
|
||||
function ob_get_flush (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get current buffer contents and delete current output buffer
|
||||
|
@ -255,7 +266,8 @@ function ob_get_flush () {}
|
|||
* @return string|false the contents of the output buffer and end output buffering.
|
||||
* If output buffering isn't active then false is returned.
|
||||
*/
|
||||
function ob_get_clean () {}
|
||||
function ob_get_clean (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the length of the output buffer
|
||||
|
@ -263,7 +275,8 @@ function ob_get_clean () {}
|
|||
* @return int|false the length of the output buffer contents or false if no
|
||||
* buffering is active.
|
||||
*/
|
||||
function ob_get_length () {}
|
||||
function ob_get_length (): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the nesting level of the output buffering mechanism
|
||||
|
@ -271,7 +284,8 @@ function ob_get_length () {}
|
|||
* @return int the level of nested output buffering handlers or zero if output
|
||||
* buffering is not active.
|
||||
*/
|
||||
function ob_get_level () {}
|
||||
function ob_get_level (): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get status of output buffers
|
||||
|
@ -342,7 +356,8 @@ function ob_get_level () {}
|
|||
* <tr><td>blocksize</td><td>...</td></tr>
|
||||
* </table>
|
||||
*/
|
||||
function ob_get_status (bool $full_status) {}
|
||||
function ob_get_status (bool $full_status): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Return the contents of the output buffer
|
||||
|
@ -350,7 +365,8 @@ function ob_get_status (bool $full_status) {}
|
|||
* @return string|false This will return the contents of the output buffer or false, if output
|
||||
* buffering isn't active.
|
||||
*/
|
||||
function ob_get_contents () {}
|
||||
function ob_get_contents (): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Turn implicit flush on/off
|
||||
|
@ -360,7 +376,7 @@ function ob_get_contents () {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function ob_implicit_flush (bool $enable = true) {}
|
||||
function ob_implicit_flush (bool $enable = true): void {}
|
||||
|
||||
/**
|
||||
* List all output handlers in use
|
||||
|
@ -371,7 +387,8 @@ function ob_implicit_flush (bool $enable = true) {}
|
|||
* ob_list_handlers will return "default output
|
||||
* handler".
|
||||
*/
|
||||
function ob_list_handlers () {}
|
||||
function ob_list_handlers (): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array by key
|
||||
|
@ -386,7 +403,8 @@ function ob_list_handlers () {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function ksort (array &$array, int $flags) {}
|
||||
function ksort (array &$array, int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array by key in reverse order
|
||||
|
@ -401,7 +419,8 @@ function ksort (array &$array, int $flags) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function krsort (array &$array, int $flags) {}
|
||||
function krsort (array &$array, int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array using a "natural order" algorithm
|
||||
|
@ -411,7 +430,8 @@ function krsort (array &$array, int $flags) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function natsort (array &$array) {}
|
||||
function natsort (array &$array): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array using a case insensitive "natural order" algorithm
|
||||
|
@ -421,7 +441,8 @@ function natsort (array &$array) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function natcasesort (array &$array) {}
|
||||
function natcasesort (array &$array): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array and maintain index association
|
||||
|
@ -436,7 +457,8 @@ function natcasesort (array &$array) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function asort (array &$array, int $flags) {}
|
||||
function asort (array &$array, int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array in reverse order and maintain index association
|
||||
|
@ -451,7 +473,8 @@ function asort (array &$array, int $flags) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function arsort (array &$array, int $flags) {}
|
||||
function arsort (array &$array, int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array
|
||||
|
@ -469,7 +492,8 @@ function arsort (array &$array, int $flags) {}
|
|||
* (don't change types)
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function sort (array &$array, int $flags) {}
|
||||
function sort (array &$array, int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array in reverse order
|
||||
|
@ -484,7 +508,8 @@ function sort (array &$array, int $flags) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function rsort (array &$array, int $flags) {}
|
||||
function rsort (array &$array, int $flags): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array by values using a user-defined comparison function
|
||||
|
@ -499,7 +524,8 @@ function rsort (array &$array, int $flags) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function usort (array &$array, callable $callback) {}
|
||||
function usort (array &$array, callable $callback): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array with a user-defined comparison function and maintain index association
|
||||
|
@ -513,7 +539,8 @@ function usort (array &$array, callable $callback) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function uasort (array &$array, callable $callback) {}
|
||||
function uasort (array &$array, callable $callback): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Sort an array by keys using a user-defined comparison function
|
||||
|
@ -534,7 +561,8 @@ function uasort (array &$array, callable $callback) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function uksort (array &$array, callable $callback) {}
|
||||
function uksort (array &$array, callable $callback): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Shuffle an array
|
||||
|
@ -544,7 +572,8 @@ function uksort (array &$array, callable $callback) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function shuffle (array &$array) {}
|
||||
function shuffle (array &$array): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Apply a user function to every member of an array
|
||||
|
@ -578,7 +607,7 @@ function shuffle (array &$array) {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function array_walk (object|array &$array, callable $callback, mixed $arg)
|
||||
function array_walk (object|array &$array, callable $callback, mixed $arg): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -607,7 +636,7 @@ function array_walk (object|array &$array, callable $callback, mixed $arg)
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function array_walk_recursive (object|array &$array, callable $callback, mixed $arg)
|
||||
function array_walk_recursive (object|array &$array, callable $callback, mixed $arg): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -638,7 +667,8 @@ function array_walk_recursive (object|array &$array, callable $callback, mixed $
|
|||
* empty array. Use isset to test if a variable is set.
|
||||
*/
|
||||
#[Pure]
|
||||
function count (Countable|array $value, int $mode = COUNT_NORMAL) {}
|
||||
function count (Countable|array $value, int $mode = COUNT_NORMAL): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set the internal pointer of an array to its last element
|
||||
|
@ -649,10 +679,10 @@ function count (Countable|array $value, int $mode = COUNT_NORMAL) {}
|
|||
* a function returning an array because only actual variables may be
|
||||
* passed by reference.
|
||||
* </p>
|
||||
* @return mixed|false the value of the last element or false for empty array.
|
||||
* @return mixed the value of the last element or false for empty array.
|
||||
* @meta
|
||||
*/
|
||||
function end (object|array &$array) {}
|
||||
function end (object|array &$array): mixed {}
|
||||
|
||||
/**
|
||||
* Rewind the internal array pointer
|
||||
|
@ -665,7 +695,7 @@ function end (object|array &$array) {}
|
|||
* elements.
|
||||
* @meta
|
||||
*/
|
||||
function prev (object|array &$array) {}
|
||||
function prev (object|array &$array): mixed {}
|
||||
|
||||
/**
|
||||
* Advance the internal array pointer of an array
|
||||
|
@ -677,7 +707,7 @@ function prev (object|array &$array) {}
|
|||
* internal array pointer, or false if there are no more elements.
|
||||
* @meta
|
||||
*/
|
||||
function next (object|array &$array) {}
|
||||
function next (object|array &$array): mixed {}
|
||||
|
||||
/**
|
||||
* Set the internal pointer of an array to its first element
|
||||
|
@ -685,11 +715,11 @@ function next (object|array &$array) {}
|
|||
* @param ArrayAccess|array &$array <p>
|
||||
* The input array.
|
||||
* </p>
|
||||
* @return mixed|false the value of the first array element, or false if the array is
|
||||
* @return mixed the value of the first array element, or false if the array is
|
||||
* empty.
|
||||
* @meta
|
||||
*/
|
||||
function reset (object|array &$array) {}
|
||||
function reset (object|array &$array): mixed {}
|
||||
|
||||
/**
|
||||
* Return the current element in an array
|
||||
|
@ -705,7 +735,7 @@ function reset (object|array &$array) {}
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function current (object|array $array) {}
|
||||
function current (object|array $array): mixed {}
|
||||
|
||||
/**
|
||||
* Fetch a key from an array
|
||||
|
@ -720,7 +750,8 @@ function current (object|array $array) {}
|
|||
* empty, key returns null.
|
||||
*/
|
||||
#[Pure]
|
||||
function key (object|array $array) {}
|
||||
function key (object|array $array): string|int|null
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find lowest value
|
||||
|
@ -731,7 +762,8 @@ function key (object|array $array) {}
|
|||
* parameter values.
|
||||
*/
|
||||
#[Pure]
|
||||
function min (mixed $value, mixed ...$values) {}
|
||||
function min (mixed $value, mixed ...$values): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Find highest value
|
||||
|
@ -742,7 +774,8 @@ function min (mixed $value, mixed ...$values) {}
|
|||
* parameter values, either within a arg array or two arguments.
|
||||
*/
|
||||
#[Pure]
|
||||
function max (mixed $value, mixed ...$values) {}
|
||||
function max (mixed $value, mixed ...$values): mixed
|
||||
{}
|
||||
|
||||
/**
|
||||
* Checks if a value exists in an array
|
||||
|
@ -767,7 +800,8 @@ function max (mixed $value, mixed ...$values) {}
|
|||
* false otherwise.
|
||||
*/
|
||||
#[Pure]
|
||||
function in_array (mixed $needle, array $haystack, bool $strict = false) {}
|
||||
function in_array (mixed $needle, array $haystack, bool $strict = false): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Searches the array for a given value and returns the first corresponding key if successful
|
||||
|
@ -798,7 +832,7 @@ function in_array (mixed $needle, array $haystack, bool $strict = false) {}
|
|||
* search_value parameter instead.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_search (mixed $needle, array $haystack, bool $strict)
|
||||
function array_search (mixed $needle, array $haystack, bool $strict): string|int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -827,7 +861,8 @@ function array_search (mixed $needle, array $haystack, bool $strict)
|
|||
* @return int the number of variables successfully imported into the symbol
|
||||
* table.
|
||||
*/
|
||||
function extract (array $array, int $flags, string $prefix) {}
|
||||
function extract (array $array, int $flags, string $prefix): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Create array containing variables and their values
|
||||
|
@ -843,7 +878,8 @@ function extract (array $array, int $flags, string $prefix) {}
|
|||
* @return array the output array with all the variables added to it.
|
||||
*/
|
||||
#[Pure]
|
||||
function compact (mixed $var_name, ...$var_names) {}
|
||||
function compact (mixed $var_name, ...$var_names): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Fill an array with values
|
||||
|
@ -861,7 +897,8 @@ function compact (mixed $var_name, ...$var_names) {}
|
|||
* @return array the filled array
|
||||
*/
|
||||
#[Pure]
|
||||
function array_fill (int $start_index, int $count, mixed $value) {}
|
||||
function array_fill (int $start_index, int $count, mixed $value): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Fill an array with values, specifying keys
|
||||
|
@ -876,7 +913,8 @@ function array_fill (int $start_index, int $count, mixed $value) {}
|
|||
* @return array the filled array
|
||||
*/
|
||||
#[Pure]
|
||||
function array_fill_keys (array $keys, mixed $value) {}
|
||||
function array_fill_keys (array $keys, mixed $value): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Create an array containing a range of elements
|
||||
|
@ -897,7 +935,7 @@ function array_fill_keys (array $keys, mixed $value) {}
|
|||
* end, inclusive.
|
||||
*/
|
||||
#[Pure]
|
||||
function range ($start, $end, int|float $step = 1)
|
||||
function range ($start, $end, int|float $step = 1): array
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -913,7 +951,8 @@ function range ($start, $end, int|float $step = 1)
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function array_multisort (&$array, &...$rest) {}
|
||||
function array_multisort (&$array, &...$rest): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Push elements onto the end of array
|
||||
|
@ -928,7 +967,8 @@ function array_multisort (&$array, &...$rest) {}
|
|||
* </p>
|
||||
* @return int the number of elements in the array.
|
||||
*/
|
||||
function array_push (array &$array, ...$values) {}
|
||||
function array_push (array &$array, ...$values): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Pop the element off the end of array
|
||||
|
@ -941,7 +981,7 @@ function array_push (array &$array, ...$values) {}
|
|||
* null will be returned.
|
||||
* @meta
|
||||
*/
|
||||
function array_pop (array &$array) {}
|
||||
function array_pop (array &$array): mixed {}
|
||||
|
||||
/**
|
||||
* Shift an element off the beginning of array
|
||||
|
@ -953,7 +993,7 @@ function array_pop (array &$array) {}
|
|||
* empty or is not an array.
|
||||
* @meta
|
||||
*/
|
||||
function array_shift (array &$array) {}
|
||||
function array_shift (array &$array): mixed {}
|
||||
|
||||
/**
|
||||
* Prepend elements to the beginning of an array
|
||||
|
@ -968,7 +1008,8 @@ function array_shift (array &$array) {}
|
|||
* </p>
|
||||
* @return int the number of elements in the array.
|
||||
*/
|
||||
function array_unshift (array &$array, ...$values) {}
|
||||
function array_unshift (array &$array, ...$values): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Remove a portion of the array and replace it with something else
|
||||
|
@ -1014,7 +1055,7 @@ function array_unshift (array &$array, ...$values) {}
|
|||
* </p>
|
||||
* @return array the array consisting of the extracted elements.
|
||||
*/
|
||||
function array_splice (array &$array, int $offset, int $length, mixed $replacement)
|
||||
function array_splice (array &$array, int $offset, int $length, mixed $replacement): array
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1047,7 +1088,7 @@ function array_splice (array &$array, int $offset, int $length, mixed $replaceme
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_slice (array $array, int $offset, int $length, bool $preserve_keys = false)
|
||||
function array_slice (array $array, int $offset, int $length, bool $preserve_keys = false): array
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -1059,4 +1100,5 @@ function array_slice (array $array, int $offset, int $length, bool $preserve_key
|
|||
* @return array the resulting array.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_merge (array ...$arrays) {}
|
||||
function array_merge (array ...$arrays): array
|
||||
{}
|
||||
|
|
|
@ -22,7 +22,8 @@ define ("ARRAY_FILTER_USE_KEY", 2);
|
|||
* @return array An array of values resulted from merging the arguments together.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_merge_recursive(array ...$arrays) { }
|
||||
function array_merge_recursive(array ...$arrays): array
|
||||
{ }
|
||||
|
||||
|
||||
/**
|
||||
|
@ -42,7 +43,8 @@ function array_merge_recursive(array ...$arrays) { }
|
|||
* @return array or null if an error occurs.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_replace(array $array, array ...$replacements) { }
|
||||
function array_replace(array $array, array ...$replacements): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Replaces elements from passed arrays into the first array recursively
|
||||
|
@ -56,7 +58,8 @@ function array_replace(array $array, array ...$replacements) { }
|
|||
* @return array|null an array, or null if an error occurs.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_replace_recursive(array $array, array ...$replacements) { }
|
||||
function array_replace_recursive(array $array, array ...$replacements): ?array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Return all the keys or a subset of the keys of an array
|
||||
|
@ -73,7 +76,8 @@ function array_replace_recursive(array $array, array ...$replacements) { }
|
|||
* @return array an array of all the keys in input.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_keys(array $array, mixed $filter_value, bool $strict) { }
|
||||
function array_keys(array $array, mixed $filter_value, bool $strict): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Return all the values of an array
|
||||
|
@ -85,7 +89,7 @@ function array_keys(array $array, mixed $filter_value, bool $strict) { }
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_values(array $array) { }
|
||||
function array_values(array $array): array { }
|
||||
|
||||
/**
|
||||
* Counts all the values of an array
|
||||
|
@ -97,7 +101,8 @@ function array_values(array $array) { }
|
|||
* keys and their count as value.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_count_values(array $array) { }
|
||||
function array_count_values(array $array): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -110,7 +115,8 @@ function array_count_values(array $array) { }
|
|||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function array_column(array $array, string|int|null $column_key, string|int $index_key = null) { }
|
||||
function array_column(array $array, string|int|null $column_key, string|int $index_key = null): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Return an array with elements in reverse order
|
||||
|
@ -125,7 +131,7 @@ function array_column(array $array, string|int|null $column_key, string|int $ind
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_reverse(array $array, bool $preserve_keys) { }
|
||||
function array_reverse(array $array, bool $preserve_keys): array { }
|
||||
|
||||
/**
|
||||
* Iteratively reduce the array to a single value using a callback function
|
||||
|
@ -157,7 +163,7 @@ function array_reverse(array $array, bool $preserve_keys) { }
|
|||
* <br/>
|
||||
* @meta
|
||||
*/
|
||||
function array_reduce(array $array, callable $callback, mixed $initial) { }
|
||||
function array_reduce(array $array, callable $callback, mixed $initial): mixed { }
|
||||
|
||||
/**
|
||||
* Pad array to the specified length with a value
|
||||
|
@ -180,7 +186,8 @@ function array_reduce(array $array, callable $callback, mixed $initial) { }
|
|||
* the length of the input then no padding takes place.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_pad(array $array, int $length, mixed $value) { }
|
||||
function array_pad(array $array, int $length, mixed $value): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Exchanges all keys with their associated values in an array
|
||||
|
@ -191,7 +198,8 @@ function array_pad(array $array, int $length, mixed $value) { }
|
|||
* @return array Returns the flipped array.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_flip(array $array) { }
|
||||
function array_flip(array $array): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Changes the case of all keys in an arra
|
||||
|
@ -207,7 +215,7 @@ function array_flip(array $array) { }
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_change_key_case(array $array, int $case) { }
|
||||
function array_change_key_case(array $array, int $case): array { }
|
||||
|
||||
/**
|
||||
* Pick one or more random keys out of an array
|
||||
|
@ -224,7 +232,8 @@ function array_change_key_case(array $array, int $case) { }
|
|||
* random keys as well as values out of the array.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_rand(array $array, int $num) { }
|
||||
function array_rand(array $array, int $num): array|string|int
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Removes duplicate values from an array
|
||||
|
@ -258,7 +267,7 @@ function array_rand(array $array, int $num) { }
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_unique(array $array, int $flags = SORT_STRING) { }
|
||||
function array_unique(array $array, int $flags = SORT_STRING): array { }
|
||||
|
||||
#[PhpStormStubsElementAvailable('8.0')]
|
||||
/**
|
||||
|
@ -275,7 +284,7 @@ function array_unique(array $array, int $flags = SORT_STRING) { }
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_intersect(array $array, ...$arrays) { }
|
||||
function array_intersect(array $array, ...$arrays): array { }
|
||||
|
||||
#[PhpStormStubsElementAvailable(to: '7.4')]
|
||||
/**
|
||||
|
@ -293,7 +302,7 @@ function array_intersect(array $array, ...$arrays) { }
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_intersect(array $array1, array $array2, array ...$_) { }
|
||||
function array_intersect(array $array1, array $array2, array ...$_): array { }
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays using keys for comparison
|
||||
|
@ -311,7 +320,7 @@ function array_intersect(array $array1, array $array2, array ...$_) { }
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_intersect_key(array $array1, array $array2, array ...$_) { }
|
||||
function array_intersect_key(array $array1, array $array2, array ...$_): array { }
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays using a callback function on the keys for comparison
|
||||
|
@ -330,7 +339,7 @@ function array_intersect_key(array $array1, array $array2, array ...$_) { }
|
|||
* in all the arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_intersect_ukey(array $array1, array $array2, array $_ = null, callable $key_compare_func) { }
|
||||
function array_intersect_ukey(array $array1, array $array2, array $_ = null, callable $key_compare_func): array { }
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays, compares data by a callback function
|
||||
|
@ -355,7 +364,7 @@ function array_intersect_ukey(array $array1, array $array2, array $_ = null, cal
|
|||
* that are present in all the arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_uintersect(array $array1, array $array2, array $_ = null, callable $data_compare_func) { }
|
||||
function array_uintersect(array $array1, array $array2, array $_ = null, callable $data_compare_func): array { }
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays with additional index check
|
||||
|
@ -372,7 +381,7 @@ function array_uintersect(array $array1, array $array2, array $_ = null, callabl
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_intersect_assoc(array $array1, array $array2, array $_ = null) { }
|
||||
function array_intersect_assoc(array $array1, array $array2, array $_ = null): array { }
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays with additional index check, compares data by a callback function
|
||||
|
@ -395,7 +404,7 @@ function array_intersect_assoc(array $array1, array $array2, array $_ = null) {
|
|||
* array1 that are present in all the arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_uintersect_assoc(array $array1, array $array2, array $_ = null, callable $data_compare_func) { }
|
||||
function array_uintersect_assoc(array $array1, array $array2, array $_ = null, callable $data_compare_func): array { }
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays with additional index check, compares indexes by a callback function
|
||||
|
@ -414,7 +423,7 @@ function array_uintersect_assoc(array $array1, array $array2, array $_ = null, c
|
|||
* in all of the arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_intersect_uassoc(array $array1, array $array2, array $_ = null, callable $key_compare_func) { }
|
||||
function array_intersect_uassoc(array $array1, array $array2, array $_ = null, callable $key_compare_func): array { }
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays with additional index check, compares data and indexes by separate callback functions
|
||||
|
@ -441,7 +450,7 @@ function array_intersect_uassoc(array $array1, array $array2, array $_ = null, c
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_uintersect_uassoc(array $array1, array $array2, array $_ = null, callable $data_compare_func, callable $key_compare_func) { }
|
||||
function array_uintersect_uassoc(array $array1, array $array2, array $_ = null, callable $data_compare_func, callable $key_compare_func): array { }
|
||||
|
||||
#[PhpStormStubsElementAvailable('8.0')]
|
||||
/**
|
||||
|
@ -457,7 +466,7 @@ function array_uintersect_uassoc(array $array1, array $array2, array $_ = null,
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_diff(array $array, ...$excludes) { }
|
||||
function array_diff(array $array, ...$excludes): array { }
|
||||
|
||||
#[PhpStormStubsElementAvailable(to: '7.4')]
|
||||
/**
|
||||
|
@ -475,7 +484,7 @@ function array_diff(array $array, ...$excludes) { }
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_diff(array $array1, array $array2, array ...$_) { }
|
||||
function array_diff(array $array1, array $array2, array ...$_): array { }
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays using keys for comparison
|
||||
|
@ -493,7 +502,7 @@ function array_diff(array $array1, array $array2, array ...$_) { }
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_diff_key(array $array1, array $array2, array ...$_) { }
|
||||
function array_diff_key(array $array1, array $array2, array ...$_): array { }
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays using a callback function on the keys for comparison
|
||||
|
@ -515,7 +524,7 @@ function array_diff_key(array $array1, array $array2, array ...$_) { }
|
|||
* array1 that are not present in any of the other arrays.
|
||||
* @meta
|
||||
*/
|
||||
function array_diff_ukey(array $array1, array $array2, array $_ = null, callable $key_compare_func) { }
|
||||
function array_diff_ukey(array $array1, array $array2, array $_ = null, callable $key_compare_func): array { }
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays by using a callback function for data comparison
|
||||
|
@ -540,7 +549,7 @@ function array_diff_ukey(array $array1, array $array2, array $_ = null, callable
|
|||
* that are not present in any of the other arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_udiff(array $array1, array $array2, array $_ = null, callable $data_compare_func) { }
|
||||
function array_udiff(array $array1, array $array2, array $_ = null, callable $data_compare_func): array { }
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays with additional index check
|
||||
|
@ -557,7 +566,7 @@ function array_udiff(array $array1, array $array2, array $_ = null, callable $da
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_diff_assoc(array $array1, array $array2, array ...$_) { }
|
||||
function array_diff_assoc(array $array1, array $array2, array ...$_): array { }
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays with additional index check, compares data by a callback function
|
||||
|
@ -589,7 +598,7 @@ function array_diff_assoc(array $array1, array $array2, array ...$_) { }
|
|||
* comparison.
|
||||
* @meta
|
||||
*/
|
||||
function array_udiff_assoc(array $array1, array $array2, array $_ = null, callable $data_compare_func) { }
|
||||
function array_udiff_assoc(array $array1, array $array2, array $_ = null, callable $data_compare_func): array { }
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays with additional index check which is performed by a user supplied callback function
|
||||
|
@ -611,7 +620,7 @@ function array_udiff_assoc(array $array1, array $array2, array $_ = null, callab
|
|||
* array1 that are not present in any of the other arrays.
|
||||
* @meta
|
||||
*/
|
||||
function array_diff_uassoc(array $array1, array $array2, array $_ = null, callable $key_compare_func) { }
|
||||
function array_diff_uassoc(array $array1, array $array2, array $_ = null, callable $key_compare_func): array { }
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays with additional index check, compares data and indexes by a callback function
|
||||
|
@ -650,7 +659,7 @@ function array_diff_uassoc(array $array1, array $array2, array $_ = null, callab
|
|||
* arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_udiff_uassoc(array $array1, array $array2, array $_ = null, callable $data_compare_func, callable $key_compare_func) { }
|
||||
function array_udiff_uassoc(array $array1, array $array2, array $_ = null, callable $data_compare_func, callable $key_compare_func): array { }
|
||||
|
||||
/**
|
||||
* Calculate the sum of values in an array
|
||||
|
@ -661,7 +670,8 @@ function array_udiff_uassoc(array $array1, array $array2, array $_ = null, calla
|
|||
* @return int|float the sum of values as an integer or float.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_sum(array $array) { }
|
||||
function array_sum(array $array): int|float
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Calculate the product of values in an array
|
||||
|
@ -672,7 +682,8 @@ function array_sum(array $array) { }
|
|||
* @return int|float the product as an integer or float.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_product(array $array) { }
|
||||
function array_product(array $array): int|float
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Iterates over each value in the <b>array</b>
|
||||
|
@ -708,7 +719,7 @@ function array_product(array $array) { }
|
|||
* @return array the filtered array.
|
||||
* @meta
|
||||
*/
|
||||
function array_filter(array $array, callable $callback, int $mode = 0) { }
|
||||
function array_filter(array $array, callable $callback, int $mode = 0): array { }
|
||||
|
||||
/**
|
||||
* Applies the callback to the elements of the given arrays
|
||||
|
@ -724,7 +735,7 @@ function array_filter(array $array, callable $callback, int $mode = 0) { }
|
|||
* after applying the callback function to each one.
|
||||
* @meta
|
||||
*/
|
||||
function array_map(callable $callback, array $array, array ...$arrays) { }
|
||||
function array_map(callable $callback, array $array, array ...$arrays): array { }
|
||||
|
||||
/**
|
||||
* Split an array into chunks
|
||||
|
@ -743,7 +754,7 @@ function array_map(callable $callback, array $array, array ...$arrays) { }
|
|||
* with each dimension containing size elements.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_chunk(array $array, int $length, bool $preserve_keys)
|
||||
function array_chunk(array $array, int $length, bool $preserve_keys): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
|
@ -761,7 +772,7 @@ function array_chunk(array $array, int $length, bool $preserve_keys)
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_combine(array $keys, array $values) { }
|
||||
function array_combine(array $keys, array $values): array { }
|
||||
|
||||
/**
|
||||
* Checks if the given key or index exists in the array
|
||||
|
@ -775,7 +786,7 @@ function array_combine(array $keys, array $values) { }
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_key_exists($key, array $array)
|
||||
function array_key_exists($key, array $array): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
|
@ -789,7 +800,8 @@ function array_key_exists($key, array $array)
|
|||
* @since 7.3
|
||||
*/
|
||||
#[Pure]
|
||||
function array_key_first(array $array) { }
|
||||
function array_key_first(array $array): string|int|null
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Gets the last key of an array
|
||||
|
@ -802,7 +814,8 @@ function array_key_first(array $array) { }
|
|||
* @since 7.3
|
||||
*/
|
||||
#[Pure]
|
||||
function array_key_last(array $array) { }
|
||||
function array_key_last(array $array): string|int|null
|
||||
{ }
|
||||
|
||||
/**
|
||||
* &Alias; <function>current</function>
|
||||
|
@ -811,7 +824,8 @@ function array_key_last(array $array) { }
|
|||
* @return mixed
|
||||
*/
|
||||
#[Pure]
|
||||
function pos(object|array $array) { }
|
||||
function pos(object|array $array): mixed
|
||||
{ }
|
||||
|
||||
/**
|
||||
* &Alias; <function>count</function>
|
||||
|
@ -821,7 +835,8 @@ function pos(object|array $array) { }
|
|||
* @return int
|
||||
*/
|
||||
#[Pure]
|
||||
function sizeof(Countable|array $value, int $mode = COUNT_NORMAL) { }
|
||||
function sizeof(Countable|array $value, int $mode = COUNT_NORMAL): int
|
||||
{ }
|
||||
|
||||
/**
|
||||
* 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.
|
||||
|
@ -835,7 +850,8 @@ function sizeof(Countable|array $value, int $mode = COUNT_NORMAL) { }
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function key_exists($key, array $array) { }
|
||||
function key_exists($key, array $array): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Checks if assertion is &false;
|
||||
|
@ -851,7 +867,8 @@ function key_exists($key, array $array) { }
|
|||
* <p>An optional description that will be included in the failure message if the assertion fails.</p>
|
||||
* @return bool false if the assertion is false, true otherwise.
|
||||
*/
|
||||
function assert(mixed $assertion, $description = '') { }
|
||||
function assert(mixed $assertion, $description = ''): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* AssertionError is thrown when an assertion made via {@see assert()} fails.
|
||||
|
@ -912,9 +929,10 @@ class AssertionError extends Error {
|
|||
* @param mixed $value [optional] <p>
|
||||
* An optional new value for the option.
|
||||
* </p>
|
||||
* @return mixed|false the original setting of any option or false on errors.
|
||||
* @return object|array|string|int|null the original setting of any option or false on errors.
|
||||
*/
|
||||
function assert_options(int $option, mixed $value) { }
|
||||
function assert_options(int $option, mixed $value): object|array|string|int|null
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Compares two "PHP-standardized" version number strings
|
||||
|
@ -950,7 +968,7 @@ function assert_options(int $option, mixed $value) { }
|
|||
* function will return true if the relationship is the one specified
|
||||
* by the operator, false otherwise.
|
||||
*/
|
||||
function version_compare(string $version1, string $version2, string $operator)
|
||||
function version_compare(string $version1, string $version2, string $operator): int|bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
|
@ -966,7 +984,8 @@ function version_compare(string $version1, string $version2, string $operator)
|
|||
* -1 is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function ftok(string $filename, string $project_id) { }
|
||||
function ftok(string $filename, string $project_id): int
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Perform the rot13 transform on a string
|
||||
|
@ -977,7 +996,8 @@ function ftok(string $filename, string $project_id) { }
|
|||
* @return string the ROT13 version of the given string.
|
||||
*/
|
||||
#[Pure]
|
||||
function str_rot13(string $string) { }
|
||||
function str_rot13(string $string): string
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Retrieve list of registered filters
|
||||
|
@ -986,7 +1006,8 @@ function str_rot13(string $string) { }
|
|||
* available.
|
||||
*/
|
||||
#[Pure]
|
||||
function stream_get_filters() { }
|
||||
function stream_get_filters(): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Check if a stream is a TTY
|
||||
|
@ -996,7 +1017,8 @@ function stream_get_filters() { }
|
|||
* @since 7.2
|
||||
*/
|
||||
#[Pure]
|
||||
function stream_isatty($stream) {}
|
||||
function stream_isatty($stream): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Register a user defined stream filter
|
||||
|
@ -1112,7 +1134,8 @@ function stream_isatty($stream) {}
|
|||
* stream_filter_register will return false if the
|
||||
* filtername is already defined.
|
||||
*/
|
||||
function stream_filter_register(string $filter_name, string $class) { }
|
||||
function stream_filter_register(string $filter_name, string $class): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Return a bucket object from the brigade for operating on
|
||||
|
@ -1120,7 +1143,8 @@ function stream_filter_register(string $filter_name, string $class) { }
|
|||
* @param resource $brigade
|
||||
* @return object
|
||||
*/
|
||||
function stream_bucket_make_writeable($brigade) { }
|
||||
function stream_bucket_make_writeable($brigade): object
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Prepend bucket to brigade
|
||||
|
@ -1129,7 +1153,7 @@ function stream_bucket_make_writeable($brigade) { }
|
|||
* @param object $bucket
|
||||
* @return void
|
||||
*/
|
||||
function stream_bucket_prepend($brigade, object $bucket) { }
|
||||
function stream_bucket_prepend($brigade, object $bucket): void { }
|
||||
|
||||
/**
|
||||
* Append bucket to brigade
|
||||
|
@ -1138,7 +1162,7 @@ function stream_bucket_prepend($brigade, object $bucket) { }
|
|||
* @param object $bucket
|
||||
* @return void
|
||||
*/
|
||||
function stream_bucket_append($brigade, object $bucket) { }
|
||||
function stream_bucket_append($brigade, object $bucket): void { }
|
||||
|
||||
/**
|
||||
* Create a new bucket for use on the current stream
|
||||
|
@ -1147,7 +1171,8 @@ function stream_bucket_append($brigade, object $bucket) { }
|
|||
* @param string $buffer
|
||||
* @return object
|
||||
*/
|
||||
function stream_bucket_new($stream, string $buffer) { }
|
||||
function stream_bucket_new($stream, string $buffer): object
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Add URL rewriter values
|
||||
|
@ -1160,7 +1185,8 @@ function stream_bucket_new($stream, string $buffer) { }
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function output_add_rewrite_var(string $name, string $value) { }
|
||||
function output_add_rewrite_var(string $name, string $value): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Reset URL rewriter values
|
||||
|
@ -1191,7 +1217,8 @@ function output_add_rewrite_var(string $name, string $value) { }
|
|||
* @link https://php.net/manual/en/function.output-reset-rewrite-vars.php
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function output_reset_rewrite_vars() { }
|
||||
function output_reset_rewrite_vars(): bool
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Returns directory path used for temporary files
|
||||
|
@ -1199,7 +1226,8 @@ function output_reset_rewrite_vars() { }
|
|||
* @return string the path of the temporary directory.
|
||||
* @since 5.2.1
|
||||
*/
|
||||
function sys_get_temp_dir() { }
|
||||
function sys_get_temp_dir(): string
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Get the contents of the realpath cache.
|
||||
|
@ -1211,7 +1239,8 @@ function sys_get_temp_dir() { }
|
|||
* @since 5.3.2
|
||||
*/
|
||||
#[Pure]
|
||||
function realpath_cache_get() { }
|
||||
function realpath_cache_get(): array
|
||||
{ }
|
||||
|
||||
/**
|
||||
* Get the amount of memory used by the realpath cache.
|
||||
|
@ -1220,7 +1249,8 @@ function realpath_cache_get() { }
|
|||
* @since 5.3.2
|
||||
*/
|
||||
#[Pure]
|
||||
function realpath_cache_size() { }
|
||||
function realpath_cache_size(): int
|
||||
{ }
|
||||
|
||||
/**
|
||||
* It returns the same result as (array) $object, with the
|
||||
|
@ -1230,7 +1260,8 @@ function realpath_cache_size() { }
|
|||
* @return array returns the mangled object properties
|
||||
* @since 7.4
|
||||
*/
|
||||
function get_mangled_object_vars(object $object){}
|
||||
function get_mangled_object_vars(object $object): array
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get the type or object name of a variable
|
||||
|
|
|
@ -12,8 +12,9 @@
|
|||
* Queue permissions. Default to 0666. If the message queue already
|
||||
* exists, the <i>perms</i> will be ignored.
|
||||
* </p>
|
||||
* @return resource|SysvMessageQueue a resource handle that can be used to access the System V message queue.
|
||||
* @return resource|SysvMessageQueue|false a resource handle that can be used to access the System V message queue.
|
||||
*/
|
||||
#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue|false"], default: "resource|false")]
|
||||
function msg_get_queue (int $key, int $permissions = 0666) {}
|
||||
|
||||
/**
|
||||
|
@ -52,7 +53,7 @@ function msg_get_queue (int $key, int $permissions = 0666) {}
|
|||
* calling process, <i>msg_qnum</i> is incremented by 1 and
|
||||
* <i>msg_stime</i> is set to the current time.
|
||||
*/
|
||||
function msg_send (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue, int $message_type, $message, bool $serialize = true, bool $blocking = true, &$error_code) {}
|
||||
function msg_send (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue, int $message_type, $message, bool $serialize = true, bool $blocking = true, &$error_code): bool {}
|
||||
|
||||
/**
|
||||
* Receive a message from a message queue
|
||||
|
@ -139,7 +140,7 @@ function msg_send (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], defau
|
|||
* calling process, msg_qnum is decremented by 1 and
|
||||
* msg_rtime is set to the current time.
|
||||
*/
|
||||
function msg_receive (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue, int $desired_message_type, &$received_message_type, int $max_message_size, mixed &$message, bool $unserialize = true, int $flags = 0, &$error_code) {}
|
||||
function msg_receive (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue, int $desired_message_type, &$received_message_type, int $max_message_size, mixed &$message, bool $unserialize = true, int $flags = 0, &$error_code): bool {}
|
||||
|
||||
/**
|
||||
* Destroy a message queue
|
||||
|
@ -149,7 +150,7 @@ function msg_receive (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], de
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function msg_remove_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue) {}
|
||||
function msg_remove_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue): bool {}
|
||||
|
||||
/**
|
||||
* Returns information from the message queue data structure
|
||||
|
@ -157,7 +158,7 @@ function msg_remove_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"
|
|||
* @param SysvMessageQueue|resource $queue <p>
|
||||
* Message queue resource handle
|
||||
* </p>
|
||||
* @return array The return value is an array whose keys and values have the following
|
||||
* @return array|false The return value is an array whose keys and values have the following
|
||||
* meanings:
|
||||
* <table>
|
||||
* Array structure for msg_stat_queue
|
||||
|
@ -225,7 +226,7 @@ function msg_remove_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"
|
|||
* </tr>
|
||||
* </table>
|
||||
*/
|
||||
function msg_stat_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue) {}
|
||||
function msg_stat_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue): array|false {}
|
||||
|
||||
/**
|
||||
* Set information in the message queue data structure
|
||||
|
@ -239,7 +240,7 @@ function msg_stat_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"],
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function msg_set_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue, array $data) {}
|
||||
function msg_set_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"], default: "resource")] $queue, array $data): bool {}
|
||||
|
||||
/**
|
||||
* Check whether a message queue exists
|
||||
|
@ -249,7 +250,7 @@ function msg_set_queue (#[LanguageLevelTypeAware(["8.0" => "SysvMessageQueue"],
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function msg_queue_exists (int $key) {}
|
||||
function msg_queue_exists (int $key): bool {}
|
||||
|
||||
define ('MSG_IPC_NOWAIT', 1);
|
||||
define ('MSG_EAGAIN', 11);
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
* @return resource|false|SysvSemaphore a positive semaphore identifier on success, or <b>FALSE</b> on
|
||||
* error.
|
||||
*/
|
||||
#[LanguageLevelTypeAware(["8.0" => "SysvSemaphore|false"], default: "resource|false")]
|
||||
function sem_get (int $key, int $max_acquire = 1, int $permissions = 0666, bool $auto_release) {}
|
||||
|
||||
/**
|
||||
|
@ -38,7 +39,7 @@ function sem_get (int $key, int $max_acquire = 1, int $permissions = 0666, bool
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function sem_acquire (#[LanguageLevelTypeAware(["8.0" => "SysvSemaphore"], default: "resource")] $semaphore, bool $non_blocking = false) {}
|
||||
function sem_acquire (#[LanguageLevelTypeAware(["8.0" => "SysvSemaphore"], default: "resource")] $semaphore, bool $non_blocking = false): bool {}
|
||||
|
||||
/**
|
||||
* Release a semaphore
|
||||
|
@ -49,7 +50,7 @@ function sem_acquire (#[LanguageLevelTypeAware(["8.0" => "SysvSemaphore"], defau
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function sem_release (#[LanguageLevelTypeAware(["8.0" => "SysvSemaphore"], default: "resource")] $semaphore) {}
|
||||
function sem_release (#[LanguageLevelTypeAware(["8.0" => "SysvSemaphore"], default: "resource")] $semaphore): bool {}
|
||||
|
||||
/**
|
||||
* Remove a semaphore
|
||||
|
@ -60,7 +61,7 @@ function sem_release (#[LanguageLevelTypeAware(["8.0" => "SysvSemaphore"], defau
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function sem_remove (#[LanguageLevelTypeAware(["8.0" => "SysvSemaphore"], default: "resource")] $semaphore) {}
|
||||
function sem_remove (#[LanguageLevelTypeAware(["8.0" => "SysvSemaphore"], default: "resource")] $semaphore): bool {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
|
|
|
@ -16,8 +16,9 @@
|
|||
* @param int $permissions [optional] <p>
|
||||
* The optional permission bits. Default to 0666.
|
||||
* </p>
|
||||
* @return resource|SysvSharedMemory a shared memory segment identifier.
|
||||
* @return resource|SysvSharedMemory|false a shared memory segment identifier.
|
||||
*/
|
||||
#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory|false"], default: "resource|false")]
|
||||
function shm_attach (int $key, int $size, int $permissions = 0666) {}
|
||||
|
||||
/**
|
||||
|
@ -29,7 +30,7 @@ function shm_attach (int $key, int $size, int $permissions = 0666) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function shm_remove (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm) {}
|
||||
function shm_remove (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm): bool {}
|
||||
|
||||
/**
|
||||
* Disconnects from shared memory segment
|
||||
|
@ -40,7 +41,7 @@ function shm_remove (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], def
|
|||
* </p>
|
||||
* @return bool <b>shm_detach</b> always returns <b>TRUE</b>.
|
||||
*/
|
||||
function shm_detach (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm) {}
|
||||
function shm_detach (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm): bool {}
|
||||
|
||||
/**
|
||||
* Inserts or updates a variable in shared memory
|
||||
|
@ -60,7 +61,7 @@ function shm_detach (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], def
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function shm_put_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm, int $key, mixed $value) {}
|
||||
function shm_put_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm, int $key, mixed $value): bool {}
|
||||
|
||||
/**
|
||||
* Check whether a specific entry exists
|
||||
|
@ -73,7 +74,7 @@ function shm_put_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], de
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> if the entry exists, otherwise <b>FALSE</b>
|
||||
*/
|
||||
function shm_has_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm, int $key) {}
|
||||
function shm_has_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm, int $key): bool {}
|
||||
|
||||
/**
|
||||
* Returns a variable from shared memory
|
||||
|
@ -86,7 +87,7 @@ function shm_has_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], de
|
|||
* </p>
|
||||
* @return mixed the variable with the given key.
|
||||
*/
|
||||
function shm_get_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm, int $key) {}
|
||||
function shm_get_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm, int $key): mixed {}
|
||||
|
||||
/**
|
||||
* Removes a variable from shared memory
|
||||
|
@ -100,7 +101,7 @@ function shm_get_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], de
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function shm_remove_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm, int $key) {}
|
||||
function shm_remove_var (#[LanguageLevelTypeAware(["8.0" => "SysvSharedMemory"], default: "resource")] $shm, int $key): bool {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
|
|
|
@ -5,6 +5,15 @@ namespace StubTests\Model;
|
|||
|
||||
use Exception;
|
||||
use PhpParser\Node;
|
||||
use PhpParser\Node\Expr\Array_;
|
||||
use PhpParser\Node\Identifier;
|
||||
use PhpParser\Node\Name;
|
||||
use PhpParser\Node\NullableType;
|
||||
use PhpParser\Node\Scalar\String_;
|
||||
use PhpParser\Node\UnionType;
|
||||
use ReflectionNamedType;
|
||||
use ReflectionType;
|
||||
use ReflectionUnionType;
|
||||
use Reflector;
|
||||
use stdClass;
|
||||
|
||||
|
@ -35,6 +44,69 @@ abstract class BasePHPElement
|
|||
return rtrim($fqn, "\\");
|
||||
}
|
||||
|
||||
protected static function convertReflectionTypeToString(?ReflectionType $type): string
|
||||
{
|
||||
if ($type instanceof ReflectionNamedType) {
|
||||
return $type->getName();
|
||||
}
|
||||
if ($type instanceof ReflectionUnionType) {
|
||||
$reflectionType = '';
|
||||
foreach ($type->getTypes() as $type) {
|
||||
$reflectionType .= $type->getName() . '|';
|
||||
}
|
||||
return substr($reflectionType, 0, -1);
|
||||
}
|
||||
return '';
|
||||
}
|
||||
|
||||
protected static function convertParsedTypeToString(Name|Identifier|NullableType|string|UnionType|null $type): string
|
||||
{
|
||||
if ($type !== null) {
|
||||
if ($type instanceof UnionType) {
|
||||
$unionType = '';
|
||||
foreach ($type->types as $type) {
|
||||
$unionType .= self::getTypeNameFromNode($type) . '|';
|
||||
}
|
||||
return substr($unionType, 0, -1);
|
||||
} else {
|
||||
return self::getTypeNameFromNode($type);
|
||||
}
|
||||
}
|
||||
return '';
|
||||
}
|
||||
|
||||
protected static function getTypeNameFromNode(Name|Identifier|NullableType|string $type): string
|
||||
{
|
||||
if($type instanceof NullableType){
|
||||
$type = $type->type;
|
||||
}
|
||||
if (empty($type->name)) {
|
||||
if (!empty($type->parts)) {
|
||||
return $type->parts[0];
|
||||
}
|
||||
} else {
|
||||
return $type->name;
|
||||
}
|
||||
}
|
||||
|
||||
protected static function findTypeFromAttribute(array $attrGroups): ?string
|
||||
{
|
||||
foreach ($attrGroups as $attrGroup) {
|
||||
foreach ($attrGroup->attrs as $attr) {
|
||||
if ($attr->name->toString() === "LanguageLevelTypeAware") {
|
||||
$arg = $attr->args[0]->value;
|
||||
if ($arg instanceof Array_) {
|
||||
$value = $arg->items[0]->value;
|
||||
if ($value instanceof String_) {
|
||||
return $value->value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public function hasMutedProblem(int $stubProblemType): bool
|
||||
{
|
||||
return in_array($stubProblemType, $this->mutedProblems, true);
|
||||
|
|
|
@ -27,7 +27,7 @@ class PHPFunction extends BasePHPElement
|
|||
|
||||
public ?Type $returnTag = null;
|
||||
|
||||
public ?NodeAbstract $returnType = null;
|
||||
public string $returnType = '';
|
||||
|
||||
public ?Doc $doc = null;
|
||||
|
||||
|
@ -42,6 +42,7 @@ class PHPFunction extends BasePHPElement
|
|||
foreach ($reflectionObject->getParameters() as $parameter) {
|
||||
$this->parameters[] = (new PHPParameter())->readObjectFromReflection($parameter);
|
||||
}
|
||||
$this->returnType = self::convertReflectionTypeToString($reflectionObject->getReturnType());
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
@ -53,12 +54,17 @@ class PHPFunction extends BasePHPElement
|
|||
{
|
||||
$functionName = $this->getFQN($node);
|
||||
$this->name = $functionName;
|
||||
$typeFromAttribute = self::findTypeFromAttribute($node->attrGroups);
|
||||
if ($typeFromAttribute != null) {
|
||||
$this->returnType = $typeFromAttribute;
|
||||
} else{
|
||||
$this->returnType = self::convertParsedTypeToString($node->getReturnType());
|
||||
}
|
||||
|
||||
foreach ($node->getParams() as $parameter) {
|
||||
$this->parameters[] = (new PHPParameter())->readObjectFromStubNode($parameter);
|
||||
}
|
||||
|
||||
$this->returnType = $node->getReturnType();
|
||||
$this->collectTags($node);
|
||||
$this->checkDeprecationTag($node);
|
||||
$this->checkReturnTag($node);
|
||||
|
|
|
@ -47,7 +47,7 @@ class PHPMethod extends PHPFunction
|
|||
$this->parentName = $this->getFQN($node->getAttribute('parent'));
|
||||
$this->name = $node->name->name;
|
||||
|
||||
$this->returnType = $node->getReturnType();
|
||||
$this->returnType = self::convertParsedTypeToString($node->getReturnType());
|
||||
$this->collectTags($node);
|
||||
$this->checkDeprecationTag($node);
|
||||
$this->checkReturnTag($node);
|
||||
|
|
|
@ -29,16 +29,7 @@ class PHPParameter extends BasePHPElement
|
|||
public function readObjectFromReflection($reflectionObject): static
|
||||
{
|
||||
$this->name = $reflectionObject->name;
|
||||
$parameterType = $reflectionObject->getType();
|
||||
if ($parameterType instanceof ReflectionNamedType) {
|
||||
$this->type = $parameterType->getName();
|
||||
}
|
||||
if ($parameterType instanceof ReflectionUnionType) {
|
||||
foreach ($parameterType->getTypes() as $type) {
|
||||
$this->type .= $type->getName() . '|';
|
||||
}
|
||||
$this->type = substr($this->type, 0, -1);
|
||||
}
|
||||
$this->type = self::convertReflectionTypeToString($reflectionObject->getType());
|
||||
$this->is_vararg = $reflectionObject->isVariadic();
|
||||
$this->is_passed_by_ref = $reflectionObject->isPassedByReference();
|
||||
return $this;
|
||||
|
@ -53,21 +44,11 @@ class PHPParameter extends BasePHPElement
|
|||
// #[LanguageLevelTypeAware(["8.0" => "OpenSSLCertificate|string"], default: "resource|string")]
|
||||
$this->name = $node->var->name;
|
||||
|
||||
$typeFromAttribute = $this->findTypeFromAttribute($node);
|
||||
$typeFromAttribute = self::findTypeFromAttribute($node->attrGroups);
|
||||
if ($typeFromAttribute != null) {
|
||||
$this->type = $typeFromAttribute;
|
||||
} else {
|
||||
$type = $node->type;
|
||||
if ($type !== null) {
|
||||
if ($type instanceof UnionType) {
|
||||
foreach ($type->types as $type) {
|
||||
$this->type .= $this->getTypeNameFromNode($type) . '|';
|
||||
}
|
||||
$this->type = substr($this->type, 0, -1);
|
||||
} else {
|
||||
$this->type = $this->getTypeNameFromNode($type);
|
||||
}
|
||||
}
|
||||
$this->type = self::convertParsedTypeToString($node->type);
|
||||
}
|
||||
if($node->default instanceof Expr\ConstFetch && $node->default->name->parts[0] === "null"){
|
||||
$this->type .= "|null";
|
||||
|
@ -96,36 +77,4 @@ class PHPParameter extends BasePHPElement
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected function getTypeNameFromNode(Name|Identifier|NullableType|string $type): string
|
||||
{
|
||||
if($type instanceof NullableType){
|
||||
$type = $type->type;
|
||||
}
|
||||
if (empty($type->name)) {
|
||||
if (!empty($type->parts)) {
|
||||
return $type->parts[0];
|
||||
}
|
||||
} else {
|
||||
return $type->name;
|
||||
}
|
||||
}
|
||||
|
||||
protected function findTypeFromAttribute(Param $node): ?string
|
||||
{
|
||||
foreach ($node->attrGroups as $attrGroup) {
|
||||
foreach ($attrGroup->attrs as $attr) {
|
||||
if ($attr->name->toString() === "LanguageLevelTypeAware") {
|
||||
$arg = $attr->args[0]->value;
|
||||
if ($arg instanceof Array_) {
|
||||
$value = $arg->items[0]->value;
|
||||
if ($value instanceof String_) {
|
||||
return $value->value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -122,6 +122,7 @@ class StubsTest extends TestCase
|
|||
}
|
||||
}
|
||||
}
|
||||
self::assertEquals($function->returnType, $phpstormFunction->returnType, "Function $functionName has invalid return type");
|
||||
}
|
||||
|
||||
private function printParameters(array $params): string
|
||||
|
@ -552,10 +553,10 @@ class StubsTest extends TestCase
|
|||
|
||||
private static function checkFunctionDoesNotHaveReturnTypeHints(int $sinceVersion, PHPFunction $function)
|
||||
{
|
||||
$returnTypeHint = $function->returnType === null ? $function->returnType : $function->returnType->getType();
|
||||
$returnTypeHint = $function->returnType;
|
||||
if ($sinceVersion < 7) {
|
||||
if (!$function->hasMutedProblem(StubProblemType::FUNCTION_HAS_RETURN_TYPEHINT)) {
|
||||
self::assertNull($returnTypeHint, "Function '$function->name' has since version '$sinceVersion'
|
||||
self::assertEmpty($returnTypeHint, "Function '$function->name' has since version '$sinceVersion'
|
||||
but has return typehint '$returnTypeHint' that supported only since PHP 7. Please declare return type via PhpDoc");
|
||||
} else {
|
||||
self::markTestSkipped("Skipped");
|
||||
|
|
|
@ -28,7 +28,7 @@ use JetBrains\PhpStorm\Pure;
|
|||
* content of the original token in element 1 and the line number in element 2.
|
||||
*/
|
||||
#[Pure]
|
||||
function token_get_all (string $code, int $flags = 0) {}
|
||||
function token_get_all (string $code, int $flags = 0): array {}
|
||||
|
||||
/**
|
||||
* Get the symbolic name of a given PHP token
|
||||
|
@ -39,7 +39,7 @@ function token_get_all (string $code, int $flags = 0) {}
|
|||
* @return string The symbolic name of the given <i>token</i>.
|
||||
*/
|
||||
#[Pure]
|
||||
function token_name (int $id) {}
|
||||
function token_name (int $id): string {}
|
||||
|
||||
define('TOKEN_PARSE', 1);
|
||||
define('T_REQUIRE_ONCE', 263);
|
||||
|
|
60
xml/xml.php
60
xml/xml.php
|
@ -22,6 +22,7 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @return resource|false|XmlParser a resource handle for the new XML parser.
|
||||
*/
|
||||
#[Pure]
|
||||
#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")]
|
||||
function xml_parser_create (string $encoding) {}
|
||||
|
||||
/**
|
||||
|
@ -46,6 +47,7 @@ function xml_parser_create (string $encoding) {}
|
|||
* @return resource|false|XmlParser a resource handle for the new XML parser.
|
||||
*/
|
||||
#[Pure]
|
||||
#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")]
|
||||
function xml_parser_create_ns (string $encoding, string $separator = ':') {}
|
||||
|
||||
/**
|
||||
|
@ -59,7 +61,8 @@ function xml_parser_create_ns (string $encoding, string $separator = ':') {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_object (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, object &$object) {}
|
||||
function xml_set_object (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, object &$object): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set up start and end element handlers
|
||||
|
@ -88,7 +91,7 @@ function xml_set_object (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], defaul
|
|||
* reference to the XML parser calling the handler.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_element_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $start_handler, $end_handler) {}
|
||||
function xml_set_element_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $start_handler, $end_handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up character data handler
|
||||
|
@ -112,7 +115,7 @@ function xml_set_element_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"
|
|||
* reference to the XML parser calling the handler.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_character_data_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler) {}
|
||||
function xml_set_character_data_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up processing instruction (PI) handler
|
||||
|
@ -137,7 +140,7 @@ function xml_set_character_data_handler (#[LanguageLevelTypeAware(["8.0" => "Xml
|
|||
* reference to the XML parser calling the handler.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_processing_instruction_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler) {}
|
||||
function xml_set_processing_instruction_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up default handler
|
||||
|
@ -161,7 +164,7 @@ function xml_set_processing_instruction_handler (#[LanguageLevelTypeAware(["8.0"
|
|||
* reference to the XML parser calling the handler.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_default_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler) {}
|
||||
function xml_set_default_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up unparsed entity declaration handler
|
||||
|
@ -190,7 +193,7 @@ function xml_set_default_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"
|
|||
* handler.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_unparsed_entity_decl_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler) {}
|
||||
function xml_set_unparsed_entity_decl_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up notation declaration handler
|
||||
|
@ -217,7 +220,8 @@ function xml_set_unparsed_entity_decl_handler (#[LanguageLevelTypeAware(["8.0" =
|
|||
* reference to the XML parser calling the handler.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_notation_decl_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler) {}
|
||||
function xml_set_notation_decl_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set up external entity reference handler
|
||||
|
@ -248,7 +252,8 @@ function xml_set_notation_decl_handler (#[LanguageLevelTypeAware(["8.0" => "XmlP
|
|||
* reference to the XML parser calling the handler.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_external_entity_ref_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler) {}
|
||||
function xml_set_external_entity_ref_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set up start namespace declaration handler
|
||||
|
@ -277,7 +282,8 @@ function xml_set_external_entity_ref_handler (#[LanguageLevelTypeAware(["8.0" =>
|
|||
* reference to the XML parser calling the handler.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_start_namespace_decl_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler) {}
|
||||
function xml_set_start_namespace_decl_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set up end namespace declaration handler
|
||||
|
@ -305,7 +311,8 @@ function xml_set_start_namespace_decl_handler (#[LanguageLevelTypeAware(["8.0" =
|
|||
* reference to the XML parser calling the handler.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_end_namespace_decl_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler) {}
|
||||
function xml_set_end_namespace_decl_handler (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, $handler): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Start parsing an XML document
|
||||
|
@ -337,7 +344,8 @@ function xml_set_end_namespace_decl_handler (#[LanguageLevelTypeAware(["8.0" =>
|
|||
* Entity errors are reported at the end of the data thus only if
|
||||
* <i>is_final</i> is set and <b>TRUE</b>.
|
||||
*/
|
||||
function xml_parse (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, string $data, bool $is_final = false) {}
|
||||
function xml_parse (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, string $data, bool $is_final = false): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Parse XML data into an array structure
|
||||
|
@ -358,7 +366,7 @@ function xml_parse (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "r
|
|||
* success. This is not the same as <b>FALSE</b> and <b>TRUE</b>, be careful with
|
||||
* operators such as ===.
|
||||
*/
|
||||
function xml_parse_into_struct (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, string $data, &$values, &$index)
|
||||
function xml_parse_into_struct (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, string $data, &$values, &$index): int
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -373,7 +381,7 @@ function xml_parse_into_struct (#[LanguageLevelTypeAware(["8.0" => "XmlParser"],
|
|||
* section.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_get_error_code (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser) {}
|
||||
function xml_get_error_code (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser): int {}
|
||||
|
||||
/**
|
||||
* Get XML parser error string
|
||||
|
@ -385,7 +393,8 @@ function xml_get_error_code (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], de
|
|||
* <i>code</i>, or <b>FALSE</b> if no description was found.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_error_string (int $error_code) {}
|
||||
function xml_error_string (int $error_code): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get current line number for an XML parser
|
||||
|
@ -398,7 +407,9 @@ function xml_error_string (int $error_code) {}
|
|||
* parser is currently at in its data buffer.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_get_current_line_number (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function xml_get_current_line_number (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get current column number for an XML parser
|
||||
|
@ -413,7 +424,9 @@ function xml_get_current_line_number (#[LanguageLevelTypeAware(["8.0" => "XmlPar
|
|||
* currently at.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_get_current_column_number (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function xml_get_current_column_number (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get current byte index for an XML parser
|
||||
|
@ -426,7 +439,9 @@ function xml_get_current_column_number (#[LanguageLevelTypeAware(["8.0" => "XmlP
|
|||
* the parser is currently at in its data buffer (starting at 0).
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_get_current_byte_index (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "int"], default: "int|false")]
|
||||
function xml_get_current_byte_index (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser)
|
||||
{}
|
||||
|
||||
/**
|
||||
* Free an XML parser
|
||||
|
@ -435,7 +450,8 @@ function xml_get_current_byte_index (#[LanguageLevelTypeAware(["8.0" => "XmlPars
|
|||
* @return bool This function returns <b>FALSE</b> if <i>parser</i> does not
|
||||
* refer to a valid parser, or else it frees the parser and returns <b>TRUE</b>.
|
||||
*/
|
||||
function xml_parser_free (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser) {}
|
||||
function xml_parser_free (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Set options in an XML parser
|
||||
|
@ -498,7 +514,8 @@ function xml_parser_free (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], defau
|
|||
* refer to a valid parser, or if the option could not be set. Else the
|
||||
* option is set and <b>TRUE</b> is returned.
|
||||
*/
|
||||
function xml_parser_set_option (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, int $option, $value) {}
|
||||
function xml_parser_set_option (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, int $option, $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Get options from an XML parser
|
||||
|
@ -507,13 +524,14 @@ function xml_parser_set_option (#[LanguageLevelTypeAware(["8.0" => "XmlParser"],
|
|||
* @param int $option Which option to fetch. <b>XML_OPTION_CASE_FOLDING</b>
|
||||
* and <b>XML_OPTION_TARGET_ENCODING</b> are available.
|
||||
* See <b>xml_parser_set_option</b> for their description.
|
||||
* @return mixed This function returns <b>FALSE</b> if <i>parser</i> does
|
||||
* @return string|int This function returns <b>FALSE</b> if <i>parser</i> does
|
||||
* not refer to a valid parser or if <i>option</i> isn't
|
||||
* valid (generates also a <b>E_WARNING</b>).
|
||||
* Else the option's value is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_parser_get_option (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, int $option) {}
|
||||
function xml_parser_get_option (#[LanguageLevelTypeAware(["8.0" => "XmlParser"], default: "resource")] $parser, int $option): string|int
|
||||
{}
|
||||
|
||||
define ('XML_ERROR_NONE', 0);
|
||||
define ('XML_ERROR_NO_MEMORY', 1);
|
||||
|
|
|
@ -517,25 +517,29 @@ class XMLWriter {
|
|||
* @param string $uri <p>
|
||||
* The URI of the resource for the output.
|
||||
* </p>
|
||||
* @return bool Object oriented style: Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @return bool|resource Object oriented style: Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* </p>
|
||||
* <p>
|
||||
* Procedural style: Returns a new xmlwriter resource for later use with the
|
||||
* xmlwriter functions on success, <b>FALSE</b> on error.
|
||||
*/
|
||||
function xmlwriter_open_uri (string $uri) {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "XMLWriter|false"], default: "resource|false")]
|
||||
function xmlwriter_open_uri (string $uri)
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
* Create new xmlwriter using memory for string output
|
||||
* @link https://php.net/manual/en/function.xmlwriter-open-memory.php
|
||||
* @return bool Object oriented style: Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @return XMLWriter|false|resource Object oriented style: Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* </p>
|
||||
* <p>
|
||||
* Procedural style: Returns a new xmlwriter resource for later use with the
|
||||
* xmlwriter functions on success, <b>FALSE</b> on error.
|
||||
*/
|
||||
function xmlwriter_open_memory () {}
|
||||
#[LanguageLevelTypeAware(["8.0" => "XMLWriter|false"], default: "resource|false")]
|
||||
function xmlwriter_open_memory (): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -551,7 +555,8 @@ function xmlwriter_open_memory () {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_set_indent (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, bool $enable) {}
|
||||
function xmlwriter_set_indent (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, bool $enable): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -567,7 +572,8 @@ function xmlwriter_set_indent (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"],
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_set_indent_string (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $indentation) {}
|
||||
function xmlwriter_set_indent_string (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $indentation): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 1.0.0)<br/>
|
||||
|
@ -579,7 +585,8 @@ function xmlwriter_set_indent_string (#[LanguageLevelTypeAware(["8.0" => "XMLWri
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-open-uri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_comment (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_start_comment (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 1.0.0)<br/>
|
||||
|
@ -592,7 +599,8 @@ function xmlwriter_start_comment (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"
|
|||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_comment (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_comment (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -608,7 +616,8 @@ function xmlwriter_end_comment (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"],
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_attribute (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name) {}
|
||||
function xmlwriter_start_attribute (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -620,7 +629,8 @@ function xmlwriter_start_attribute (#[LanguageLevelTypeAware(["8.0" => "XMLWrite
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-open-uri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_attribute (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_attribute (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -639,7 +649,8 @@ function xmlwriter_end_attribute (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_attribute (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $value) {}
|
||||
function xmlwriter_write_attribute (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -661,7 +672,8 @@ function xmlwriter_write_attribute (#[LanguageLevelTypeAware(["8.0" => "XMLWrite
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_attribute_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $prefix, string $name, string $namespace) {}
|
||||
function xmlwriter_start_attribute_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $prefix, string $name, string $namespace): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -686,7 +698,8 @@ function xmlwriter_start_attribute_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWr
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_attribute_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $prefix, string $name, string $namespace, string $value) {}
|
||||
function xmlwriter_write_attribute_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $prefix, string $name, string $namespace, string $value): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -702,7 +715,8 @@ function xmlwriter_write_attribute_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWr
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name) {}
|
||||
function xmlwriter_start_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -714,7 +728,8 @@ function xmlwriter_start_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-open-uri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL xmlwriter >= 2.0.4)<br/>
|
||||
|
@ -726,7 +741,8 @@ function xmlwriter_end_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"],
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-open-uri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_full_end_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_full_end_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -748,7 +764,8 @@ function xmlwriter_full_end_element (#[LanguageLevelTypeAware(["8.0" => "XMLWrit
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_element_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $prefix, string $name, string $namespace) {}
|
||||
function xmlwriter_start_element_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $prefix, string $name, string $namespace): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -767,7 +784,8 @@ function xmlwriter_start_element_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWrit
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $content) {}
|
||||
function xmlwriter_write_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -792,7 +810,8 @@ function xmlwriter_write_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_element_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $prefix, string $name, string $namespace, string $content) {}
|
||||
function xmlwriter_write_element_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $prefix, string $name, string $namespace, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -808,7 +827,8 @@ function xmlwriter_write_element_ns (#[LanguageLevelTypeAware(["8.0" => "XMLWrit
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_pi (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $target) {}
|
||||
function xmlwriter_start_pi (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $target): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -820,7 +840,8 @@ function xmlwriter_start_pi (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], de
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-open-uri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_pi (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_pi (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -840,7 +861,8 @@ function xmlwriter_end_pi (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], defa
|
|||
*
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_pi (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $target, string $content) {}
|
||||
function xmlwriter_write_pi (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $target, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -853,7 +875,8 @@ function xmlwriter_write_pi (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], de
|
|||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_cdata (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_start_cdata (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -866,7 +889,8 @@ function xmlwriter_start_cdata (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"],
|
|||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_cdata (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_cdata (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -882,7 +906,8 @@ function xmlwriter_end_cdata (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], d
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_cdata (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $content) {}
|
||||
function xmlwriter_write_cdata (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -898,7 +923,8 @@ function xmlwriter_write_cdata (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"],
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_text (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $content) {}
|
||||
function xmlwriter_text (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL xmlwriter >= 2.0.4)<br/>
|
||||
|
@ -914,7 +940,8 @@ function xmlwriter_text (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], defaul
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_raw (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $content) {}
|
||||
function xmlwriter_write_raw (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -936,7 +963,8 @@ function xmlwriter_write_raw (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], d
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_document (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $version = '1.0', string $encoding, string $standalone) {}
|
||||
function xmlwriter_start_document (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $version = '1.0', string $encoding, string $standalone): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -949,7 +977,8 @@ function xmlwriter_start_document (#[LanguageLevelTypeAware(["8.0" => "XMLWriter
|
|||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_document (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_document (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -965,7 +994,8 @@ function xmlwriter_end_document (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"]
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_comment (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $content) {}
|
||||
function xmlwriter_write_comment (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -987,7 +1017,8 @@ function xmlwriter_write_comment (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_dtd (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $qualifiedName, string $publicId, string $systemId) {}
|
||||
function xmlwriter_start_dtd (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $qualifiedName, string $publicId, string $systemId): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -999,7 +1030,8 @@ function xmlwriter_start_dtd (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], d
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-open-uri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_dtd (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_dtd (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1024,7 +1056,8 @@ function xmlwriter_end_dtd (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], def
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_dtd (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $publicId, string $systemId, string $content) {}
|
||||
function xmlwriter_write_dtd (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $publicId, string $systemId, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1040,7 +1073,8 @@ function xmlwriter_write_dtd (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], d
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_dtd_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $qualifiedName) {}
|
||||
function xmlwriter_start_dtd_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $qualifiedName): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1049,7 +1083,8 @@ function xmlwriter_start_dtd_element (#[LanguageLevelTypeAware(["8.0" => "XMLWri
|
|||
* @param $writer
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_dtd_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_dtd_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1068,7 +1103,8 @@ function xmlwriter_end_dtd_element (#[LanguageLevelTypeAware(["8.0" => "XMLWrite
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_dtd_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $content) {}
|
||||
function xmlwriter_write_dtd_element (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1084,7 +1120,8 @@ function xmlwriter_write_dtd_element (#[LanguageLevelTypeAware(["8.0" => "XMLWri
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_dtd_attlist (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name) {}
|
||||
function xmlwriter_start_dtd_attlist (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1096,7 +1133,8 @@ function xmlwriter_start_dtd_attlist (#[LanguageLevelTypeAware(["8.0" => "XMLWri
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-open-uri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_dtd_attlist (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_dtd_attlist (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1115,7 +1153,8 @@ function xmlwriter_end_dtd_attlist (#[LanguageLevelTypeAware(["8.0" => "XMLWrite
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_dtd_attlist (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $content) {}
|
||||
function xmlwriter_write_dtd_attlist (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, string $content): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1132,7 +1171,8 @@ function xmlwriter_write_dtd_attlist (#[LanguageLevelTypeAware(["8.0" => "XMLWri
|
|||
* @param bool $isParam
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_dtd_entity (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, bool $isParam) {}
|
||||
function xmlwriter_start_dtd_entity (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, string $name, bool $isParam): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1144,7 +1184,8 @@ function xmlwriter_start_dtd_entity (#[LanguageLevelTypeAware(["8.0" => "XMLWrit
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-open-uri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-open-memory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_dtd_entity (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer) {}
|
||||
function xmlwriter_end_dtd_entity (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1167,7 +1208,8 @@ function xmlwriter_end_dtd_entity (#[LanguageLevelTypeAware(["8.0" => "XMLWriter
|
|||
* @param string $ndataid
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_dtd_entity (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, $name, $content, $pe, $pubid, $sysid, $ndataid) {}
|
||||
function xmlwriter_write_dtd_entity (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, $name, $content, $pe, $pubid, $sysid, $ndataid): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1183,7 +1225,8 @@ function xmlwriter_write_dtd_entity (#[LanguageLevelTypeAware(["8.0" => "XMLWrit
|
|||
* </p>
|
||||
* @return string the current buffer as a string.
|
||||
*/
|
||||
function xmlwriter_output_memory (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, bool $flush = true) {}
|
||||
function xmlwriter_output_memory (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, bool $flush = true): string
|
||||
{}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 1.0.0)<br/>
|
||||
|
@ -1197,8 +1240,9 @@ function xmlwriter_output_memory (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"
|
|||
* @param bool $empty [optional] <p>
|
||||
* Whether to empty the buffer or not. Default is <b>TRUE</b>.
|
||||
* </p>
|
||||
* @return mixed If you opened the writer in memory, this function returns the generated XML buffer,
|
||||
* @return string|int If you opened the writer in memory, this function returns the generated XML buffer,
|
||||
* Else, if using URI, this function will write the buffer and return the number of
|
||||
* written bytes.
|
||||
*/
|
||||
function xmlwriter_flush (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, bool $empty = true) {}
|
||||
function xmlwriter_flush (#[LanguageLevelTypeAware(["8.0" => "XMLWriter"], default: "resource")] $writer, bool $empty = true): string|int
|
||||
{}
|
||||
|
|
|
@ -17,7 +17,7 @@ use JetBrains\PhpStorm\Pure;
|
|||
* </p>
|
||||
* @return int|false the number of (uncompressed) bytes read from the file, or FALSE on error
|
||||
*/
|
||||
function readgzfile (string $filename, int $use_include_path = 0) {}
|
||||
function readgzfile (string $filename, int $use_include_path = 0): int|false {}
|
||||
|
||||
/**
|
||||
* Rewind the position of a gz-file pointer
|
||||
|
@ -28,7 +28,8 @@ function readgzfile (string $filename, int $use_include_path = 0) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function gzrewind ($stream) {}
|
||||
function gzrewind ($stream): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Close an open gz-file pointer
|
||||
|
@ -39,7 +40,8 @@ function gzrewind ($stream) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function gzclose ($stream) {}
|
||||
function gzclose ($stream): bool
|
||||
{}
|
||||
|
||||
/**
|
||||
* Test for EOF on a gz-file pointer
|
||||
|
@ -48,10 +50,10 @@ function gzclose ($stream) {}
|
|||
* The gz-file pointer. It must be valid, and must point to a file
|
||||
* successfully opened by <b>gzopen</b>.
|
||||
* </p>
|
||||
* @return int|bool <b>TRUE</b> if the gz-file pointer is at EOF or an error occurs;
|
||||
* @return bool <b>TRUE</b> if the gz-file pointer is at EOF or an error occurs;
|
||||
* otherwise returns <b>FALSE</b>.
|
||||
*/
|
||||
function gzeof ($stream) {}
|
||||
function gzeof ($stream): bool {}
|
||||
|
||||
/**
|
||||
* Get character from gz-file pointer
|
||||
|
@ -62,7 +64,7 @@ function gzeof ($stream) {}
|
|||
* </p>
|
||||
* @return string|false The uncompressed character or <b>FALSE</b> on EOF (unlike <b>gzeof</b>).
|
||||
*/
|
||||
function gzgetc ($stream) {}
|
||||
function gzgetc ($stream): string|false {}
|
||||
|
||||
/**
|
||||
* Get line from file pointer
|
||||
|
@ -76,7 +78,7 @@ function gzgetc ($stream) {}
|
|||
* </p>
|
||||
* @return string|false The uncompressed string, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function gzgets ($stream, int $length) {}
|
||||
function gzgets ($stream, int $length): string|false {}
|
||||
|
||||
/**
|
||||
* Get line from gz-file pointer and strip HTML tags
|
||||
|
@ -109,9 +111,9 @@ function gzgetss ($zp, int $length, $allowable_tags)
|
|||
* @param int $length <p>
|
||||
* The number of bytes to read.
|
||||
* </p>
|
||||
* @return string The data that have been read.
|
||||
* @return string|false The data that have been read.
|
||||
*/
|
||||
function gzread ($stream, int $length) {}
|
||||
function gzread ($stream, int $length): string|false {}
|
||||
|
||||
/**
|
||||
* Open gz-file
|
||||
|
@ -152,7 +154,8 @@ function gzopen (string $filename, string $mode, int $use_include_path = 0) {}
|
|||
* @return int The number of uncompressed characters read from <i>gz</i>
|
||||
* and passed through to the input, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function gzpassthru ($stream) {}
|
||||
function gzpassthru ($stream): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Seek on a gz-file pointer
|
||||
|
@ -176,7 +179,8 @@ function gzpassthru ($stream) {}
|
|||
* @return int Upon success, returns 0; otherwise, returns -1. Note that seeking
|
||||
* past EOF is not considered an error.
|
||||
*/
|
||||
function gzseek ($stream, int $offset, int $whence = SEEK_SET) {}
|
||||
function gzseek ($stream, int $offset, int $whence = SEEK_SET): int
|
||||
{}
|
||||
|
||||
/**
|
||||
* Tell gz-file pointer read/write position
|
||||
|
@ -187,7 +191,7 @@ function gzseek ($stream, int $offset, int $whence = SEEK_SET) {}
|
|||
* </p>
|
||||
* @return int|false The position of the file pointer or <b>FALSE</b> if an error occurs.
|
||||
*/
|
||||
function gztell ($stream) {}
|
||||
function gztell ($stream): int|false {}
|
||||
|
||||
/**
|
||||
* Binary-safe gz-file write
|
||||
|
@ -211,10 +215,10 @@ function gztell ($stream) {}
|
|||
* configuration option will be ignored and no slashes will be
|
||||
* stripped from <i>string</i>.
|
||||
* </p>
|
||||
* @return int the number of (uncompressed) bytes written to the given gz-file
|
||||
* @return int|false the number of (uncompressed) bytes written to the given gz-file
|
||||
* stream.
|
||||
*/
|
||||
function gzwrite ($stream, string $data, int $length)
|
||||
function gzwrite ($stream, string $data, int $length): int|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -224,7 +228,7 @@ function gzwrite ($stream, string $data, int $length)
|
|||
* @param string $data
|
||||
* @param int $length [optional]
|
||||
*/
|
||||
function gzputs ($stream, string $data, int $length) {}
|
||||
function gzputs ($stream, string $data, int $length): int|false {}
|
||||
|
||||
/**
|
||||
* Read entire gz-file into an array
|
||||
|
@ -236,9 +240,9 @@ function gzputs ($stream, string $data, int $length) {}
|
|||
* You can set this optional parameter to 1, if you
|
||||
* want to search for the file in the include_path too.
|
||||
* </p>
|
||||
* @return array An array containing the file, one line per cell.
|
||||
* @return array|false An array containing the file, one line per cell.
|
||||
*/
|
||||
function gzfile (string $filename, int $use_include_path = 0) {}
|
||||
function gzfile (string $filename, int $use_include_path = 0): array|false {}
|
||||
|
||||
/**
|
||||
* Compress a string
|
||||
|
@ -259,7 +263,7 @@ function gzfile (string $filename, int $use_include_path = 0) {}
|
|||
* @return string|false The compressed string or <b>FALSE</b> if an error occurred.
|
||||
*/
|
||||
#[Pure]
|
||||
function gzcompress (string $data, int $level = -1, int $encoding = ZLIB_ENCODING_DEFLATE) {}
|
||||
function gzcompress (string $data, int $level = -1, int $encoding = ZLIB_ENCODING_DEFLATE): string|false {}
|
||||
|
||||
/**
|
||||
* Uncompress a compressed string
|
||||
|
@ -278,7 +282,7 @@ function gzcompress (string $data, int $level = -1, int $encoding = ZLIB_ENCODIN
|
|||
* or more than the optional parameter <i>length</i>.
|
||||
*/
|
||||
#[Pure]
|
||||
function gzuncompress (string $data, int $max_length = 0) {}
|
||||
function gzuncompress (string $data, int $max_length = 0): string|false {}
|
||||
|
||||
/**
|
||||
* Deflate a string
|
||||
|
@ -297,7 +301,7 @@ function gzuncompress (string $data, int $max_length = 0) {}
|
|||
* @return string|false The deflated string or <b>FALSE</b> if an error occurred.
|
||||
*/
|
||||
#[Pure]
|
||||
function gzdeflate (string $data, int $level = -1, int $encoding = ZLIB_ENCODING_RAW) {}
|
||||
function gzdeflate (string $data, int $level = -1, int $encoding = ZLIB_ENCODING_RAW): string|false {}
|
||||
|
||||
/**
|
||||
* Inflate a deflated string
|
||||
|
@ -316,7 +320,7 @@ function gzdeflate (string $data, int $level = -1, int $encoding = ZLIB_ENCODING
|
|||
* or more than the optional parameter <i>length</i>.
|
||||
*/
|
||||
#[Pure]
|
||||
function gzinflate (string $data, int $max_length = 0) {}
|
||||
function gzinflate (string $data, int $max_length = 0): string|false {}
|
||||
|
||||
/**
|
||||
* Create a gzip compressed string
|
||||
|
@ -346,7 +350,7 @@ function gzinflate (string $data, int $max_length = 0) {}
|
|||
* @return string|false The encoded string, or <b>FALSE</b> if an error occurred.
|
||||
*/
|
||||
#[Pure]
|
||||
function gzencode (string $data, int $level = -1, int $encoding = FORCE_GZIP) {}
|
||||
function gzencode (string $data, int $level = -1, int $encoding = FORCE_GZIP): string|false {}
|
||||
|
||||
/**
|
||||
* Decodes a gzip compressed string
|
||||
|
@ -361,7 +365,7 @@ function gzencode (string $data, int $level = -1, int $encoding = FORCE_GZIP) {}
|
|||
* @since 5.4
|
||||
*/
|
||||
#[Pure]
|
||||
function gzdecode (string $data, int $max_length)
|
||||
function gzdecode (string $data, int $max_length): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
|
@ -373,43 +377,43 @@ function gzdecode (string $data, int $max_length)
|
|||
* </p>
|
||||
* @param int $level [optional] default -1 <p>
|
||||
* </p>
|
||||
* @return string
|
||||
* @return string|false
|
||||
* @since 5.4
|
||||
*/
|
||||
#[Pure]
|
||||
function zlib_encode (string $data, int $encoding, int $level) {}
|
||||
function zlib_encode (string $data, int $encoding, int $level): string|false {}
|
||||
|
||||
/**
|
||||
* Uncompress any raw/gzip/zlib encoded data
|
||||
* @link https://php.net/manual/en/function.zlib-decode.php
|
||||
* @param string $data <p>
|
||||
* </p>
|
||||
* @param string $max_length [optional] <p>
|
||||
* @param int $max_length [optional] <p>
|
||||
* </p>
|
||||
* @return string
|
||||
* @return string|false
|
||||
* @since 5.4
|
||||
*/
|
||||
#[Pure]
|
||||
function zlib_decode (string $data, int $max_length)
|
||||
function zlib_decode (string $data, int $max_length): string|false
|
||||
{}
|
||||
|
||||
/**
|
||||
* Returns the coding type used for output compression
|
||||
* @link https://php.net/manual/en/function.zlib-get-coding-type.php
|
||||
* @return string Possible return values are gzip, deflate,
|
||||
* @return string|false Possible return values are gzip, deflate,
|
||||
* or <b>FALSE</b>.
|
||||
*/
|
||||
#[Pure]
|
||||
function zlib_get_coding_type () {}
|
||||
function zlib_get_coding_type (): string|false {}
|
||||
|
||||
/**
|
||||
* ob_start callback function to gzip output buffer
|
||||
* @link https://php.net/manual/en/function.ob-gzhandler.php
|
||||
* @param string $data
|
||||
* @param int $flags
|
||||
* @return string
|
||||
* @return string|false
|
||||
*/
|
||||
function ob_gzhandler (string $data, int $flags) {}
|
||||
function ob_gzhandler (string $data, int $flags): string|false {}
|
||||
|
||||
/**
|
||||
* Initialize an incremental deflate context
|
||||
|
@ -433,6 +437,7 @@ function ob_gzhandler (string $data, int $flags) {}
|
|||
* @since 7.0
|
||||
*/
|
||||
#[Pure]
|
||||
#[LanguageLevelTypeAware(["8.0" => "DeflateContext|false"], default: "resource|false")]
|
||||
function deflate_init (int $encoding, array $options = array()) {}
|
||||
|
||||
/**
|
||||
|
@ -456,7 +461,7 @@ function deflate_init (int $encoding, array $options = array()) {}
|
|||
* </p>
|
||||
* @since 7.0
|
||||
*/
|
||||
function deflate_add (#[LanguageLevelTypeAware(["8.0" => "DeflateContext"], default: "resource")] $context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH) {}
|
||||
function deflate_add (#[LanguageLevelTypeAware(["8.0" => "DeflateContext"], default: "resource")] $context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH): string|false {}
|
||||
|
||||
/**
|
||||
* Initialize an incremental inflate context
|
||||
|
@ -480,6 +485,7 @@ function deflate_add (#[LanguageLevelTypeAware(["8.0" => "DeflateContext"], defa
|
|||
* @since 7.0
|
||||
*/
|
||||
#[Pure]
|
||||
#[LanguageLevelTypeAware(["8.0" => "InflateContext|false"], default: "resource|false")]
|
||||
function inflate_init (int $encoding, array $options = array()) {}
|
||||
|
||||
/**
|
||||
|
@ -503,25 +509,25 @@ function inflate_init (int $encoding, array $options = array()) {}
|
|||
* </p>
|
||||
* @since 7.0
|
||||
*/
|
||||
function inflate_add (#[LanguageLevelTypeAware(["8.0" => "InflateContext"], default: "resource")] $context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH) {}
|
||||
function inflate_add (#[LanguageLevelTypeAware(["8.0" => "InflateContext"], default: "resource")] $context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH): string|false {}
|
||||
|
||||
/**
|
||||
* Get number of bytes read so far
|
||||
* @param InflateContext|resource $context
|
||||
* @return bool
|
||||
* @return int
|
||||
* @since 7.2
|
||||
*/
|
||||
#[Pure]
|
||||
function inflate_get_read_len (#[LanguageLevelTypeAware(["8.0" => "InflateContext"], default: "resource")] $context){}
|
||||
function inflate_get_read_len (#[LanguageLevelTypeAware(["8.0" => "InflateContext"], default: "resource")] $context): int{}
|
||||
|
||||
/**
|
||||
* Get decompression status
|
||||
* @param InflateContext|resource $context
|
||||
* @return bool
|
||||
* @return int
|
||||
* @since 7.2
|
||||
*/
|
||||
#[Pure]
|
||||
function inflate_get_status(#[LanguageLevelTypeAware(["8.0" => "InflateContext"], default: "resource")] $context) {}
|
||||
function inflate_get_status(#[LanguageLevelTypeAware(["8.0" => "InflateContext"], default: "resource")] $context): int {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
|
|
Loading…
Reference in New Issue