[phpstorm-stubs] update stubs to migration version for php 8.0
This commit is contained in:
parent
71276b938f
commit
e16c1713ce
|
@ -7,7 +7,7 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
name: Run tests against php 7.4
|
||||
name: Run tests against php 8.0
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
@ -15,22 +15,22 @@ jobs:
|
|||
- name: Build Docker Container
|
||||
run: docker-compose -f docker-compose.yml build >/dev/null
|
||||
env:
|
||||
PHP_VERSION: '7.4'
|
||||
PHP_VERSION: '8.0'
|
||||
|
||||
- name: Composer Install
|
||||
run: docker-compose -f docker-compose.yml run -e PHP_VERSION=7.4 test_runner composer update
|
||||
run: docker-compose -f docker-compose.yml run -e PHP_VERSION=8.0 test_runner composer update
|
||||
env:
|
||||
PHP_VERSION: '7.4'
|
||||
PHP_VERSION: '8.0'
|
||||
|
||||
- name: Dump Reflection To File
|
||||
run: docker-compose -f docker-compose.yml run -e PHP_VERSION=7.4 php_under_test /usr/local/bin/php tests/Tools/dump-reflection-to-file.php ReflectionData.json
|
||||
run: docker-compose -f docker-compose.yml run -e PHP_VERSION=8.0 php_under_test /usr/local/bin/php tests/Tools/dump-reflection-to-file.php ReflectionData.json
|
||||
env:
|
||||
PHP_VERSION: '7.4'
|
||||
PHP_VERSION: '8.0'
|
||||
|
||||
- name: Run Tests
|
||||
run: docker-compose -f docker-compose.yml run -e PHP_VERSION=7.4 test_runner vendor/bin/phpunit --testsuite PHP_7.4
|
||||
run: docker-compose -f docker-compose.yml run -e PHP_VERSION=8.0 test_runner vendor/bin/phpunit --testsuite PHP_8.0
|
||||
env:
|
||||
PHP_VERSION: '7.4'
|
||||
PHP_VERSION: '8.0'
|
||||
additional:
|
||||
runs-on: ubuntu-latest
|
||||
name: Run cs-fixer and stubs structure tests
|
||||
|
|
|
@ -127,6 +127,42 @@ function strcasecmp(string $string1, string $string2): int {}
|
|||
#[Pure]
|
||||
function strncasecmp(string $string1, string $string2, int $length): int {}
|
||||
|
||||
/**
|
||||
* The function returns {@see true} if the passed $haystack starts from the
|
||||
* $needle string or {@see false} otherwise.
|
||||
*
|
||||
* @param string $haystack
|
||||
* @param string $needle
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
function str_starts_with(string $haystack, string $needle): bool {}
|
||||
|
||||
/**
|
||||
* The function returns {@see true} if the passed $haystack ends with the
|
||||
* $needle string or {@see false} otherwise.
|
||||
*
|
||||
* @param string $haystack
|
||||
* @param string $needle
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
function str_ends_with(string $haystack, string $needle): bool {}
|
||||
|
||||
/**
|
||||
* Checks if $needle is found in $haystack and returns a boolean value
|
||||
* (true/false) whether or not the $needle was found.
|
||||
*
|
||||
* @param string $haystack
|
||||
* @param string $needle
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
function str_contains(string $haystack, string $needle): bool {}
|
||||
|
||||
/**
|
||||
* Return the current key and value pair from an array and advance the array cursor
|
||||
* @link https://php.net/manual/en/function.each.php
|
||||
|
@ -299,7 +335,7 @@ function error_reporting(?int $error_level): int {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function define(string $constant_name, null|array|bool|int|float|string $value, #[Deprecated(since: "7.3")] bool $case_insensitive = false): bool {}
|
||||
function define(string $constant_name, $value, #[Deprecated(since: "7.3")] bool $case_insensitive = false): bool {}
|
||||
|
||||
/**
|
||||
* Checks whether a given named constant exists
|
||||
|
|
176
Core/Core_c.php
176
Core/Core_c.php
|
@ -1,5 +1,6 @@
|
|||
<?php
|
||||
|
||||
use JetBrains\PhpStorm\ExpectedValues;
|
||||
use JetBrains\PhpStorm\Internal\TentativeType;
|
||||
use JetBrains\PhpStorm\Pure;
|
||||
|
||||
|
@ -113,7 +114,7 @@ interface ArrayAccess
|
|||
* The return value will be casted to boolean if non-boolean was returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetExists($offset): bool;
|
||||
public function offsetExists(mixed $offset): bool;
|
||||
|
||||
/**
|
||||
* Offset to retrieve
|
||||
|
@ -124,7 +125,7 @@ interface ArrayAccess
|
|||
* @return TValue Can return all value types.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetGet($offset): mixed;
|
||||
public function offsetGet(mixed $offset): mixed;
|
||||
|
||||
/**
|
||||
* Offset to set
|
||||
|
@ -138,7 +139,7 @@ interface ArrayAccess
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetSet($offset, $value): void;
|
||||
public function offsetSet(mixed $offset, mixed $value): void;
|
||||
|
||||
/**
|
||||
* Offset to unset
|
||||
|
@ -149,7 +150,7 @@ interface ArrayAccess
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetUnset($offset): void;
|
||||
public function offsetUnset(mixed $offset): void;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -174,7 +175,7 @@ interface Serializable
|
|||
* @param string $data The string representation of the object.
|
||||
* @return void
|
||||
*/
|
||||
public function unserialize($data);
|
||||
public function unserialize(string $data);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -247,7 +248,7 @@ interface Throwable extends Stringable
|
|||
* @return null|Throwable Returns the previous {@see Throwable} if available, or <b>NULL</b> otherwise.
|
||||
* @since 7.0
|
||||
*/
|
||||
public function getPrevious();
|
||||
public function getPrevious(): Throwable|null;
|
||||
|
||||
/**
|
||||
* Gets a string representation of the thrown object
|
||||
|
@ -277,6 +278,23 @@ interface Countable
|
|||
public function count(): int;
|
||||
}
|
||||
|
||||
/**
|
||||
* Stringable interface denotes a class as having a __toString() method.
|
||||
*
|
||||
* @since 8.0
|
||||
*/
|
||||
interface Stringable
|
||||
{
|
||||
/**
|
||||
* Magic method {@see https://www.php.net/manual/en/language.oop5.magic.php#object.tostring}
|
||||
* allows a class to decide how it will react when it is treated like a string.
|
||||
*
|
||||
* @return string Returns string representation of the object that
|
||||
* implements this interface (and/or "__toString" magic method).
|
||||
*/
|
||||
public function __toString(): string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Created by typecasting to object.
|
||||
* @link https://php.net/manual/en/reserved.classes.php
|
||||
|
@ -310,7 +328,7 @@ class Exception implements Throwable
|
|||
* @param null|Throwable $previous [optional] The previous throwable used for the exception chaining.
|
||||
*/
|
||||
#[Pure]
|
||||
public function __construct($message = '', $code = 0, Throwable $previous = null) {}
|
||||
public function __construct(string $message = '', int $code = 0, Throwable|null $previous = null) {}
|
||||
|
||||
/**
|
||||
* Gets the Exception message
|
||||
|
@ -419,7 +437,7 @@ class Error implements Throwable
|
|||
* @param null|Throwable $previous [optional] The previous throwable used for the exception chaining.
|
||||
*/
|
||||
#[Pure]
|
||||
public function __construct($message = '', $code = 0, Throwable $previous = null) {}
|
||||
public function __construct(string $message = '', int $code = 0, Throwable|null $previous = null) {}
|
||||
|
||||
final public function getMessage(): string {}
|
||||
|
||||
|
@ -550,6 +568,11 @@ class CompileError extends Error {}
|
|||
*/
|
||||
class DivisionByZeroError extends ArithmeticError {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
class UnhandledMatchError extends Error {}
|
||||
|
||||
/**
|
||||
* An Error Exception.
|
||||
* @link https://php.net/manual/en/class.errorexception.php
|
||||
|
@ -569,7 +592,7 @@ class ErrorException extends Exception
|
|||
* @param Exception $previous [optional] The previous exception used for the exception chaining.
|
||||
*/
|
||||
#[Pure]
|
||||
public function __construct($message = '', $code = 0, $severity = 1, $filename = __FILE__, $line = __LINE__, Throwable $previous = null) {}
|
||||
public function __construct(string $message = '', int $code = 0, int $severity = 1, string|null $filename = __FILE__, int|null $line = __LINE__, Throwable|null $previous = null) {}
|
||||
|
||||
/**
|
||||
* Gets the exception severity
|
||||
|
@ -684,3 +707,138 @@ final class WeakReference
|
|||
*/
|
||||
public function get(): ?object {}
|
||||
}
|
||||
|
||||
/**
|
||||
* Weak maps allow creating a map from objects to arbitrary values
|
||||
* (similar to SplObjectStorage) without preventing the objects that are used
|
||||
* as keys from being garbage collected. If an object key is garbage collected,
|
||||
* it will simply be removed from the map.
|
||||
*
|
||||
* @since 8.0
|
||||
*
|
||||
* @template TKey of object
|
||||
* @template TValue
|
||||
* @template-implements IteratorAggregate<TKey, TValue>
|
||||
*/
|
||||
final class WeakMap implements ArrayAccess, Countable, IteratorAggregate
|
||||
{
|
||||
/**
|
||||
* Returns {@see true} if the value for the object is contained in
|
||||
* the {@see WeakMap} and {@see false} instead.
|
||||
*
|
||||
* @param TKey $object Any object
|
||||
* @return bool
|
||||
*/
|
||||
public function offsetExists($object): bool {}
|
||||
|
||||
/**
|
||||
* Returns the existsing value by an object.
|
||||
*
|
||||
* @param TKey $object Any object
|
||||
* @return TValue Value associated with the key object
|
||||
*/
|
||||
public function offsetGet($object): mixed {}
|
||||
|
||||
/**
|
||||
* Sets a new value for an object.
|
||||
*
|
||||
* @param TKey $object Any object
|
||||
* @param TValue $value Any value
|
||||
* @return void
|
||||
*/
|
||||
public function offsetSet($object, mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Force removes an object value from the {@see WeakMap} instance.
|
||||
*
|
||||
* @param TKey $object Any object
|
||||
* @return void
|
||||
*/
|
||||
public function offsetUnset($object): void {}
|
||||
|
||||
/**
|
||||
* Returns an iterator in the "[object => mixed]" format.
|
||||
*
|
||||
* @return Traversable<TKey, TValue>
|
||||
*/
|
||||
public function getIterator(): Iterator {}
|
||||
|
||||
/**
|
||||
* Returns the number of items in the {@see WeakMap} instance.
|
||||
*
|
||||
* @return int<0,max>
|
||||
*/
|
||||
public function count(): int {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class Attribute
|
||||
{
|
||||
/**
|
||||
* Marks that attribute declaration is allowed only in classes.
|
||||
*/
|
||||
public const TARGET_CLASS = 1;
|
||||
|
||||
/**
|
||||
* Marks that attribute declaration is allowed only in functions.
|
||||
*/
|
||||
public const TARGET_FUNCTION = 2;
|
||||
|
||||
/**
|
||||
* Marks that attribute declaration is allowed only in class methods.
|
||||
*/
|
||||
public const TARGET_METHOD = 4;
|
||||
|
||||
/**
|
||||
* Marks that attribute declaration is allowed only in class properties.
|
||||
*/
|
||||
public const TARGET_PROPERTY = 8;
|
||||
|
||||
/**
|
||||
* Marks that attribute declaration is allowed only in class constants.
|
||||
*/
|
||||
public const TARGET_CLASS_CONSTANT = 16;
|
||||
|
||||
/**
|
||||
* Marks that attribute declaration is allowed only in function or method parameters.
|
||||
*/
|
||||
public const TARGET_PARAMETER = 32;
|
||||
|
||||
/**
|
||||
* Marks that attribute declaration is allowed anywhere.
|
||||
*/
|
||||
public const TARGET_ALL = 63;
|
||||
|
||||
/**
|
||||
* Notes that an attribute declaration in the same place is
|
||||
* allowed multiple times.
|
||||
*/
|
||||
public const IS_REPEATABLE = 64;
|
||||
public int $flags;
|
||||
|
||||
/**
|
||||
* @param int $flags A value in the form of a bitmask indicating the places
|
||||
* where attributes can be defined.
|
||||
*/
|
||||
public function __construct(#[ExpectedValues([Attribute::class])] int $flags = self::TARGET_ALL) {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class InternalIterator implements Iterator
|
||||
{
|
||||
private function __construct() {}
|
||||
|
||||
public function current(): mixed {}
|
||||
|
||||
public function next(): void {}
|
||||
|
||||
public function key(): mixed {}
|
||||
|
||||
public function valid(): bool {}
|
||||
|
||||
public function rewind(): void {}
|
||||
}
|
||||
|
|
76
PDO/PDO.php
76
PDO/PDO.php
|
@ -558,6 +558,13 @@ class PDO
|
|||
*/
|
||||
public const FETCH_ORI_REL = 5;
|
||||
|
||||
/**
|
||||
* Specifies that the default fetch mode shall be used.
|
||||
* @since 8.0.7
|
||||
* @link https://php.net/manual/en/pdo.constants.php#pdo.constants.fetch-default
|
||||
*/
|
||||
public const FETCH_DEFAULT = 0;
|
||||
|
||||
/**
|
||||
* Create a <b>PDOStatement</b> object with a forward-only cursor. This is the
|
||||
* default cursor choice, as it is the fastest and most common data access
|
||||
|
@ -891,6 +898,12 @@ class PDO
|
|||
*/
|
||||
public const OCI_ATTR_MODULE = 1003;
|
||||
|
||||
/**
|
||||
* The number of milliseconds to wait for individual round trips to the database to complete before timing out.
|
||||
* @since 8.0
|
||||
*/
|
||||
public const OCI_ATTR_CALL_TIMEOUT = 1004;
|
||||
|
||||
/**
|
||||
* Sets the date format.
|
||||
*/
|
||||
|
@ -911,12 +924,12 @@ class PDO
|
|||
* Creates a PDO instance representing a connection to a database
|
||||
* @link https://php.net/manual/en/pdo.construct.php
|
||||
* @param string $dsn
|
||||
* @param string $username [optional]
|
||||
* @param string $password [optional]
|
||||
* @param array $options [optional]
|
||||
* @param string|null $username [optional]
|
||||
* @param string|null $password [optional]
|
||||
* @param array|null $options [optional]
|
||||
* @throws PDOException if the attempt to connect to the requested database fails.
|
||||
*/
|
||||
public function __construct($dsn, $username = null, $password = null, $options = null) {}
|
||||
public function __construct(string $dsn, string|null $username = null, string|null $password = null, array|null $options = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.3, PHP 7, PECL pdo >= 1.0.3)<br/>
|
||||
|
@ -956,7 +969,7 @@ class PDO
|
|||
* so <b>PDO::prepare</b> does not check the statement.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function prepare($query, array $options = []): PDOStatement|false {}
|
||||
public function prepare(string $query, array $options = []): PDOStatement|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1023,7 +1036,7 @@ class PDO
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setAttribute($attribute, $value): bool {}
|
||||
public function setAttribute(int $attribute, mixed $value): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1054,7 +1067,7 @@ class PDO
|
|||
* </code>
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function exec($statement): int|false {}
|
||||
public function exec(string $statement): int|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.2.0)<br/>
|
||||
|
@ -1069,10 +1082,7 @@ class PDO
|
|||
* @param int $mode <p>
|
||||
* The fetch mode must be one of the PDO::FETCH_* constants.
|
||||
* </p>
|
||||
* @param mixed $arg3 <p>
|
||||
* The second and following parameters are the same as the parameters for PDOStatement::setFetchMode.
|
||||
* </p>
|
||||
* @param array $ctorargs [optional] <p>
|
||||
* @param mixed $fetch_mode_args <p>
|
||||
* Arguments of custom class constructor when the <i>mode</i>
|
||||
* parameter is set to <b>PDO::FETCH_CLASS</b>.
|
||||
* </p>
|
||||
|
@ -1080,7 +1090,7 @@ class PDO
|
|||
* on failure.
|
||||
* @see PDOStatement::setFetchMode For a full description of the second and following parameters.
|
||||
*/
|
||||
public function query($statement, $mode = PDO::ATTR_DEFAULT_FETCH_MODE, $arg3 = null, array $ctorargs = []) {}
|
||||
public function query($statement, $mode = PDO::ATTR_DEFAULT_FETCH_MODE, ...$fetch_mode_args) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1106,7 +1116,7 @@ class PDO
|
|||
* IM001 SQLSTATE.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function lastInsertId($name = null): string|false {}
|
||||
public function lastInsertId(string|null $name = null): string|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1204,7 +1214,7 @@ class PDO
|
|||
* An unsuccessful call returns null.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getAttribute($attribute): mixed {}
|
||||
public function getAttribute(int $attribute): mixed {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.2.1)<br/>
|
||||
|
@ -1221,7 +1231,7 @@ class PDO
|
|||
* this way.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function quote($string, $type = PDO::PARAM_STR): string|false {}
|
||||
public function quote(string $string, int $type = PDO::PARAM_STR): string|false {}
|
||||
|
||||
final public function __wakeup() {}
|
||||
|
||||
|
@ -1387,7 +1397,7 @@ class PDO
|
|||
* with fields message and pid, otherwise <b>FALSE</b>.
|
||||
* @since 5.6
|
||||
*/
|
||||
public function pgsqlGetNotify(int $fetchMode = PDO::FETCH_LAZY, int $timeoutMilliseconds = 0) {}
|
||||
public function pgsqlGetNotify(int $fetchMode = PDO::FETCH_DEFAULT, int $timeoutMilliseconds = 0): array|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.6.0, PHP 7, PHP 8)<br/>
|
||||
|
@ -1436,7 +1446,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* @throws PDOException On error if PDO::ERRMODE_EXCEPTION option is true.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function execute($params = null): bool {}
|
||||
public function execute(array|null $params = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1467,7 +1477,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* all cases, <b>FALSE</b> is returned on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fetch($mode = PDO::FETCH_BOTH, $cursorOrientation = PDO::FETCH_ORI_NEXT, $cursorOffset = 0): mixed {}
|
||||
public function fetch(int $mode = PDO::FETCH_BOTH, int $cursorOrientation = PDO::FETCH_ORI_NEXT, int $cursorOffset = 0): mixed {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1500,7 +1510,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function bindParam($param, &$var, $type = PDO::PARAM_STR, $maxLength = null, $driverOptions = null): bool {}
|
||||
public function bindParam(int|string $param, mixed &$var, int $type = PDO::PARAM_STR, int $maxLength = null, mixed $driverOptions = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1526,7 +1536,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function bindColumn($column, &$var, $type = PDO::PARAM_STR, $maxLength = null, $driverOptions = null): bool {}
|
||||
public function bindColumn(int|string $column, mixed &$var, int $type = PDO::PARAM_STR, int $maxLength = null, mixed $driverOptions = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 1.0.0)<br/>
|
||||
|
@ -1549,7 +1559,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function bindValue($param, $value, $type = PDO::PARAM_STR): bool {}
|
||||
public function bindValue(int|string $param, mixed $value, int $type = PDO::PARAM_STR): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1577,7 +1587,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* use <b>PDOStatement::fetchColumn</b> to retrieve data.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fetchColumn($column = 0): mixed {}
|
||||
public function fetchColumn(int $column = 0): mixed {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1624,7 +1634,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* processing them with PHP.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fetchAll($mode = PDO::FETCH_BOTH, $fetch_argument = null, ...$args): array {}
|
||||
public function fetchAll(int $mode = PDO::FETCH_BOTH, mixed ...$args): array {}
|
||||
|
||||
/**
|
||||
* @template T
|
||||
|
@ -1642,7 +1652,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* correspond to the column names or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fetchObject($class = 'stdClass', array $constructorArgs = []): object|false {}
|
||||
public function fetchObject(string|null $class = 'stdClass', array $constructorArgs = []): object|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.1.0)<br/>
|
||||
|
@ -1693,7 +1703,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setAttribute($attribute, $value): bool {}
|
||||
public function setAttribute(int $attribute, mixed $value): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.2.0)<br/>
|
||||
|
@ -1703,7 +1713,7 @@ class PDOStatement implements IteratorAggregate
|
|||
* @return mixed the attribute value.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getAttribute($name): mixed {}
|
||||
public function getAttribute(int $name): mixed {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.2.0)<br/>
|
||||
|
@ -1778,7 +1788,7 @@ class PDOStatement implements IteratorAggregate
|
|||
*/
|
||||
#[TentativeType]
|
||||
#[ArrayShape(["name" => "string", "len" => "int", "precision" => "int", "oci:decl_type" => "int|string", "native_type" => "string", "scale" => "int", "flags" => "array", "pdo_type" => "int"])]
|
||||
public function getColumnMeta($column): array|false {}
|
||||
public function getColumnMeta(int $column): array|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.2.0)<br/>
|
||||
|
@ -1787,13 +1797,13 @@ class PDOStatement implements IteratorAggregate
|
|||
* @param int $mode <p>
|
||||
* The fetch mode must be one of the PDO::FETCH_* constants.
|
||||
* </p>
|
||||
* @param null|string|object $className [optional] <p>
|
||||
* @param string|object|null $className [optional] <p>
|
||||
* Class name or object
|
||||
* </p>
|
||||
* @param array $params [optional] <p> Constructor arguments. </p>
|
||||
* @param mixed ...$params <p> Constructor arguments. </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function setFetchMode($mode, $className = null, array $params = []) {}
|
||||
public function setFetchMode($mode, $className = null, ...$params) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 0.2.0)<br/>
|
||||
|
@ -1825,6 +1835,12 @@ class PDOStatement implements IteratorAggregate
|
|||
final public function __wakeup() {}
|
||||
|
||||
final public function __sleep() {}
|
||||
|
||||
/**
|
||||
* @return Iterator
|
||||
* @since 8.0
|
||||
*/
|
||||
public function getIterator(): Iterator {}
|
||||
}
|
||||
|
||||
final class PDORow
|
||||
|
|
|
@ -52,7 +52,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @throws BadMethodCallException If called twice.
|
||||
* @throws UnexpectedValueException If the phar archive can't be opened.
|
||||
*/
|
||||
public function __construct($filename, $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO, $alias = null) {}
|
||||
public function __construct(string $filename, int $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO, string|null $alias = null) {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.0.0)<br/>
|
||||
|
@ -302,7 +302,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* </p>
|
||||
* @return void No value is returned.
|
||||
*/
|
||||
final public static function webPhar(?string $alias = null, ?string $index = 'index.php', string $fileNotFoundScript = null, array $mimeTypes = null, ?callable $rewrite = null): void {}
|
||||
final public static function webPhar(?string $alias = null, ?string $index = 'index.php', string|null $fileNotFoundScript = null, array $mimeTypes = null, ?callable $rewrite = null): void {}
|
||||
|
||||
public function __destruct() {}
|
||||
|
||||
|
@ -316,7 +316,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return void no return value, exception is thrown on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function addEmptyDir($directory = ''): void {}
|
||||
public function addEmptyDir(string $directory): void {}
|
||||
|
||||
/**
|
||||
* (Unknown)<br/>
|
||||
|
@ -332,7 +332,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return void no return value, exception is thrown on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function addFile($filename, $localName = null): void {}
|
||||
public function addFile(string $filename, string|null $localName = null): void {}
|
||||
|
||||
/**
|
||||
* (Unknown)<br/>
|
||||
|
@ -347,7 +347,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return void no return value, exception is thrown on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function addFromString($localName, $contents = ''): void {}
|
||||
public function addFromString(string $localName, string $contents): void {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -367,7 +367,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* filesystem.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function buildFromDirectory($directory, $pattern = null): array {}
|
||||
public function buildFromDirectory(string $directory, string $pattern = null): array {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -386,7 +386,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* filesystem.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function buildFromIterator(Traversable $iterator, $baseDirectory = null): array {}
|
||||
public function buildFromIterator(Traversable $iterator, string|null $baseDirectory = null): array {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -400,7 +400,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function compressFiles($compression): void {}
|
||||
public function compressFiles(int $compression): void {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -429,7 +429,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return static|null a <b>Phar</b> object.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function compress($compression, $extension = null): ?Phar {}
|
||||
public function compress(int $compression, string|null $extension = null): ?Phar {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -445,7 +445,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return static|null A <b>Phar</b> object is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function decompress($extension = null): ?Phar {}
|
||||
public function decompress(string|null $extension = null): ?Phar {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -479,7 +479,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* exception on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function convertToExecutable($format = 9021976, $compression = 9021976, $extension = null): ?Phar {}
|
||||
public function convertToExecutable(int|null $format = 9021976, int|null $compression = 9021976, string|null $extension = null): ?Phar {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -511,7 +511,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* exception on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function convertToData($format = 9021976, $compression = 9021976, $extension = null): ?PharData {}
|
||||
public function convertToData(int|null $format = 9021976, int|null $compression = 9021976, string|null $extension = null): ?PharData {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -522,7 +522,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return bool returns <b>TRUE</b> on success, but it is safer to encase method call in a
|
||||
* try/catch block and assume success if no exception is thrown.
|
||||
*/
|
||||
public function copy($to, $from) {}
|
||||
public function copy(string $to, string $from) {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.0.0)<br/>
|
||||
|
@ -533,7 +533,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* if none.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function count(): int {}
|
||||
public function count(int $mode = COUNT_NORMAL): int {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -545,7 +545,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return bool returns <b>TRUE</b> on success, but it is better to check for thrown exception,
|
||||
* and assume success if none is thrown.
|
||||
*/
|
||||
public function delete($localName) {}
|
||||
public function delete(string $localName) {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.2.0)<br/>
|
||||
|
@ -573,7 +573,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* and assume success if none is thrown.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function extractTo($directory, $files = null, $overwrite = false): bool {}
|
||||
public function extractTo(string $directory, array|string|null $files = null, bool $overwrite = false): bool {}
|
||||
|
||||
/**
|
||||
* @return string|null
|
||||
|
@ -592,7 +592,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* or <b>NULL</b> if no meta-data is stored.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getMetadata(): mixed {}
|
||||
public function getMetadata(array $unserializeOptions = []): mixed {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.0.0)<br/>
|
||||
|
@ -681,7 +681,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return bool <b>TRUE</b> if the phar archive matches the file format requested by the parameter
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function isFileFormat($format): bool {}
|
||||
public function isFileFormat(int $format): bool {}
|
||||
|
||||
/**
|
||||
* (Unknown)<br/>
|
||||
|
@ -755,7 +755,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setAlias($alias): bool {}
|
||||
public function setAlias(string $alias): bool {}
|
||||
|
||||
/**
|
||||
* (Unknown)<br/>
|
||||
|
@ -770,7 +770,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setDefaultStub($index = null, $webIndex = null): bool {}
|
||||
public function setDefaultStub(string|null $index = null, string|null $webIndex = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.0.0)<br/>
|
||||
|
@ -782,7 +782,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setMetadata($metadata): void {}
|
||||
public function setMetadata(mixed $metadata): void {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.1.0)<br/>
|
||||
|
@ -808,7 +808,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setSignatureAlgorithm($algo, $privateKey = null): void {}
|
||||
public function setSignatureAlgorithm(int $algo, string|null $privateKey = null): void {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.0.0)<br/>
|
||||
|
@ -822,7 +822,7 @@ class Phar extends RecursiveDirectoryIterator implements RecursiveIterator, Seek
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function setStub($stub, $length = -1) {}
|
||||
public function setStub($stub, int $length = -1) {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.0.0)<br/>
|
||||
|
@ -941,7 +941,7 @@ class PharData extends Phar
|
|||
* available within the <b>Phar</b> class.
|
||||
* </p>
|
||||
*/
|
||||
public function __construct($filename, $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO, $alias = null, $format = Phar::TAR) {}
|
||||
public function __construct(string $filename, int $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO, string|null $alias = null, int $format = Phar::TAR) {}
|
||||
|
||||
/**
|
||||
* @param string $localName
|
||||
|
@ -1067,7 +1067,7 @@ class PharFileInfo extends SplFileInfo
|
|||
* the entry should be phar://boo.phar/my/file.php.
|
||||
* </p>
|
||||
*/
|
||||
public function __construct($filename) {}
|
||||
public function __construct(string $filename) {}
|
||||
|
||||
public function __destruct() {}
|
||||
|
||||
|
@ -1081,7 +1081,7 @@ class PharFileInfo extends SplFileInfo
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function chmod($perms): void {}
|
||||
public function chmod(int $perms): void {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -1090,7 +1090,7 @@ class PharFileInfo extends SplFileInfo
|
|||
* @param int $compression
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function compress($compression) {}
|
||||
public function compress(int $compression) {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 2.0.0)<br/>
|
||||
|
@ -1144,7 +1144,7 @@ class PharFileInfo extends SplFileInfo
|
|||
* or <b>NULL</b> if no meta-data is stored.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getMetadata(): mixed {}
|
||||
public function getMetadata(array $unserializeOptions = []): mixed {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.0.0)<br/>
|
||||
|
@ -1175,7 +1175,7 @@ class PharFileInfo extends SplFileInfo
|
|||
* @return bool <b>TRUE</b> if the file is compressed within the Phar archive, <b>FALSE</b> if not.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function isCompressed($compression = 9021976): bool {}
|
||||
public function isCompressed(int|null $compression = 9021976): bool {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL phar >= 1.0.0)<br/>
|
||||
|
@ -1196,5 +1196,5 @@ class PharFileInfo extends SplFileInfo
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setMetadata($metadata): void {}
|
||||
public function setMetadata(mixed $metadata): void {}
|
||||
}
|
||||
|
|
|
@ -10,6 +10,7 @@ namespace JetBrains\PHPStormStub;
|
|||
final class PhpStormStubsMap
|
||||
{
|
||||
const CLASSES = array (
|
||||
'AddressInfo' => 'sockets/sockets.php',
|
||||
'Aerospike' => 'aerospike/aerospike.php',
|
||||
'Aerospike\\Bytes' => 'aerospike/Bytes.php',
|
||||
'AppendIterator' => 'SPL/SPL.php',
|
||||
|
@ -19,6 +20,7 @@ const CLASSES = array (
|
|||
'ArrayIterator' => 'SPL/SPL.php',
|
||||
'ArrayObject' => 'SPL/SPL.php',
|
||||
'AssertionError' => 'standard/standard_9.php',
|
||||
'Attribute' => 'Core/Core_c.php',
|
||||
'BadFunctionCallException' => 'SPL/SPL.php',
|
||||
'BadMethodCallException' => 'SPL/SPL.php',
|
||||
'CURLFile' => 'curl/curl.php',
|
||||
|
@ -29,9 +31,13 @@ const CLASSES = array (
|
|||
'Collator' => 'intl/intl.php',
|
||||
'CompileError' => 'Core/Core_c.php',
|
||||
'Countable' => 'Core/Core_c.php',
|
||||
'CurlHandle' => 'curl/curl.php',
|
||||
'CurlMultiHandle' => 'curl/curl.php',
|
||||
'CurlShareHandle' => 'curl/curl.php',
|
||||
'DOMAttr' => 'dom/dom_c.php',
|
||||
'DOMCdataSection' => 'dom/dom_c.php',
|
||||
'DOMCharacterData' => 'dom/dom_c.php',
|
||||
'DOMChildNode' => 'dom/dom_c.php',
|
||||
'DOMComment' => 'dom/dom_c.php',
|
||||
'DOMConfiguration' => 'dom/dom_c.php',
|
||||
'DOMDocument' => 'dom/dom_c.php',
|
||||
|
@ -53,6 +59,7 @@ const CLASSES = array (
|
|||
'DOMNode' => 'dom/dom_c.php',
|
||||
'DOMNodeList' => 'dom/dom_c.php',
|
||||
'DOMNotation' => 'dom/dom_c.php',
|
||||
'DOMParentNode' => 'dom/dom_c.php',
|
||||
'DOMProcessingInstruction' => 'dom/dom_c.php',
|
||||
'DOMStringExtend' => 'dom/dom_c.php',
|
||||
'DOMStringList' => 'dom/dom_c.php',
|
||||
|
@ -66,6 +73,7 @@ const CLASSES = array (
|
|||
'DateTimeImmutable' => 'date/date_c.php',
|
||||
'DateTimeInterface' => 'date/date_c.php',
|
||||
'DateTimeZone' => 'date/date_c.php',
|
||||
'DeflateContext' => 'zlib/zlib.php',
|
||||
'Directory' => 'standard/standard_0.php',
|
||||
'DirectoryIterator' => 'SPL/SPL_c1.php',
|
||||
'DivisionByZeroError' => 'Core/Core_c.php',
|
||||
|
@ -79,10 +87,13 @@ const CLASSES = array (
|
|||
'FilesystemIterator' => 'SPL/SPL_c1.php',
|
||||
'FilterIterator' => 'SPL/SPL.php',
|
||||
'GMP' => 'gmp/gmp.php',
|
||||
'GdImage' => 'gd/gd.php',
|
||||
'Generator' => 'standard/_types.php',
|
||||
'GlobIterator' => 'SPL/SPL_c1.php',
|
||||
'HashContext' => 'hash/hash.php',
|
||||
'InfiniteIterator' => 'SPL/SPL.php',
|
||||
'InflateContext' => 'zlib/zlib.php',
|
||||
'InternalIterator' => 'Core/Core_c.php',
|
||||
'IntlBreakIterator' => 'intl/intl.php',
|
||||
'IntlCalendar' => 'intl/intl.php',
|
||||
'IntlChar' => 'intl/IntlChar.php',
|
||||
|
@ -111,8 +122,11 @@ const CLASSES = array (
|
|||
'NoRewindIterator' => 'SPL/SPL.php',
|
||||
'Normalizer' => 'intl/intl.php',
|
||||
'NumberFormatter' => 'intl/intl.php',
|
||||
'OCI_Collection' => 'oci8/oci8.php',
|
||||
'OCI_Lob' => 'oci8/oci8.php',
|
||||
'OCICollection' => 'oci8/oci8v3.php',
|
||||
'OCILob' => 'oci8/oci8v3.php',
|
||||
'OpenSSLAsymmetricKey' => 'openssl/openssl.php',
|
||||
'OpenSSLCertificate' => 'openssl/openssl.php',
|
||||
'OpenSSLCertificateSigningRequest' => 'openssl/openssl.php',
|
||||
'OutOfBoundsException' => 'SPL/SPL.php',
|
||||
'OutOfRangeException' => 'SPL/SPL.php',
|
||||
'OuterIterator' => 'SPL/SPL.php',
|
||||
|
@ -127,6 +141,7 @@ const CLASSES = array (
|
|||
'PharData' => 'Phar/Phar.php',
|
||||
'PharException' => 'Phar/Phar.php',
|
||||
'PharFileInfo' => 'Phar/Phar.php',
|
||||
'PhpToken' => 'tokenizer/PhpToken.php',
|
||||
'RangeException' => 'SPL/SPL.php',
|
||||
'RecursiveArrayIterator' => 'SPL/SPL.php',
|
||||
'RecursiveCachingIterator' => 'SPL/SPL.php',
|
||||
|
@ -138,6 +153,7 @@ const CLASSES = array (
|
|||
'RecursiveRegexIterator' => 'SPL/SPL.php',
|
||||
'RecursiveTreeIterator' => 'SPL/SPL.php',
|
||||
'Reflection' => 'Reflection/Reflection.php',
|
||||
'ReflectionAttribute' => 'Reflection/ReflectionAttribute.php',
|
||||
'ReflectionClass' => 'Reflection/ReflectionClass.php',
|
||||
'ReflectionClassConstant' => 'Reflection/ReflectionClassConstant.php',
|
||||
'ReflectionException' => 'Reflection/ReflectionException.php',
|
||||
|
@ -152,6 +168,7 @@ const CLASSES = array (
|
|||
'ReflectionProperty' => 'Reflection/ReflectionProperty.php',
|
||||
'ReflectionReference' => 'Reflection/ReflectionReference.php',
|
||||
'ReflectionType' => 'Reflection/ReflectionType.php',
|
||||
'ReflectionUnionType' => 'Reflection/ReflectionUnionType.php',
|
||||
'ReflectionZendExtension' => 'Reflection/ReflectionZendExtension.php',
|
||||
'Reflector' => 'Reflection/Reflector.php',
|
||||
'RegexIterator' => 'SPL/SPL.php',
|
||||
|
@ -168,6 +185,7 @@ const CLASSES = array (
|
|||
'SessionHandlerInterface' => 'session/SessionHandler.php',
|
||||
'SessionIdInterface' => 'session/SessionHandler.php',
|
||||
'SessionUpdateTimestampHandlerInterface' => 'session/SessionHandler.php',
|
||||
'Shmop' => 'shmop/shmop.php',
|
||||
'SimpleXMLElement' => 'SimpleXML/SimpleXML.php',
|
||||
'SimpleXMLIterator' => 'SimpleXML/SimpleXML.php',
|
||||
'SoapClient' => 'soap/soap.php',
|
||||
|
@ -176,6 +194,7 @@ const CLASSES = array (
|
|||
'SoapParam' => 'soap/soap.php',
|
||||
'SoapServer' => 'soap/soap.php',
|
||||
'SoapVar' => 'soap/soap.php',
|
||||
'Socket' => 'sockets/sockets.php',
|
||||
'SodiumException' => 'sodium/sodium.php',
|
||||
'SplDoublyLinkedList' => 'SPL/SPL_c1.php',
|
||||
'SplFileInfo' => 'SPL/SPL_c1.php',
|
||||
|
@ -192,6 +211,10 @@ const CLASSES = array (
|
|||
'SplSubject' => 'SPL/SPL_c1.php',
|
||||
'SplTempFileObject' => 'SPL/SPL_c1.php',
|
||||
'Spoofchecker' => 'intl/intl.php',
|
||||
'Stringable' => 'Core/Core_c.php',
|
||||
'SysvMessageQueue' => 'sysvmsg/sysvmsg.php',
|
||||
'SysvSemaphore' => 'sysvsem/sysvsem.php',
|
||||
'SysvSharedMemory' => 'sysvshm/sysvshm.php',
|
||||
'Throwable' => 'Core/Core_c.php',
|
||||
'Transliterator' => 'intl/intl.php',
|
||||
'Traversable' => 'Core/Core_c.php',
|
||||
|
@ -199,8 +222,11 @@ const CLASSES = array (
|
|||
'UConverter' => 'intl/intl.php',
|
||||
'UnderflowException' => 'SPL/SPL.php',
|
||||
'UnexpectedValueException' => 'SPL/SPL.php',
|
||||
'UnhandledMatchError' => 'Core/Core_c.php',
|
||||
'ValueError' => 'Core/Core_c.php',
|
||||
'WeakMap' => 'Core/Core_c.php',
|
||||
'WeakReference' => 'Core/Core_c.php',
|
||||
'XMLParser' => 'xml/xml.php',
|
||||
'XMLReader' => 'xmlreader/xmlreader.php',
|
||||
'XMLWriter' => 'xmlwriter/xmlwriter.php',
|
||||
'XSLTProcessor' => 'xsl/xsl.php',
|
||||
|
@ -547,11 +573,13 @@ const FUNCTIONS = array (
|
|||
'enchant_broker_request_pwl_dict' => 'enchant/enchant.php',
|
||||
'enchant_broker_set_dict_path' => 'enchant/enchant.php',
|
||||
'enchant_broker_set_ordering' => 'enchant/enchant.php',
|
||||
'enchant_dict_add' => 'enchant/enchant.php',
|
||||
'enchant_dict_add_to_personal' => 'enchant/enchant.php',
|
||||
'enchant_dict_add_to_session' => 'enchant/enchant.php',
|
||||
'enchant_dict_check' => 'enchant/enchant.php',
|
||||
'enchant_dict_describe' => 'enchant/enchant.php',
|
||||
'enchant_dict_get_error' => 'enchant/enchant.php',
|
||||
'enchant_dict_is_added' => 'enchant/enchant.php',
|
||||
'enchant_dict_is_in_session' => 'enchant/enchant.php',
|
||||
'enchant_dict_quick_check' => 'enchant/enchant.php',
|
||||
'enchant_dict_store_replacement' => 'enchant/enchant.php',
|
||||
|
@ -628,6 +656,7 @@ const FUNCTIONS = array (
|
|||
'fbird_trans' => 'interbase/interbase.php',
|
||||
'fbird_wait_event' => 'interbase/interbase.php',
|
||||
'fclose' => 'standard/standard_5.php',
|
||||
'fdiv' => 'standard/standard_3.php',
|
||||
'feof' => 'standard/standard_5.php',
|
||||
'fflush' => 'standard/standard_5.php',
|
||||
'fgetc' => 'standard/standard_5.php',
|
||||
|
@ -737,6 +766,7 @@ const FUNCTIONS = array (
|
|||
'get_class_methods' => 'Core/Core.php',
|
||||
'get_class_vars' => 'Core/Core.php',
|
||||
'get_current_user' => 'standard/standard_3.php',
|
||||
'get_debug_type' => 'standard/standard_9.php',
|
||||
'get_declared_classes' => 'Core/Core.php',
|
||||
'get_declared_interfaces' => 'Core/Core.php',
|
||||
'get_declared_traits' => 'Core/Core.php',
|
||||
|
@ -756,11 +786,13 @@ const FUNCTIONS = array (
|
|||
'get_object_vars' => 'Core/Core.php',
|
||||
'get_parent_class' => 'Core/Core.php',
|
||||
'get_required_files' => 'Core/Core.php',
|
||||
'get_resource_id' => 'standard/standard_9.php',
|
||||
'get_resource_type' => 'Core/Core.php',
|
||||
'get_resources' => 'Core/Core.php',
|
||||
'getallheaders' => 'standard/standard_4.php',
|
||||
'getcwd' => 'standard/standard_7.php',
|
||||
'getdate' => 'date/date.php',
|
||||
'getdir' => 'standard/standard_7.php',
|
||||
'getenv' => 'standard/standard_3.php',
|
||||
'gethostbyaddr' => 'standard/standard_4.php',
|
||||
'gethostbyname' => 'standard/standard_4.php',
|
||||
|
@ -966,7 +998,6 @@ const FUNCTIONS = array (
|
|||
'idn_to_ascii' => 'intl/intl.php',
|
||||
'idn_to_utf8' => 'intl/intl.php',
|
||||
'ignore_user_abort' => 'standard/standard_4.php',
|
||||
'image2wbmp' => 'gd/gd.php',
|
||||
'image_type_to_extension' => 'standard/standard_0.php',
|
||||
'image_type_to_mime_type' => 'standard/standard_0.php',
|
||||
'imageaffine' => 'gd/gd.php',
|
||||
|
@ -1051,13 +1082,6 @@ const FUNCTIONS = array (
|
|||
'imagepalettetotruecolor' => 'gd/gd.php',
|
||||
'imagepng' => 'gd/gd.php',
|
||||
'imagepolygon' => 'gd/gd.php',
|
||||
'imagepsbbox' => 'gd/gd.php',
|
||||
'imagepsencodefont' => 'gd/gd.php',
|
||||
'imagepsextendfont' => 'gd/gd.php',
|
||||
'imagepsfreefont' => 'gd/gd.php',
|
||||
'imagepsloadfont' => 'gd/gd.php',
|
||||
'imagepsslantfont' => 'gd/gd.php',
|
||||
'imagepstext' => 'gd/gd.php',
|
||||
'imagerectangle' => 'gd/gd.php',
|
||||
'imageresolution' => 'gd/gd.php',
|
||||
'imagerotate' => 'gd/gd.php',
|
||||
|
@ -1110,7 +1134,6 @@ const FUNCTIONS = array (
|
|||
'imap_getannotation' => 'imap/imap.php',
|
||||
'imap_getmailboxes' => 'imap/imap.php',
|
||||
'imap_getsubscribed' => 'imap/imap.php',
|
||||
'imap_header' => 'imap/imap.php',
|
||||
'imap_headerinfo' => 'imap/imap.php',
|
||||
'imap_headers' => 'imap/imap.php',
|
||||
'imap_last_error' => 'imap/imap.php',
|
||||
|
@ -1305,7 +1328,6 @@ const FUNCTIONS = array (
|
|||
'jdtounix' => 'calendar/calendar.php',
|
||||
'jewishtojd' => 'calendar/calendar.php',
|
||||
'join' => 'standard/standard_1.php',
|
||||
'jpeg2wbmp' => 'gd/gd.php',
|
||||
'json_decode' => 'json/json.php',
|
||||
'json_encode' => 'json/json.php',
|
||||
'json_last_error' => 'json/json.php',
|
||||
|
@ -1330,6 +1352,7 @@ const FUNCTIONS = array (
|
|||
'ldap_control_paged_result' => 'ldap/ldap.php',
|
||||
'ldap_control_paged_result_response' => 'ldap/ldap.php',
|
||||
'ldap_count_entries' => 'ldap/ldap.php',
|
||||
'ldap_count_references' => 'ldap/ldap.php',
|
||||
'ldap_delete' => 'ldap/ldap.php',
|
||||
'ldap_delete_ext' => 'ldap/ldap.php',
|
||||
'ldap_dn2ufn' => 'ldap/ldap.php',
|
||||
|
@ -1971,6 +1994,11 @@ const FUNCTIONS = array (
|
|||
'opendir' => 'standard/standard_7.php',
|
||||
'openlog' => 'standard/standard_7.php',
|
||||
'openssl_cipher_iv_length' => 'openssl/openssl.php',
|
||||
'openssl_cms_decrypt' => 'openssl/openssl.php',
|
||||
'openssl_cms_encrypt' => 'openssl/openssl.php',
|
||||
'openssl_cms_read' => 'openssl/openssl.php',
|
||||
'openssl_cms_sign' => 'openssl/openssl.php',
|
||||
'openssl_cms_verify' => 'openssl/openssl.php',
|
||||
'openssl_csr_export' => 'openssl/openssl.php',
|
||||
'openssl_csr_export_to_file' => 'openssl/openssl.php',
|
||||
'openssl_csr_get_public_key' => 'openssl/openssl.php',
|
||||
|
@ -2197,7 +2225,6 @@ const FUNCTIONS = array (
|
|||
'phpinfo' => 'standard/standard_0.php',
|
||||
'phpversion' => 'standard/standard_0.php',
|
||||
'pi' => 'standard/standard_3.php',
|
||||
'png2wbmp' => 'gd/gd.php',
|
||||
'popen' => 'standard/standard_5.php',
|
||||
'pos' => 'standard/standard_9.php',
|
||||
'posix_access' => 'posix/posix.php',
|
||||
|
@ -2241,6 +2268,7 @@ const FUNCTIONS = array (
|
|||
'preg_filter' => 'pcre/pcre.php',
|
||||
'preg_grep' => 'pcre/pcre.php',
|
||||
'preg_last_error' => 'pcre/pcre.php',
|
||||
'preg_last_error_msg' => 'pcre/pcre.php',
|
||||
'preg_match' => 'pcre/pcre.php',
|
||||
'preg_match_all' => 'pcre/pcre.php',
|
||||
'preg_quote' => 'pcre/pcre.php',
|
||||
|
@ -2583,6 +2611,8 @@ const FUNCTIONS = array (
|
|||
'srand' => 'random/random.php',
|
||||
'sscanf' => 'standard/standard_2.php',
|
||||
'stat' => 'standard/standard_7.php',
|
||||
'str_contains' => 'Core/Core.php',
|
||||
'str_ends_with' => 'Core/Core.php',
|
||||
'str_getcsv' => 'standard/standard_2.php',
|
||||
'str_ireplace' => 'standard/standard_1.php',
|
||||
'str_pad' => 'standard/standard_2.php',
|
||||
|
@ -2591,6 +2621,7 @@ const FUNCTIONS = array (
|
|||
'str_rot13' => 'standard/standard_9.php',
|
||||
'str_shuffle' => 'standard/standard_1.php',
|
||||
'str_split' => 'standard/standard_1.php',
|
||||
'str_starts_with' => 'Core/Core.php',
|
||||
'str_word_count' => 'standard/standard_1.php',
|
||||
'strcasecmp' => 'Core/Core.php',
|
||||
'strchr' => 'standard/standard_2.php',
|
||||
|
@ -3724,6 +3755,7 @@ const CONSTANTS = array (
|
|||
'FILTER_SANITIZE_STRIPPED' => 'filter/filter.php',
|
||||
'FILTER_SANITIZE_URL' => 'filter/filter.php',
|
||||
'FILTER_UNSAFE_RAW' => 'filter/filter.php',
|
||||
'FILTER_VALIDATE_BOOL' => 'filter/filter.php',
|
||||
'FILTER_VALIDATE_BOOLEAN' => 'filter/filter.php',
|
||||
'FILTER_VALIDATE_DOMAIN' => 'filter/filter.php',
|
||||
'FILTER_VALIDATE_EMAIL' => 'filter/filter.php',
|
||||
|
@ -4580,8 +4612,19 @@ const CONSTANTS = array (
|
|||
'OPENSSL_CIPHER_RC2_128' => 'openssl/openssl.php',
|
||||
'OPENSSL_CIPHER_RC2_40' => 'openssl/openssl.php',
|
||||
'OPENSSL_CIPHER_RC2_64' => 'openssl/openssl.php',
|
||||
'OPENSSL_CMS_BINARY' => 'openssl/openssl.php',
|
||||
'OPENSSL_CMS_DETACHED' => 'openssl/openssl.php',
|
||||
'OPENSSL_CMS_NOATTR' => 'openssl/openssl.php',
|
||||
'OPENSSL_CMS_NOCERTS' => 'openssl/openssl.php',
|
||||
'OPENSSL_CMS_NOINTERN' => 'openssl/openssl.php',
|
||||
'OPENSSL_CMS_NOSIGS' => 'openssl/openssl.php',
|
||||
'OPENSSL_CMS_NOVERIFY' => 'openssl/openssl.php',
|
||||
'OPENSSL_CMS_TEXT' => 'openssl/openssl.php',
|
||||
'OPENSSL_DEFAULT_STREAM_CIPHERS' => 'openssl/openssl.php',
|
||||
'OPENSSL_DONT_ZERO_PAD_KEY' => 'openssl/openssl.php',
|
||||
'OPENSSL_ENCODING_DER' => 'openssl/openssl.php',
|
||||
'OPENSSL_ENCODING_PEM' => 'openssl/openssl.php',
|
||||
'OPENSSL_ENCODING_SMIME' => 'openssl/openssl.php',
|
||||
'OPENSSL_KEYTYPE_DH' => 'openssl/openssl.php',
|
||||
'OPENSSL_KEYTYPE_DSA' => 'openssl/openssl.php',
|
||||
'OPENSSL_KEYTYPE_EC' => 'openssl/openssl.php',
|
||||
|
@ -5634,6 +5677,7 @@ const CONSTANTS = array (
|
|||
'T_ARRAY' => 'tokenizer/tokenizer.php',
|
||||
'T_ARRAY_CAST' => 'tokenizer/tokenizer.php',
|
||||
'T_AS' => 'tokenizer/tokenizer.php',
|
||||
'T_ATTRIBUTE' => 'tokenizer/tokenizer.php',
|
||||
'T_BAD_CHARACTER' => 'tokenizer/tokenizer.php',
|
||||
'T_BOOLEAN_AND' => 'tokenizer/tokenizer.php',
|
||||
'T_BOOLEAN_OR' => 'tokenizer/tokenizer.php',
|
||||
|
@ -5725,9 +5769,13 @@ const CONSTANTS = array (
|
|||
'T_MOD_EQUAL' => 'tokenizer/tokenizer.php',
|
||||
'T_MUL_EQUAL' => 'tokenizer/tokenizer.php',
|
||||
'T_NAMESPACE' => 'tokenizer/tokenizer.php',
|
||||
'T_NAME_FULLY_QUALIFIED' => 'tokenizer/tokenizer.php',
|
||||
'T_NAME_QUALIFIED' => 'tokenizer/tokenizer.php',
|
||||
'T_NAME_RELATIVE' => 'tokenizer/tokenizer.php',
|
||||
'T_NEW' => 'tokenizer/tokenizer.php',
|
||||
'T_NS_C' => 'tokenizer/tokenizer.php',
|
||||
'T_NS_SEPARATOR' => 'tokenizer/tokenizer.php',
|
||||
'T_NULLSAFE_OBJECT_OPERATOR' => 'tokenizer/tokenizer.php',
|
||||
'T_NUM_STRING' => 'tokenizer/tokenizer.php',
|
||||
'T_OBJECT_CAST' => 'tokenizer/tokenizer.php',
|
||||
'T_OBJECT_OPERATOR' => 'tokenizer/tokenizer.php',
|
||||
|
|
|
@ -18,7 +18,7 @@ class Reflection
|
|||
* @return string[] An array of modifier names.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getModifierNames($modifiers): array {}
|
||||
public static function getModifierNames(int $modifiers): array {}
|
||||
|
||||
/**
|
||||
* Exports
|
||||
|
|
|
@ -0,0 +1,83 @@
|
|||
<?php
|
||||
|
||||
use JetBrains\PhpStorm\Pure;
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*
|
||||
* @template T of object
|
||||
*/
|
||||
class ReflectionAttribute implements Reflector
|
||||
{
|
||||
/**
|
||||
* Indicates that the search for a suitable attribute should not be by
|
||||
* strict comparison, but by the inheritance chain.
|
||||
*
|
||||
* Used for the argument of flags of the "getAttribute" method.
|
||||
*
|
||||
* @since 8.0
|
||||
*/
|
||||
public const IS_INSTANCEOF = 2;
|
||||
|
||||
/**
|
||||
* ReflectionAttribute cannot be created explicitly.
|
||||
* @since 8.0
|
||||
*/
|
||||
private function __construct() {}
|
||||
|
||||
public static function export() {}
|
||||
|
||||
/**
|
||||
* Gets attribute name
|
||||
*
|
||||
* @return string The name of the attribute parameter.
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function getName(): string {}
|
||||
|
||||
/**
|
||||
* Returns the target of the attribute as a bit mask format.
|
||||
*
|
||||
* @return int
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function getTarget(): int {}
|
||||
|
||||
/**
|
||||
* Returns {@see true} if the attribute is repeated.
|
||||
*
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function isRepeated(): bool {}
|
||||
|
||||
/**
|
||||
* Gets list of passed attribute's arguments.
|
||||
*
|
||||
* @return array
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function getArguments(): array {}
|
||||
|
||||
/**
|
||||
* Creates a new instance of the attribute with passed arguments
|
||||
*
|
||||
* @return T
|
||||
* @since 8.0
|
||||
*/
|
||||
public function newInstance(): object {}
|
||||
|
||||
public function __toString(): string {}
|
||||
|
||||
/**
|
||||
* ReflectionAttribute cannot be cloned
|
||||
*
|
||||
* @return void
|
||||
* @since 8.0
|
||||
*/
|
||||
private function __clone(): void {}
|
||||
}
|
|
@ -48,7 +48,7 @@ class ReflectionClass implements Reflector
|
|||
* the class to reflect, or an object.
|
||||
* @throws ReflectionException if the class does not exist.
|
||||
*/
|
||||
public function __construct($objectOrClass) {}
|
||||
public function __construct(object|string $objectOrClass) {}
|
||||
|
||||
/**
|
||||
* Exports a reflected class
|
||||
|
@ -186,7 +186,7 @@ class ReflectionClass implements Reflector
|
|||
* @return bool Returns {@see true} if it has the method, otherwise {@see false}
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function hasMethod($name): bool {}
|
||||
public function hasMethod(string $name): bool {}
|
||||
|
||||
/**
|
||||
* Gets a <b>ReflectionMethod</b> for a class method.
|
||||
|
@ -198,7 +198,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getMethod($name): ReflectionMethod {}
|
||||
public function getMethod(string $name): ReflectionMethod {}
|
||||
|
||||
/**
|
||||
* Gets an array of methods for the class.
|
||||
|
@ -211,7 +211,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getMethods($filter = null): array {}
|
||||
public function getMethods(int|null $filter = null): array {}
|
||||
|
||||
/**
|
||||
* Checks if property is defined
|
||||
|
@ -221,7 +221,7 @@ class ReflectionClass implements Reflector
|
|||
* @return bool Returns {@see true} if it has the property, otherwise {@see false}
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function hasProperty($name): bool {}
|
||||
public function hasProperty(string $name): bool {}
|
||||
|
||||
/**
|
||||
* Gets a <b>ReflectionProperty</b> for a class's property
|
||||
|
@ -233,7 +233,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getProperty($name): ReflectionProperty {}
|
||||
public function getProperty(string $name): ReflectionProperty {}
|
||||
|
||||
/**
|
||||
* Gets properties
|
||||
|
@ -246,7 +246,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getProperties($filter = null): array {}
|
||||
public function getProperties(int|null $filter = null): array {}
|
||||
|
||||
/**
|
||||
* Gets a ReflectionClassConstant for a class's property
|
||||
|
@ -270,7 +270,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getReflectionConstants(): array {}
|
||||
public function getReflectionConstants(?int $filter = ReflectionClassConstant::IS_PUBLIC|ReflectionClassConstant::IS_PROTECTED|ReflectionClassConstant::IS_PRIVATE): array {}
|
||||
|
||||
/**
|
||||
* Checks if constant is defined
|
||||
|
@ -280,7 +280,7 @@ class ReflectionClass implements Reflector
|
|||
* @return bool Returns {@see true} if the constant is defined, otherwise {@see false}
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function hasConstant($name): bool {}
|
||||
public function hasConstant(string $name): bool {}
|
||||
|
||||
/**
|
||||
* Gets constants
|
||||
|
@ -292,7 +292,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getConstants(): array {}
|
||||
public function getConstants(?int $filter = ReflectionClassConstant::IS_PUBLIC|ReflectionClassConstant::IS_PROTECTED|ReflectionClassConstant::IS_PRIVATE): array {}
|
||||
|
||||
/**
|
||||
* Gets defined constant
|
||||
|
@ -304,7 +304,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getConstant($name): mixed {}
|
||||
public function getConstant(string $name): mixed {}
|
||||
|
||||
/**
|
||||
* Gets the interfaces
|
||||
|
@ -436,7 +436,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function isInstance($object): bool {}
|
||||
public function isInstance(object $object): bool {}
|
||||
|
||||
/**
|
||||
* Creates a new class instance from given arguments.
|
||||
|
@ -499,7 +499,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function isSubclassOf($class): bool {}
|
||||
public function isSubclassOf(ReflectionClass|string $class): bool {}
|
||||
|
||||
/**
|
||||
* Gets static properties
|
||||
|
@ -524,7 +524,7 @@ class ReflectionClass implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getStaticPropertyValue($name, $default = null): mixed {}
|
||||
public function getStaticPropertyValue(string $name, mixed $default = null): mixed {}
|
||||
|
||||
/**
|
||||
* Sets static property value
|
||||
|
@ -535,7 +535,7 @@ class ReflectionClass implements Reflector
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setStaticPropertyValue($name, $value): void {}
|
||||
public function setStaticPropertyValue(string $name, mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Gets default properties
|
||||
|
@ -580,7 +580,7 @@ class ReflectionClass implements Reflector
|
|||
* @return bool Returns {@see true} on success or {@see false} on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function implementsInterface($interface): bool {}
|
||||
public function implementsInterface(ReflectionClass|string $interface): bool {}
|
||||
|
||||
/**
|
||||
* Gets a <b>ReflectionExtension</b> object for the extension which defined the class
|
||||
|
@ -633,6 +633,19 @@ class ReflectionClass implements Reflector
|
|||
#[TentativeType]
|
||||
public function getShortName(): string {}
|
||||
|
||||
/**
|
||||
* @template T
|
||||
*
|
||||
* Returns an array of class attributes.
|
||||
*
|
||||
* @param class-string<T>|null $name Name of an attribute class
|
||||
* @param int $flags Сriteria by which the attribute is searched.
|
||||
* @return ReflectionAttribute<T>[]
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function getAttributes(?string $name = null, int $flags = 0): array {}
|
||||
|
||||
/**
|
||||
* Clones object
|
||||
*
|
||||
|
|
|
@ -13,6 +13,27 @@ use JetBrains\PhpStorm\Pure;
|
|||
*/
|
||||
class ReflectionClassConstant implements Reflector
|
||||
{
|
||||
/**
|
||||
* Indicates that the constant is public.
|
||||
*
|
||||
* @since 8.0
|
||||
*/
|
||||
public const IS_PUBLIC = 1;
|
||||
|
||||
/**
|
||||
* Indicates that the constant is protected.
|
||||
*
|
||||
* @since 8.0
|
||||
*/
|
||||
public const IS_PROTECTED = 2;
|
||||
|
||||
/**
|
||||
* Indicates that the constant is private.
|
||||
*
|
||||
* @since 8.0
|
||||
*/
|
||||
public const IS_PRIVATE = 4;
|
||||
|
||||
/**
|
||||
* @var string Constant name, same as calling the {@see ReflectionClassConstant::getName()} method
|
||||
*/
|
||||
|
@ -40,7 +61,7 @@ class ReflectionClassConstant implements Reflector
|
|||
* @since 7.1
|
||||
* @link https://php.net/manual/en/reflectionclassconstant.construct.php
|
||||
*/
|
||||
public function __construct($class, string $constant) {}
|
||||
public function __construct(string|object $class, string $constant) {}
|
||||
|
||||
/**
|
||||
* @link https://php.net/manual/en/reflectionclassconstant.export.php
|
||||
|
@ -153,6 +174,19 @@ class ReflectionClassConstant implements Reflector
|
|||
*/
|
||||
public function __toString(): string {}
|
||||
|
||||
/**
|
||||
* @template T
|
||||
*
|
||||
* Returns an array of constant attributes.
|
||||
*
|
||||
* @param class-string<T>|null $name Name of an attribute class
|
||||
* @param int $flags Сriteria by which the attribute is searched.
|
||||
* @return ReflectionAttribute<T>[]
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function getAttributes(?string $name = null, int $flags = 0): array {}
|
||||
|
||||
/**
|
||||
* ReflectionClassConstant cannot be cloned
|
||||
*
|
||||
|
|
|
@ -25,7 +25,7 @@ class ReflectionExtension implements Reflector
|
|||
* @param string $name Name of the extension.
|
||||
* @throws ReflectionException if the extension does not exist.
|
||||
*/
|
||||
public function __construct($name) {}
|
||||
public function __construct(string $name) {}
|
||||
|
||||
/**
|
||||
* Exports a reflected extension.
|
||||
|
|
|
@ -33,7 +33,7 @@ class ReflectionFunction extends ReflectionFunctionAbstract
|
|||
* @param string|Closure $function The name of the function to reflect or a closure.
|
||||
* @throws ReflectionException if the function does not exist.
|
||||
*/
|
||||
public function __construct($function) {}
|
||||
public function __construct(Closure|string $function) {}
|
||||
|
||||
/**
|
||||
* Exports function
|
||||
|
@ -79,7 +79,7 @@ class ReflectionFunction extends ReflectionFunctionAbstract
|
|||
* @return mixed Returns the result of the invoked function call.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function invoke(...$args): mixed {}
|
||||
public function invoke(mixed ...$args): mixed {}
|
||||
|
||||
/**
|
||||
* Invokes function args
|
||||
|
|
|
@ -111,6 +111,15 @@ abstract class ReflectionFunctionAbstract implements Reflector
|
|||
#[TentativeType]
|
||||
public function getClosureScopeClass(): ?ReflectionClass {}
|
||||
|
||||
/**
|
||||
* @return ReflectionClass|null Returns the class on success or {@see null}
|
||||
* on failure.
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getClosureCalledClass(): ?ReflectionClass {}
|
||||
|
||||
/**
|
||||
* Gets doc comment
|
||||
*
|
||||
|
@ -225,7 +234,7 @@ abstract class ReflectionFunctionAbstract implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getReturnType(): ReflectionNamedType|null {}
|
||||
public function getReturnType(): ReflectionNamedType|ReflectionUnionType|null {}
|
||||
|
||||
/**
|
||||
* Gets function short name
|
||||
|
@ -277,6 +286,19 @@ abstract class ReflectionFunctionAbstract implements Reflector
|
|||
#[TentativeType]
|
||||
public function hasReturnType(): bool {}
|
||||
|
||||
/**
|
||||
* @template T
|
||||
*
|
||||
* Returns an array of function attributes.
|
||||
*
|
||||
* @param class-string<T>|null $name Name of an attribute class
|
||||
* @param int $flags Сriteria by which the attribute is searched.
|
||||
* @return ReflectionAttribute<T>[]
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function getAttributes(?string $name = null, int $flags = 0): array {}
|
||||
|
||||
/**
|
||||
* Clones function
|
||||
*
|
||||
|
|
|
@ -72,7 +72,7 @@ class ReflectionMethod extends ReflectionFunctionAbstract
|
|||
* classname or an object.
|
||||
* @throws ReflectionException if the class or method does not exist.
|
||||
*/
|
||||
public function __construct($objectOrMethod, $method = null) {}
|
||||
public function __construct(object|string $objectOrMethod, string|null $method = null) {}
|
||||
|
||||
/**
|
||||
* Export a reflection method.
|
||||
|
@ -189,7 +189,7 @@ class ReflectionMethod extends ReflectionFunctionAbstract
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getClosure($object = null): Closure {}
|
||||
public function getClosure(object|null $object = null): Closure {}
|
||||
|
||||
/**
|
||||
* Gets the method modifiers
|
||||
|
@ -241,7 +241,7 @@ class ReflectionMethod extends ReflectionFunctionAbstract
|
|||
* invocation failed.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function invokeArgs($object, array $args): mixed {}
|
||||
public function invokeArgs(object|null $object, array $args): mixed {}
|
||||
|
||||
/**
|
||||
* Gets declaring class for the reflected method.
|
||||
|
@ -274,5 +274,5 @@ class ReflectionMethod extends ReflectionFunctionAbstract
|
|||
* @since 5.3.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setAccessible($accessible): void {}
|
||||
public function setAccessible(bool $accessible): void {}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
<?php
|
||||
|
||||
use JetBrains\PhpStorm\Internal\TentativeType;
|
||||
use JetBrains\PhpStorm\Pure;
|
||||
|
||||
/**
|
||||
|
@ -16,4 +17,17 @@ class ReflectionNamedType extends ReflectionType
|
|||
*/
|
||||
#[Pure]
|
||||
public function getName() {}
|
||||
|
||||
/**
|
||||
* Checks if it is a built-in type
|
||||
*
|
||||
* @link https://php.net/manual/en/reflectionnamedtype.isbuiltin.php
|
||||
* @return bool Returns {@see true} if it's a built-in type, otherwise {@see false}
|
||||
*
|
||||
* @since 7.1 overrides the parent {@see ReflectionType::isBuiltin()} method.
|
||||
* @since 8.0 method was removed from the parent {@see ReflectionType} class.
|
||||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function isBuiltin(): bool {}
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@ class ReflectionObject extends ReflectionClass
|
|||
* @link https://php.net/manual/en/reflectionobject.construct.php
|
||||
* @param object $object An object instance.
|
||||
*/
|
||||
public function __construct($object) {}
|
||||
public function __construct(object $object) {}
|
||||
|
||||
/**
|
||||
* Export
|
||||
|
|
|
@ -28,7 +28,7 @@ class ReflectionParameter implements Reflector
|
|||
* of the parameter (starting with zero), or a the parameter name as string.
|
||||
* @throws ReflectionException if the function or parameter does not exist.
|
||||
*/
|
||||
public function __construct($function, $param) {}
|
||||
public function __construct($function, string|int $param) {}
|
||||
|
||||
/**
|
||||
* Exports
|
||||
|
@ -139,7 +139,7 @@ class ReflectionParameter implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getType(): ReflectionNamedType|null {}
|
||||
public function getType(): ReflectionNamedType|ReflectionUnionType|null {}
|
||||
|
||||
/**
|
||||
* Checks if parameter expects an array
|
||||
|
@ -256,6 +256,28 @@ class ReflectionParameter implements Reflector
|
|||
#[TentativeType]
|
||||
public function isVariadic(): bool {}
|
||||
|
||||
/**
|
||||
* Returns information about whether the parameter is a promoted.
|
||||
*
|
||||
* @return bool Returns {@see true} if the parameter promoted or {@see false} instead
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function isPromoted(): bool {}
|
||||
|
||||
/**
|
||||
* @template T
|
||||
*
|
||||
* Returns an array of parameter attributes.
|
||||
*
|
||||
* @param class-string<T>|null $name Name of an attribute class
|
||||
* @param int $flags Сriteria by which the attribute is searched.
|
||||
* @return ReflectionAttribute<T>[]
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function getAttributes(?string $name = null, int $flags = 0): array {}
|
||||
|
||||
/**
|
||||
* Clone
|
||||
*
|
||||
|
|
|
@ -61,7 +61,7 @@ class ReflectionProperty implements Reflector
|
|||
* @param string $property The name of the property being reflected.
|
||||
* @throws ReflectionException if the class or property does not exist.
|
||||
*/
|
||||
public function __construct($class, $property) {}
|
||||
public function __construct(object|string $class, string $property) {}
|
||||
|
||||
/**
|
||||
* Export
|
||||
|
@ -109,7 +109,7 @@ class ReflectionProperty implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getValue($object = null): mixed {}
|
||||
public function getValue(object|null $object = null): mixed {}
|
||||
|
||||
/**
|
||||
* Set property value
|
||||
|
@ -122,7 +122,7 @@ class ReflectionProperty implements Reflector
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setValue($objectOrValue, $value = null): void {}
|
||||
public function setValue(mixed $objectOrValue, mixed $value = null): void {}
|
||||
|
||||
/**
|
||||
* Checks if property is public
|
||||
|
@ -213,7 +213,7 @@ class ReflectionProperty implements Reflector
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setAccessible($accessible): void {}
|
||||
public function setAccessible(bool $accessible): void {}
|
||||
|
||||
/**
|
||||
* Gets property type
|
||||
|
@ -225,7 +225,7 @@ class ReflectionProperty implements Reflector
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getType(): ReflectionNamedType|null {}
|
||||
public function getType(): ReflectionNamedType|ReflectionUnionType|null {}
|
||||
|
||||
/**
|
||||
* Checks if property has type
|
||||
|
@ -250,6 +250,42 @@ class ReflectionProperty implements Reflector
|
|||
#[TentativeType]
|
||||
public function isInitialized(?object $object = null): bool {}
|
||||
|
||||
/**
|
||||
* Returns information about whether the property was promoted.
|
||||
*
|
||||
* @return bool Returns {@see true} if the property was promoted or {@see false} instead.
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function isPromoted(): bool {}
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
public function hasDefaultValue(): bool {}
|
||||
|
||||
/**
|
||||
* @return mixed
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getDefaultValue(): mixed {}
|
||||
|
||||
/**
|
||||
* @template T
|
||||
*
|
||||
* Returns an array of property attributes.
|
||||
*
|
||||
* @param class-string<T>|null $name Name of an attribute class
|
||||
* @param int $flags Сriteria by which the attribute is searched.
|
||||
* @return ReflectionAttribute<T>[]
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
public function getAttributes(?string $name = null, int $flags = 0): array {}
|
||||
|
||||
/**
|
||||
* Clone
|
||||
*
|
||||
|
|
|
@ -25,7 +25,7 @@ class ReflectionReference
|
|||
* @param int|string $key The key; either an integer or a string.
|
||||
* @return self|null
|
||||
*/
|
||||
public static function fromArrayElement(array $array, $key): ?ReflectionReference {}
|
||||
public static function fromArrayElement(array $array, string|int $key): ?ReflectionReference {}
|
||||
|
||||
/**
|
||||
* Returns unique identifier for the reference. The return value format is unspecified
|
||||
|
|
|
@ -10,7 +10,7 @@ use JetBrains\PhpStorm\Pure;
|
|||
* @link https://www.php.net/manual/en/class.reflectiontype.php
|
||||
* @since 7.0
|
||||
*/
|
||||
abstract class ReflectionType
|
||||
abstract class ReflectionType implements Stringable
|
||||
{
|
||||
/**
|
||||
* Checks if null is allowed
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
<?php
|
||||
|
||||
use JetBrains\PhpStorm\Pure;
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
class ReflectionUnionType extends ReflectionType
|
||||
{
|
||||
/**
|
||||
* Get list of named types of union type
|
||||
*
|
||||
* @return ReflectionNamedType[]
|
||||
*/
|
||||
#[Pure]
|
||||
public function getTypes(): array {}
|
||||
}
|
|
@ -24,7 +24,7 @@ class ReflectionZendExtension implements Reflector
|
|||
* @throws ReflectionException if the extension does not exist.
|
||||
* @since 5.4
|
||||
*/
|
||||
public function __construct($name) {}
|
||||
public function __construct(string $name) {}
|
||||
|
||||
/**
|
||||
* Exports a reflected zend extension.
|
||||
|
|
94
SPL/SPL.php
94
SPL/SPL.php
|
@ -57,7 +57,7 @@ interface SeekableIterator extends Iterator
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function seek($offset): void;
|
||||
public function seek(int $offset): void;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -240,7 +240,7 @@ class RecursiveCallbackFilterIterator extends CallbackFilterIterator implements
|
|||
* May be any valid callable value.
|
||||
* @link https://www.php.net/manual/en/recursivecallbackfilteriterator.construct.php
|
||||
*/
|
||||
public function __construct(RecursiveIterator $iterator, $callback) {}
|
||||
public function __construct(RecursiveIterator $iterator, callable $callback) {}
|
||||
|
||||
/**
|
||||
* Check whether the inner iterator's current element has children
|
||||
|
@ -293,7 +293,7 @@ class RecursiveIteratorIterator implements OuterIterator
|
|||
* @param int $flags [optional] A bitmask of special flags. See class constants for details.
|
||||
* @since 5.1.3
|
||||
*/
|
||||
public function __construct(Traversable $iterator, $mode = RecursiveIteratorIterator::LEAVES_ONLY, $flags = 0) {}
|
||||
public function __construct(Traversable $iterator, int $mode = RecursiveIteratorIterator::LEAVES_ONLY, int $flags = 0) {}
|
||||
|
||||
/**
|
||||
* Rewind the iterator to the first element of the top level inner iterator
|
||||
|
@ -350,7 +350,7 @@ class RecursiveIteratorIterator implements OuterIterator
|
|||
* @return RecursiveIterator|null The current active sub iterator.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getSubIterator($level): ?RecursiveIterator {}
|
||||
public function getSubIterator(int|null $level): ?RecursiveIterator {}
|
||||
|
||||
/**
|
||||
* Get inner iterator
|
||||
|
@ -426,7 +426,7 @@ class RecursiveIteratorIterator implements OuterIterator
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setMaxDepth($maxDepth = -1): void {}
|
||||
public function setMaxDepth(int $maxDepth = -1): void {}
|
||||
|
||||
/**
|
||||
* Get max depth
|
||||
|
@ -454,7 +454,7 @@ class IteratorIterator implements OuterIterator
|
|||
* @param Traversable $iterator
|
||||
* @param string|null $class [optional]
|
||||
*/
|
||||
public function __construct(Traversable $iterator) {}
|
||||
public function __construct(Traversable $iterator, ?string $class = '') {}
|
||||
|
||||
/**
|
||||
* Get the inner iterator
|
||||
|
@ -655,7 +655,7 @@ class LimitIterator extends IteratorIterator
|
|||
* @param int $offset [optional] The offset to start at. Must be zero or greater.
|
||||
* @param int $limit [optional] The number of items to iterate. Must be -1 or greater. -1, the default, means no limit.
|
||||
*/
|
||||
public function __construct(Iterator $iterator, $offset = 0, $limit = -1) {}
|
||||
public function __construct(Iterator $iterator, int $offset = 0, int $limit = -1) {}
|
||||
|
||||
/**
|
||||
* Rewind the iterator to the specified starting offset
|
||||
|
@ -704,7 +704,7 @@ class LimitIterator extends IteratorIterator
|
|||
* @return int the offset position after seeking.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function seek($offset): int {}
|
||||
public function seek(int $offset): int {}
|
||||
|
||||
/**
|
||||
* Return the current position
|
||||
|
@ -726,7 +726,7 @@ class LimitIterator extends IteratorIterator
|
|||
* This object supports cached iteration over another iterator.
|
||||
* @link https://php.net/manual/en/class.cachingiterator.php
|
||||
*/
|
||||
class CachingIterator extends IteratorIterator implements ArrayAccess, Countable
|
||||
class CachingIterator extends IteratorIterator implements ArrayAccess, Countable, Stringable
|
||||
{
|
||||
/**
|
||||
* String conversion flag (mutually exclusive): Uses the current element for the iterator's string conversion.
|
||||
|
@ -767,7 +767,7 @@ class CachingIterator extends IteratorIterator implements ArrayAccess, Countable
|
|||
* @param Iterator $iterator The iterator to cache.
|
||||
* @param int $flags [optional] A bitmask of flags. See CachingIterator class constants for details.
|
||||
*/
|
||||
public function __construct(Iterator $iterator, $flags = CachingIterator::CALL_TOSTRING) {}
|
||||
public function __construct(Iterator $iterator, int $flags = CachingIterator::CALL_TOSTRING) {}
|
||||
|
||||
/**
|
||||
* Rewind the iterator
|
||||
|
@ -845,7 +845,7 @@ class CachingIterator extends IteratorIterator implements ArrayAccess, Countable
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setFlags($flags): void {}
|
||||
public function setFlags(int $flags): void {}
|
||||
|
||||
/**
|
||||
* Internal cache array index to retrieve.
|
||||
|
@ -866,7 +866,7 @@ class CachingIterator extends IteratorIterator implements ArrayAccess, Countable
|
|||
* @throws BadMethodCallException when the {@see CachingIterator::FULL_CACHE} flag is not being used.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetSet($key, $value): void {}
|
||||
public function offsetSet($key, mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Remove an element from the internal cache array.
|
||||
|
@ -920,7 +920,7 @@ class RecursiveCachingIterator extends CachingIterator implements RecursiveItera
|
|||
* @param Iterator $iterator The iterator to cache.
|
||||
* @param int $flags [optional] A bitmask of flags. See CachingIterator class constants for details.
|
||||
*/
|
||||
public function __construct(Iterator $iterator, $flags = CachingIterator::CALL_TOSTRING) {}
|
||||
public function __construct(Iterator $iterator, int $flags = CachingIterator::CALL_TOSTRING) {}
|
||||
|
||||
/**
|
||||
* Check whether the current element of the inner iterator has children
|
||||
|
@ -1157,7 +1157,7 @@ class RegexIterator extends FilterIterator
|
|||
* @param int $flags [optional] Special flags, see RegexIterator::setFlags() for a list of available flags.
|
||||
* @param int $pregFlags [optional] The regular expression flags. These flags depend on the operation mode parameter
|
||||
*/
|
||||
public function __construct(Iterator $iterator, $pattern, $mode = RegexIterator::MATCH, $flags = 0, $pregFlags = 0) {}
|
||||
public function __construct(Iterator $iterator, string $pattern, int $mode = RegexIterator::MATCH, int $flags = 0, int $pregFlags = 0) {}
|
||||
|
||||
/**
|
||||
* Get accept status
|
||||
|
@ -1226,7 +1226,7 @@ class RegexIterator extends FilterIterator
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setMode($mode): void {}
|
||||
public function setMode(int $mode): void {}
|
||||
|
||||
/**
|
||||
* Get flags
|
||||
|
@ -1263,7 +1263,7 @@ class RegexIterator extends FilterIterator
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setFlags($flags): void {}
|
||||
public function setFlags(int $flags): void {}
|
||||
|
||||
/**
|
||||
* Returns current regular expression
|
||||
|
@ -1292,7 +1292,7 @@ class RegexIterator extends FilterIterator
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setPregFlags($pregFlags): void {}
|
||||
public function setPregFlags(int $pregFlags): void {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1310,7 +1310,7 @@ class RecursiveRegexIterator extends RegexIterator implements RecursiveIterator
|
|||
* @param int $flags [optional] Special flags, see RegexIterator::setFlags() for a list of available flags.
|
||||
* @param int $pregFlags [optional] The regular expression flags. These flags depend on the operation mode parameter
|
||||
*/
|
||||
public function __construct(RecursiveIterator $iterator, $pattern, $mode = RegexIterator::MATCH, $flags = 0, $pregFlags = 0) {}
|
||||
public function __construct(RecursiveIterator $iterator, string $pattern, int $mode = RegexIterator::MATCH, int $flags = 0, int $pregFlags = 0) {}
|
||||
|
||||
/**
|
||||
* Returns whether an iterator can be obtained for the current entry.
|
||||
|
@ -1352,7 +1352,7 @@ class RecursiveTreeIterator extends RecursiveIteratorIterator
|
|||
* @param int $cachingIteratorFlags [optional] Flags to affect the behavior of the {@see RecursiveCachingIterator} used internally.
|
||||
* @param int $mode [optional] Flags to affect the behavior of the {@see RecursiveIteratorIterator} used internally.
|
||||
*/
|
||||
public function __construct($iterator, $flags = self::BYPASS_KEY, $cachingIteratorFlags = CachingIterator::CATCH_GET_CHILD, $mode = RecursiveIteratorIterator::SELF_FIRST) {}
|
||||
public function __construct($iterator, int $flags = self::BYPASS_KEY, int $cachingIteratorFlags = CachingIterator::CATCH_GET_CHILD, int $mode = RecursiveIteratorIterator::SELF_FIRST) {}
|
||||
|
||||
/**
|
||||
* Rewind iterator
|
||||
|
@ -1466,7 +1466,7 @@ class RecursiveTreeIterator extends RecursiveIteratorIterator
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setPrefixPart($part, $value): void {}
|
||||
public function setPrefixPart(int $part, string $value): void {}
|
||||
|
||||
/**
|
||||
* Get current entry
|
||||
|
@ -1508,7 +1508,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @param int $flags Flags to control the behaviour of the ArrayObject object.
|
||||
* @param string $iteratorClass Specify the class that will be used for iteration of the ArrayObject object. ArrayIterator is the default class used.
|
||||
*/
|
||||
public function __construct($array = [], $flags = 0, $iteratorClass = 'ArrayIterator') {}
|
||||
public function __construct(object|array $array = [], int $flags = 0, string $iteratorClass = 'ArrayIterator') {}
|
||||
|
||||
/**
|
||||
* Returns whether the requested index exists
|
||||
|
@ -1519,7 +1519,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return bool true if the requested index exists, otherwise false
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetExists($key): bool {}
|
||||
public function offsetExists(mixed $key): bool {}
|
||||
|
||||
/**
|
||||
* Returns the value at the specified index
|
||||
|
@ -1530,7 +1530,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return mixed|false The value at the specified index or false.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetGet($key): mixed {}
|
||||
public function offsetGet(mixed $key): mixed {}
|
||||
|
||||
/**
|
||||
* Sets the value at the specified index to newval
|
||||
|
@ -1544,7 +1544,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetSet($key, $value): void {}
|
||||
public function offsetSet(mixed $key, mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Unsets the value at the specified index
|
||||
|
@ -1555,7 +1555,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetUnset($key): void {}
|
||||
public function offsetUnset(mixed $key): void {}
|
||||
|
||||
/**
|
||||
* Appends the value
|
||||
|
@ -1566,7 +1566,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function append($value): void {}
|
||||
public function append(mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Creates a copy of the ArrayObject.
|
||||
|
@ -1630,7 +1630,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setFlags($flags): void {}
|
||||
public function setFlags(int $flags): void {}
|
||||
|
||||
/**
|
||||
* Sort the entries by value
|
||||
|
@ -1639,7 +1639,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function asort(): bool {}
|
||||
public function asort(int $flags = SORT_REGULAR): bool {}
|
||||
|
||||
/**
|
||||
* Sort the entries by key
|
||||
|
@ -1648,7 +1648,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function ksort(): bool {}
|
||||
public function ksort(int $flags = SORT_REGULAR): bool {}
|
||||
|
||||
/**
|
||||
* Sort the entries with a user-defined comparison function and maintain key association
|
||||
|
@ -1664,7 +1664,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function uasort($callback): bool {}
|
||||
public function uasort(callable $callback): bool {}
|
||||
|
||||
/**
|
||||
* Sort the entries by keys using a user-defined comparison function
|
||||
|
@ -1683,7 +1683,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function uksort($callback): bool {}
|
||||
public function uksort(callable $callback): bool {}
|
||||
|
||||
/**
|
||||
* Sort entries using a "natural order" algorithm
|
||||
|
@ -1710,7 +1710,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function unserialize($data): void {}
|
||||
public function unserialize(string $data): void {}
|
||||
|
||||
/**
|
||||
* Serialize an ArrayObject
|
||||
|
@ -1758,7 +1758,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return array the old array.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function exchangeArray($array): array {}
|
||||
public function exchangeArray(object|array $array): array {}
|
||||
|
||||
/**
|
||||
* Sets the iterator classname for the ArrayObject.
|
||||
|
@ -1769,7 +1769,7 @@ class ArrayObject implements IteratorAggregate, ArrayAccess, Serializable, Count
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setIteratorClass($iteratorClass): void {}
|
||||
public function setIteratorClass(string $iteratorClass): void {}
|
||||
|
||||
/**
|
||||
* Gets the iterator classname for the ArrayObject.
|
||||
|
@ -1797,7 +1797,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @param int $flags Flags to control the behaviour of the ArrayObject object.
|
||||
* @see ArrayObject::setFlags()
|
||||
*/
|
||||
public function __construct($array = [], $flags = 0) {}
|
||||
public function __construct(object|array $array = [], int $flags = 0) {}
|
||||
|
||||
/**
|
||||
* Check if offset exists
|
||||
|
@ -1808,7 +1808,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return bool true if the offset exists, otherwise false
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetExists($key): bool {}
|
||||
public function offsetExists(mixed $key): bool {}
|
||||
|
||||
/**
|
||||
* Get value for an offset
|
||||
|
@ -1819,7 +1819,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return mixed The value at offset <i>index</i>.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetGet($key): mixed {}
|
||||
public function offsetGet(mixed $key): mixed {}
|
||||
|
||||
/**
|
||||
* Set value for an offset
|
||||
|
@ -1833,7 +1833,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetSet($key, $value): void {}
|
||||
public function offsetSet(mixed $key, mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Unset value for an offset
|
||||
|
@ -1844,7 +1844,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetUnset($key): void {}
|
||||
public function offsetUnset(mixed $key): void {}
|
||||
|
||||
/**
|
||||
* Append an element
|
||||
|
@ -1855,7 +1855,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function append($value): void {}
|
||||
public function append(mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Get array copy
|
||||
|
@ -1895,7 +1895,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setFlags($flags): void {}
|
||||
public function setFlags(int $flags): void {}
|
||||
|
||||
/**
|
||||
* Sort array by values
|
||||
|
@ -1904,7 +1904,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function asort(): bool {}
|
||||
public function asort(int $flags = SORT_REGULAR): bool {}
|
||||
|
||||
/**
|
||||
* Sort array by keys
|
||||
|
@ -1913,7 +1913,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function ksort(): bool {}
|
||||
public function ksort(int $flags = SORT_REGULAR): bool {}
|
||||
|
||||
/**
|
||||
* User defined sort
|
||||
|
@ -1924,7 +1924,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function uasort($callback): bool {}
|
||||
public function uasort(callable $callback): bool {}
|
||||
|
||||
/**
|
||||
* User defined sort
|
||||
|
@ -1935,7 +1935,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function uksort($callback): bool {}
|
||||
public function uksort(callable $callback): bool {}
|
||||
|
||||
/**
|
||||
* Sort an array naturally
|
||||
|
@ -1962,7 +1962,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function unserialize($data): void {}
|
||||
public function unserialize(string $data): void {}
|
||||
|
||||
/**
|
||||
* Serialize
|
||||
|
@ -2021,7 +2021,7 @@ class ArrayIterator implements SeekableIterator, ArrayAccess, Serializable, Coun
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function seek($offset): void {}
|
||||
public function seek(int $offset): void {}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
|
|
124
SPL/SPL_c1.php
124
SPL/SPL_c1.php
|
@ -65,7 +65,7 @@ interface SplSubject
|
|||
* information for an individual file.
|
||||
* @link https://php.net/manual/en/class.splfileinfo.php
|
||||
*/
|
||||
class SplFileInfo
|
||||
class SplFileInfo implements Stringable
|
||||
{
|
||||
/**
|
||||
* Construct a new SplFileInfo object
|
||||
|
@ -73,7 +73,7 @@ class SplFileInfo
|
|||
* @param string $filename
|
||||
* @since 5.1.2
|
||||
*/
|
||||
public function __construct($filename) {}
|
||||
public function __construct(string $filename) {}
|
||||
|
||||
/**
|
||||
* Gets the path without filename
|
||||
|
@ -113,7 +113,7 @@ class SplFileInfo
|
|||
* @since 5.2.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getBasename($suffix = null): string {}
|
||||
public function getBasename(string $suffix = null): string {}
|
||||
|
||||
/**
|
||||
* Gets the path to the file
|
||||
|
@ -289,7 +289,7 @@ class SplFileInfo
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getFileInfo($class = null): SplFileInfo {}
|
||||
public function getFileInfo(string|null $class = null): SplFileInfo {}
|
||||
|
||||
/**
|
||||
* Gets an SplFileInfo object for the path
|
||||
|
@ -301,7 +301,7 @@ class SplFileInfo
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getPathInfo($class = null): ?SplFileInfo {}
|
||||
public function getPathInfo(string|null $class = null): ?SplFileInfo {}
|
||||
|
||||
/**
|
||||
* Gets an SplFileObject object for the file
|
||||
|
@ -319,7 +319,7 @@ class SplFileInfo
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function openFile($mode = 'r', $useIncludePath = false, $context = null): SplFileObject {}
|
||||
public function openFile(string $mode = 'r', bool $useIncludePath = false, $context = null): SplFileObject {}
|
||||
|
||||
/**
|
||||
* Sets the class name used with <b>SplFileInfo::openFile</b>
|
||||
|
@ -331,7 +331,7 @@ class SplFileInfo
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setFileClass($class = SplFileObject::class): void {}
|
||||
public function setFileClass(string $class = SplFileObject::class): void {}
|
||||
|
||||
/**
|
||||
* Sets the class used with getFileInfo and getPathInfo
|
||||
|
@ -343,7 +343,7 @@ class SplFileInfo
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setInfoClass($class = SplFileInfo::class): void {}
|
||||
public function setInfoClass(string $class = SplFileInfo::class): void {}
|
||||
|
||||
/**
|
||||
* Returns the path to the file as a string
|
||||
|
@ -351,7 +351,7 @@ class SplFileInfo
|
|||
* @return string the path to the file.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
public function __toString() {}
|
||||
public function __toString(): string {}
|
||||
|
||||
#[TentativeType]
|
||||
final public function _bad_state_ex(): void {}
|
||||
|
@ -380,7 +380,7 @@ class DirectoryIterator extends SplFileInfo implements SeekableIterator
|
|||
* @throws UnexpectedValueException if the path cannot be opened.
|
||||
* @throws RuntimeException if the path is an empty string.
|
||||
*/
|
||||
public function __construct($directory) {}
|
||||
public function __construct(string $directory) {}
|
||||
|
||||
/**
|
||||
* Determine if current DirectoryIterator item is '.' or '..'
|
||||
|
@ -440,7 +440,7 @@ class DirectoryIterator extends SplFileInfo implements SeekableIterator
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function seek($offset): void {}
|
||||
public function seek(int $offset): void {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -469,7 +469,7 @@ class FilesystemIterator extends DirectoryIterator
|
|||
* @param int $flags [optional]
|
||||
* @throws UnexpectedValueException if the path cannot be found.
|
||||
*/
|
||||
public function __construct($directory, $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO|FilesystemIterator::SKIP_DOTS) {}
|
||||
public function __construct(string $directory, int $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO|FilesystemIterator::SKIP_DOTS) {}
|
||||
|
||||
/**
|
||||
* Rewinds back to the beginning
|
||||
|
@ -522,7 +522,7 @@ class FilesystemIterator extends DirectoryIterator
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setFlags($flags = null): void {}
|
||||
public function setFlags(int $flags): void {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -540,7 +540,7 @@ class RecursiveDirectoryIterator extends FilesystemIterator implements Recursive
|
|||
* @throws UnexpectedValueException if the path cannot be found or is not a directory.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
public function __construct($directory, $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO) {}
|
||||
public function __construct(string $directory, int $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO) {}
|
||||
|
||||
/**
|
||||
* Returns whether current entry is a directory and not '.' or '..'
|
||||
|
@ -550,7 +550,7 @@ class RecursiveDirectoryIterator extends FilesystemIterator implements Recursive
|
|||
* @return bool whether the current entry is a directory, but not '.' or '..'
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function hasChildren($allowLinks = false): bool {}
|
||||
public function hasChildren(bool $allowLinks = false): bool {}
|
||||
|
||||
/**
|
||||
* Returns an iterator for the current entry if it is a directory
|
||||
|
@ -620,7 +620,7 @@ class GlobIterator extends FilesystemIterator implements Countable
|
|||
* @param $pattern
|
||||
* @param int $flags [optional]
|
||||
*/
|
||||
public function __construct($pattern, $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO) {}
|
||||
public function __construct(string $pattern, int $flags = FilesystemIterator::KEY_AS_PATHNAME|FilesystemIterator::CURRENT_AS_FILEINFO) {}
|
||||
|
||||
/**
|
||||
* Get the number of directories and files
|
||||
|
@ -671,7 +671,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @throws RuntimeException When the filename cannot be opened
|
||||
* @throws LogicException When the filename is a directory
|
||||
*/
|
||||
public function __construct($filename, $mode = 'r', $useIncludePath = false, $context = null) {}
|
||||
public function __construct(string $filename, string $mode = 'r', bool $useIncludePath = false, $context = null) {}
|
||||
|
||||
/**
|
||||
* Rewind the file to the first line
|
||||
|
@ -715,7 +715,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @since 5.5.11
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fread($length): string|false {}
|
||||
public function fread(int $length): string|false {}
|
||||
|
||||
/**
|
||||
* Gets line from file and parse as CSV fields
|
||||
|
@ -737,7 +737,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* in which case empty lines are skipped.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fgetcsv($separator = ',', $enclosure = '"', $escape = "\\"): array|false|null {}
|
||||
public function fgetcsv(string $separator = ',', string $enclosure = '"', string $escape = "\\"): array|false|null {}
|
||||
|
||||
/**
|
||||
* Write a field array as a CSV line
|
||||
|
@ -754,7 +754,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fputcsv(array $fields, $separator = ',', $enclosure = '"', $escape = "\\"): int|false {}
|
||||
public function fputcsv(array $fields, string $separator = ',', string $enclosure = '"', string $escape = "\\"): int|false {}
|
||||
|
||||
/**
|
||||
* Set the delimiter and enclosure character for CSV
|
||||
|
@ -771,7 +771,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setCsvControl($separator = ',', $enclosure = '"', $escape = "\\"): void {}
|
||||
public function setCsvControl(string $separator = ',', string $enclosure = '"', string $escape = "\\"): void {}
|
||||
|
||||
/**
|
||||
* Get the delimiter and enclosure character for CSV
|
||||
|
@ -794,7 +794,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function flock($operation, &$wouldBlock = null): bool {}
|
||||
public function flock(int $operation, &$wouldBlock = null): bool {}
|
||||
|
||||
/**
|
||||
* Flushes the output to the file
|
||||
|
@ -832,7 +832,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* past EOF is not considered an error.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fseek($offset, $whence = SEEK_SET): int {}
|
||||
public function fseek(int $offset, int $whence = SEEK_SET): int {}
|
||||
|
||||
/**
|
||||
* Gets character from file
|
||||
|
@ -880,7 +880,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* parameters must be passed by reference.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fscanf($format, &...$vars): array|int|null {}
|
||||
public function fscanf(string $format, mixed &...$vars): array|int|null {}
|
||||
|
||||
/**
|
||||
* Write to file
|
||||
|
@ -897,7 +897,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @return int|false the number of bytes written, or 0 (false since 7.4) on error.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fwrite($data, $length = null): int|false {}
|
||||
public function fwrite(string $data, int $length = null): int|false {}
|
||||
|
||||
/**
|
||||
* Gets information about the file
|
||||
|
@ -923,7 +923,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function ftruncate($size): bool {}
|
||||
public function ftruncate(int $size): bool {}
|
||||
|
||||
/**
|
||||
* Retrieve current line of file
|
||||
|
@ -960,7 +960,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setFlags($flags): void {}
|
||||
public function setFlags(int $flags): void {}
|
||||
|
||||
/**
|
||||
* Gets flags for the SplFileObject
|
||||
|
@ -979,7 +979,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setMaxLineLen($maxLength): void {}
|
||||
public function setMaxLineLen(int $maxLength): void {}
|
||||
|
||||
/**
|
||||
* Get maximum line length
|
||||
|
@ -1016,7 +1016,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function seek($line): void {}
|
||||
public function seek(int $line): void {}
|
||||
|
||||
/**
|
||||
* Alias of <b>SplFileObject::fgets</b>
|
||||
|
@ -1031,7 +1031,7 @@ class SplFileObject extends SplFileInfo implements RecursiveIterator, SeekableIt
|
|||
* Alias of <b>SplFileObject::current</b>
|
||||
* @link https://php.net/manual/en/splfileobject.tostring.php
|
||||
*/
|
||||
public function __toString() {}
|
||||
public function __toString(): string {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1047,7 +1047,7 @@ class SplTempFileObject extends SplFileObject
|
|||
* @throws RuntimeException if an error occurs.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
public function __construct($maxMemory = 2097152) {}
|
||||
public function __construct(int $maxMemory = 2097152) {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1073,7 +1073,7 @@ class SplDoublyLinkedList implements Iterator, Countable, ArrayAccess, Serializa
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function add($index, $value): void {}
|
||||
public function add(int $index, mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Pops a node from the end of the doubly linked list
|
||||
|
@ -1100,7 +1100,7 @@ class SplDoublyLinkedList implements Iterator, Countable, ArrayAccess, Serializa
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function push($value): void {}
|
||||
public function push(mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Prepends the doubly linked list with an element
|
||||
|
@ -1111,7 +1111,7 @@ class SplDoublyLinkedList implements Iterator, Countable, ArrayAccess, Serializa
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function unshift($value): void {}
|
||||
public function unshift(mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Peeks at the node from the end of the doubly linked list
|
||||
|
@ -1156,7 +1156,7 @@ class SplDoublyLinkedList implements Iterator, Countable, ArrayAccess, Serializa
|
|||
* @return int
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setIteratorMode($mode): int {}
|
||||
public function setIteratorMode(int $mode): int {}
|
||||
|
||||
/**
|
||||
* Returns the mode of iteration
|
||||
|
@ -1200,7 +1200,7 @@ class SplDoublyLinkedList implements Iterator, Countable, ArrayAccess, Serializa
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetSet($index, $value): void {}
|
||||
public function offsetSet($index, mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Unsets the value at the specified $index
|
||||
|
@ -1269,7 +1269,7 @@ class SplDoublyLinkedList implements Iterator, Countable, ArrayAccess, Serializa
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function unserialize($data): void {}
|
||||
public function unserialize(string $data): void {}
|
||||
|
||||
/**
|
||||
* Serializes the storage
|
||||
|
@ -1318,7 +1318,7 @@ class SplQueue extends SplDoublyLinkedList
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function enqueue($value): void {}
|
||||
public function enqueue(mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Dequeues a node from the queue
|
||||
|
@ -1387,7 +1387,7 @@ abstract class SplHeap implements Iterator, Countable
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function insert($value): bool {}
|
||||
public function insert(mixed $value): bool {}
|
||||
|
||||
/**
|
||||
* Peeks at the node from the top of the heap
|
||||
|
@ -1594,7 +1594,7 @@ class SplMinHeap extends SplHeap
|
|||
* Having multiple elements with the same value in a Heap is not recommended. They will end up in an arbitrary relative position.
|
||||
*/
|
||||
#[TentativeType]
|
||||
protected function compare($value1, $value2): int {}
|
||||
protected function compare(mixed $value1, mixed $value2): int {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1620,7 +1620,7 @@ class SplMaxHeap extends SplHeap
|
|||
* Having multiple elements with the same value in a Heap is not recommended. They will end up in an arbitrary relative position.
|
||||
*/
|
||||
#[TentativeType]
|
||||
protected function compare($value1, $value2): int {}
|
||||
protected function compare(mixed $value1, mixed $value2): int {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1652,7 +1652,7 @@ class SplPriorityQueue implements Iterator, Countable
|
|||
* Multiple elements with the same priority will get dequeued in no particular order.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function compare($priority1, $priority2): int {}
|
||||
public function compare(mixed $priority1, mixed $priority2): int {}
|
||||
|
||||
/**
|
||||
* Inserts an element in the queue by sifting it up.
|
||||
|
@ -1665,7 +1665,7 @@ class SplPriorityQueue implements Iterator, Countable
|
|||
* </p>
|
||||
* @return true
|
||||
*/
|
||||
public function insert($value, $priority) {}
|
||||
public function insert(mixed $value, mixed $priority) {}
|
||||
|
||||
/**
|
||||
* Sets the mode of extraction
|
||||
|
@ -1679,7 +1679,7 @@ class SplPriorityQueue implements Iterator, Countable
|
|||
* @return int
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setExtractFlags($flags): int {}
|
||||
public function setExtractFlags(int $flags): int {}
|
||||
|
||||
/**
|
||||
* Peeks at the node from the top of the queue
|
||||
|
@ -1799,7 +1799,7 @@ class SplFixedArray implements Iterator, ArrayAccess, Countable, IteratorAggrega
|
|||
* @link https://php.net/manual/en/splfixedarray.construct.php
|
||||
* @param int $size [optional]
|
||||
*/
|
||||
public function __construct($size = 0) {}
|
||||
public function __construct(int $size = 0) {}
|
||||
|
||||
/**
|
||||
* Import a PHP array in a <b>SplFixedArray</b> instance
|
||||
|
@ -1814,7 +1814,7 @@ class SplFixedArray implements Iterator, ArrayAccess, Countable, IteratorAggrega
|
|||
* containing the array content.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function fromArray($array, $preserveKeys = true): SplFixedArray {}
|
||||
public static function fromArray(array $array, bool $preserveKeys = true): SplFixedArray {}
|
||||
|
||||
/**
|
||||
* Returns the size of the array
|
||||
|
@ -1848,7 +1848,7 @@ class SplFixedArray implements Iterator, ArrayAccess, Countable, IteratorAggrega
|
|||
* </p>
|
||||
* @return bool
|
||||
*/
|
||||
public function setSize($size) {}
|
||||
public function setSize(int $size) {}
|
||||
|
||||
/**
|
||||
* Returns whether the requested index exists
|
||||
|
@ -1884,7 +1884,7 @@ class SplFixedArray implements Iterator, ArrayAccess, Countable, IteratorAggrega
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetSet($index, $value): void {}
|
||||
public function offsetSet($index, mixed $value): void {}
|
||||
|
||||
/**
|
||||
* Unsets the value at the specified $index
|
||||
|
@ -1968,7 +1968,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function attach($object, $info = null): void {}
|
||||
public function attach(object $object, mixed $info = null): void {}
|
||||
|
||||
/**
|
||||
* Removes an object from the storage
|
||||
|
@ -1979,7 +1979,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function detach($object): void {}
|
||||
public function detach(object $object): void {}
|
||||
|
||||
/**
|
||||
* Checks if the storage contains a specific object
|
||||
|
@ -1990,7 +1990,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @return bool true if the object is in the storage, false otherwise.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function contains($object): bool {}
|
||||
public function contains(object $object): bool {}
|
||||
|
||||
/**
|
||||
* Adds all objects from another storage
|
||||
|
@ -2001,7 +2001,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @return int
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function addAll($storage): int {}
|
||||
public function addAll(SplObjectStorage $storage): int {}
|
||||
|
||||
/**
|
||||
* Removes objects contained in another storage from the current storage
|
||||
|
@ -2012,7 +2012,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @return int
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function removeAll($storage): int {}
|
||||
public function removeAll(SplObjectStorage $storage): int {}
|
||||
|
||||
/**
|
||||
* Removes all objects except for those contained in another storage from the current storage
|
||||
|
@ -2024,7 +2024,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @since 5.3.6
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function removeAllExcept($storage): int {}
|
||||
public function removeAllExcept(SplObjectStorage $storage): int {}
|
||||
|
||||
/**
|
||||
* Returns the data associated with the current iterator entry
|
||||
|
@ -2043,7 +2043,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setInfo($info): void {}
|
||||
public function setInfo(mixed $info): void {}
|
||||
|
||||
/**
|
||||
* Returns the number of objects in the storage
|
||||
|
@ -2052,7 +2052,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @return int The number of objects in the storage.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function count(): int {}
|
||||
public function count(int $mode = COUNT_NORMAL): int {}
|
||||
|
||||
/**
|
||||
* Rewind the iterator to the first storage element
|
||||
|
@ -2104,7 +2104,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @since 5.2.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function unserialize($data): void {}
|
||||
public function unserialize(string $data): void {}
|
||||
|
||||
/**
|
||||
* Serializes the storage
|
||||
|
@ -2139,7 +2139,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function offsetSet($object, $info = null): void {}
|
||||
public function offsetSet($object, mixed $info = null): void {}
|
||||
|
||||
/**
|
||||
* Removes an object from the storage
|
||||
|
@ -2173,7 +2173,7 @@ class SplObjectStorage implements Countable, Iterator, Serializable, ArrayAccess
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getHash($object): string {}
|
||||
public function getHash(object $object): string {}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
|
@ -2213,7 +2213,7 @@ class MultipleIterator implements Iterator
|
|||
* @link https://php.net/manual/en/multipleiterator.construct.php
|
||||
* @param int $flags Defaults to MultipleIterator::MIT_NEED_ALL | MultipleIterator::MIT_KEYS_NUMERIC
|
||||
*/
|
||||
public function __construct($flags) {}
|
||||
public function __construct(int $flags = MultipleIterator::MIT_NEED_ALL|MultipleIterator::MIT_KEYS_NUMERIC) {}
|
||||
|
||||
/**
|
||||
* Gets the flag information
|
||||
|
@ -2233,7 +2233,7 @@ class MultipleIterator implements Iterator
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setFlags($flags): void {}
|
||||
public function setFlags(int $flags): void {}
|
||||
|
||||
/**
|
||||
* Attaches iterator information
|
||||
|
@ -2248,7 +2248,7 @@ class MultipleIterator implements Iterator
|
|||
* @return void Description...
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function attachIterator(Iterator $iterator, $info = null): void {}
|
||||
public function attachIterator(Iterator $iterator, int|string|null $info = null): void {}
|
||||
|
||||
/**
|
||||
* Detaches an iterator
|
||||
|
|
|
@ -73,12 +73,11 @@ function spl_autoload_unregister(callable $callback): bool {}
|
|||
/**
|
||||
* Return all registered __autoload() functions
|
||||
* @link https://php.net/manual/en/function.spl-autoload-functions.php
|
||||
* @return array|false An array of all registered __autoload functions.
|
||||
* If the autoload stack is not activated then the return value is false.
|
||||
* @return array An array of all registered __autoload functions.
|
||||
* If no function is registered the return value will be an empty array.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
function spl_autoload_functions(): array|false {}
|
||||
function spl_autoload_functions(): array {}
|
||||
|
||||
/**
|
||||
* Try all registered __autoload() functions to load the requested class
|
||||
|
|
|
@ -87,7 +87,7 @@ function simplexml_import_dom(SimpleXMLElement|DOMNode $node, ?string $class_nam
|
|||
* Represents an element in an XML document.
|
||||
* @link https://php.net/manual/en/class.simplexmlelement.php
|
||||
*/
|
||||
class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator, RecursiveIterator
|
||||
class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator, Stringable, RecursiveIterator
|
||||
{
|
||||
/**
|
||||
* Creates a new SimpleXMLElement object
|
||||
|
@ -102,7 +102,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[Pure]
|
||||
public function __construct($data, $options = 0, $dataIsURL = false, $namespaceOrPrefix = '', $isPrefix = false) {}
|
||||
public function __construct(string $data, int $options = 0, bool $dataIsURL = false, string $namespaceOrPrefix = '', bool $isPrefix = false) {}
|
||||
|
||||
/**
|
||||
* Return a well-formed XML string based on SimpleXML element
|
||||
|
@ -118,7 +118,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function asXML($filename = null): string|bool {}
|
||||
public function asXML(string|null $filename = null): string|bool {}
|
||||
|
||||
/**
|
||||
* Alias of <b>SimpleXMLElement::asXML</b>
|
||||
|
@ -134,7 +134,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* successfully and false otherwise.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function saveXML($filename = null): string|bool {}
|
||||
public function saveXML(string|null $filename = null): string|bool {}
|
||||
|
||||
/**
|
||||
* Runs XPath query on XML data
|
||||
|
@ -146,7 +146,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* case of an error.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function xpath($expression): array|false|null {}
|
||||
public function xpath(string $expression): array|false|null {}
|
||||
|
||||
/**
|
||||
* Creates a prefix/ns context for the next XPath query
|
||||
|
@ -163,7 +163,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function registerXPathNamespace($prefix, $namespace): bool {}
|
||||
public function registerXPathNamespace(string $prefix, string $namespace): bool {}
|
||||
|
||||
/**
|
||||
* Identifies an element's attributes
|
||||
|
@ -183,7 +183,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function attributes($namespaceOrPrefix = null, $isPrefix = false): ?static {}
|
||||
public function attributes(string|null $namespaceOrPrefix = null, bool $isPrefix = false): ?static {}
|
||||
|
||||
/**
|
||||
* Finds children of given node
|
||||
|
@ -203,7 +203,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function children($namespaceOrPrefix = null, $isPrefix = false): ?static {}
|
||||
public function children(string|null $namespaceOrPrefix = null, bool $isPrefix = false): ?static {}
|
||||
|
||||
/**
|
||||
* Returns namespaces used in document
|
||||
|
@ -218,7 +218,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getNamespaces($recursive = false): array {}
|
||||
public function getNamespaces(bool $recursive = false): array {}
|
||||
|
||||
/**
|
||||
* Returns namespaces declared in document
|
||||
|
@ -237,7 +237,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getDocNamespaces($recursive = false, $fromRoot = true): array|false {}
|
||||
public function getDocNamespaces(bool $recursive = false, bool $fromRoot = true): array|false {}
|
||||
|
||||
/**
|
||||
* Gets the name of the XML element
|
||||
|
@ -267,7 +267,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* @since 5.1.3
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function addChild($qualifiedName, $value = null, $namespace = null): ?static {}
|
||||
public function addChild(string $qualifiedName, string|null $value = null, string|null $namespace = null): ?static {}
|
||||
|
||||
/**
|
||||
* Adds an attribute to the SimpleXML element
|
||||
|
@ -285,7 +285,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* @since 5.1.3
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function addAttribute($qualifiedName, $value = null, $namespace = null): void {}
|
||||
public function addAttribute(string $qualifiedName, string $value, string|null $namespace = null): void {}
|
||||
|
||||
/**
|
||||
* Returns the string content
|
||||
|
@ -372,7 +372,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* @return string|false the XML tag name of the element referenced by the current <b>SimpleXMLIterator</b> object
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function key(): string|false {}
|
||||
public function key(): string {}
|
||||
|
||||
/**
|
||||
* Move to next element
|
||||
|
@ -382,6 +382,21 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
#[TentativeType]
|
||||
public function next(): void {}
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function hasChildren(): bool {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function getChildren(): ?SimpleXMLElement {}
|
||||
|
||||
/**
|
||||
* Provides access to element's children
|
||||
* private Method not callable directly, stub exists for typehint only
|
||||
|
@ -395,7 +410,7 @@ class SimpleXMLElement implements Traversable, ArrayAccess, Countable, Iterator,
|
|||
* The SimpleXMLIterator provides recursive iteration over all nodes of a <b>SimpleXMLElement</b> object.
|
||||
* @link https://php.net/manual/en/class.simplexmliterator.php
|
||||
*/
|
||||
class SimpleXMLIterator extends SimpleXMLElement implements RecursiveIterator, Countable
|
||||
class SimpleXMLIterator extends SimpleXMLElement implements RecursiveIterator, Countable, Stringable
|
||||
{
|
||||
/**
|
||||
* Rewind to the first element
|
||||
|
|
|
@ -77,11 +77,11 @@ function bcmul(string $num1, string $num2, ?int $scale = null): string {}
|
|||
* set globally with the {@link bcscale()} function, or fallback to 0 if
|
||||
* this has not been set.
|
||||
* </p>
|
||||
* @return string|null the result of the division as a string, or <b>NULL</b> if
|
||||
* <i>divisor</i> is 0.
|
||||
* @return string the result of the division as a string.
|
||||
* @throws DivisionByZeroError if <i>divisor</i> is 0. Available since PHP 8.0.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcdiv(string $num1, string $num2, ?int $scale = 0): ?string {}
|
||||
function bcdiv(string $num1, string $num2, ?int $scale = 0): string {}
|
||||
|
||||
/**
|
||||
* Get modulus of an arbitrary precision number
|
||||
|
@ -98,11 +98,11 @@ function bcdiv(string $num1, string $num2, ?int $scale = 0): ?string {}
|
|||
* set globally with the {@link bcscale()} function, or fallback to 0 if
|
||||
* this has not been set. Available since PHP 7.2.
|
||||
* </p>
|
||||
* @return string|null the modulus as a string, or <b>NULL</b> if
|
||||
* <i>divisor</i> is 0.
|
||||
* @return string the modulus as a string.
|
||||
* @throws DivisionByZeroError if <i>divisor</i> is 0. Available since PHP 8.0.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcmod(string $num1, string $num2, ?int $scale = 0): ?string {}
|
||||
function bcmod(string $num1, string $num2, ?int $scale = 0): string {}
|
||||
|
||||
/**
|
||||
* Raise an arbitrary precision number to another
|
||||
|
@ -137,7 +137,7 @@ function bcpow(string $num, string $exponent, ?int $scale = null): string {}
|
|||
* <i>operand</i> is negative.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcsqrt(string $num, ?int $scale): ?string {}
|
||||
function bcsqrt(string $num, ?int $scale): string {}
|
||||
|
||||
/**
|
||||
* Set default scale parameter for all bc math functions
|
||||
|
@ -145,7 +145,7 @@ function bcsqrt(string $num, ?int $scale): ?string {}
|
|||
* @param int $scale
|
||||
* @return int
|
||||
*/
|
||||
function bcscale(int $scale = null): int {}
|
||||
function bcscale(int|null $scale = null): int {}
|
||||
|
||||
/**
|
||||
* Compare two arbitrary precision numbers
|
||||
|
@ -191,4 +191,4 @@ function bccomp(string $num1, string $num2, ?int $scale = null): int {}
|
|||
* is 0 or <i>exponent</i> is negative.
|
||||
*/
|
||||
#[Pure]
|
||||
function bcpowmod(string $num, string $exponent, string $modulus, ?int $scale = null): ?string {}
|
||||
function bcpowmod(string $num, string $exponent, string $modulus, ?int $scale = null): string {}
|
||||
|
|
12
bz2/bz2.php
12
bz2/bz2.php
|
@ -84,10 +84,10 @@ function bzclose($bz): bool {}
|
|||
* The file pointer. It must be valid and must point to a file
|
||||
* successfully opened by <b>bzopen</b>.
|
||||
* </p>
|
||||
* @return int the error number as an integer.
|
||||
* @return int|false the error number as an integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function bzerrno($bz): int {}
|
||||
function bzerrno($bz): int|false {}
|
||||
|
||||
/**
|
||||
* Returns a bzip2 error string
|
||||
|
@ -96,10 +96,10 @@ function bzerrno($bz): int {}
|
|||
* The file pointer. It must be valid and must point to a file
|
||||
* successfully opened by <b>bzopen</b>.
|
||||
* </p>
|
||||
* @return string a string containing the error message.
|
||||
* @return string|false a string containing the error message.
|
||||
*/
|
||||
#[Pure]
|
||||
function bzerrstr($bz): string {}
|
||||
function bzerrstr($bz): string|false {}
|
||||
|
||||
/**
|
||||
* Returns the bzip2 error number and error string in an array
|
||||
|
@ -108,13 +108,13 @@ function bzerrstr($bz): string {}
|
|||
* The file pointer. It must be valid and must point to a file
|
||||
* successfully opened by <b>bzopen</b>.
|
||||
* </p>
|
||||
* @return array an associative array, with the error code in the
|
||||
* @return array|false an associative array, with the error code in the
|
||||
* errno entry, and the error message in the
|
||||
* errstr entry.
|
||||
*/
|
||||
#[Pure]
|
||||
#[ArrayShape(["errno" => "int", "errstr" => "string"])]
|
||||
function bzerror($bz): array {}
|
||||
function bzerror($bz): array|false {}
|
||||
|
||||
/**
|
||||
* Compress a string into bzip2 encoded data
|
||||
|
|
|
@ -210,7 +210,7 @@ function jdmonthname(int $julian_day, int $mode): string {}
|
|||
* @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 {}
|
||||
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
|
||||
|
|
158
curl/curl.php
158
curl/curl.php
|
@ -12,18 +12,18 @@ use JetBrains\PhpStorm\Pure;
|
|||
* to its value. You can manually set this using the
|
||||
* curl_setopt function.
|
||||
* </p>
|
||||
* @return resource|false a cURL handle on success, false on errors.
|
||||
* @return false|CurlHandle a cURL handle on success, false on errors.
|
||||
*/
|
||||
function curl_init(?string $url) {}
|
||||
function curl_init(?string $url): CurlHandle|false {}
|
||||
|
||||
/**
|
||||
* Copy a cURL handle along with all of its preferences
|
||||
* @link https://php.net/manual/en/function.curl-copy-handle.php
|
||||
* @param resource $handle
|
||||
* @return resource|false a new cURL handle.
|
||||
* @param CurlHandle $handle
|
||||
* @return CurlHandle|false a new cURL handle.
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_copy_handle($handle) {}
|
||||
function curl_copy_handle(CurlHandle $handle): CurlHandle|false {}
|
||||
|
||||
/**
|
||||
* Gets cURL version information
|
||||
|
@ -73,12 +73,12 @@ function curl_copy_handle($handle) {}
|
|||
*/
|
||||
#[ArrayShape(["version_number" => "string", "version" => "string", "ssl_version_number" => "int", "ssl_version" => "string", "libz_version" => "string", "host" => "string", "age" => "int", "features" => "int", "protocols" => "array"])]
|
||||
#[Pure]
|
||||
function curl_version($age = null): array|false {}
|
||||
function curl_version(): array|false {}
|
||||
|
||||
/**
|
||||
* Set an option for a cURL transfer
|
||||
* @link https://php.net/manual/en/function.curl-setopt.php
|
||||
* @param resource $handle
|
||||
* @param CurlHandle $handle
|
||||
* @param int $option <p>
|
||||
* The CURLOPT_XXX option to set.
|
||||
* </p>
|
||||
|
@ -2031,12 +2031,12 @@ function curl_version($age = null): array|false {}
|
|||
* </table>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function curl_setopt($handle, int $option, mixed $value): bool {}
|
||||
function curl_setopt(CurlHandle $handle, int $option, mixed $value): bool {}
|
||||
|
||||
/**
|
||||
* Set multiple options for a cURL transfer
|
||||
* @link https://php.net/manual/en/function.curl-setopt-array.php
|
||||
* @param resource $handle
|
||||
* @param CurlHandle $handle
|
||||
* @param array $options <p>
|
||||
* An array specifying which options to set and their values.
|
||||
* The keys should be valid curl_setopt constants or
|
||||
|
@ -2047,34 +2047,34 @@ function curl_setopt($handle, int $option, mixed $value): bool {}
|
|||
* future options in the options array.
|
||||
* @since 5.1.3
|
||||
*/
|
||||
function curl_setopt_array($handle, array $options): bool {}
|
||||
function curl_setopt_array(CurlHandle $handle, array $options): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
* Close a cURL share handle
|
||||
* @link https://secure.php.net/manual/en/function.curl-share-close.php
|
||||
* @param CurlShareHandle|resource $share_handle <p>
|
||||
* @param CurlShareHandle $share_handle <p>
|
||||
* A cURL share handle returned by {@link https://secure.php.net/manual/en/function.curl-share-init.php curl_share_init()}
|
||||
* </p>
|
||||
* @return void
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_share_close($share_handle): void {}
|
||||
function curl_share_close(CurlShareHandle $share_handle): void {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
* Initialize a cURL share handle
|
||||
* @link https://secure.php.net/manual/en/function.curl-share-init.php
|
||||
* @return resource|CurlShareHandle Returns resource of type "cURL Share Handle".
|
||||
* @return 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/>
|
||||
* Set an option for a cURL share handle.
|
||||
* @link https://secure.php.net/manual/en/function.curl-share-setopt.php
|
||||
* @param CurlShareHandle|resource $share_handle <p>
|
||||
* @param CurlShareHandle $share_handle <p>
|
||||
* A cURL share handle returned by {@link https://secure.php.net/manual/en/function.curl-share-init.php curl_share_init()}.
|
||||
* </p>
|
||||
* @param int $option <table>
|
||||
|
@ -2147,7 +2147,7 @@ function curl_share_init() {}
|
|||
* Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_share_setopt($share_handle, int $option, mixed $value): bool {}
|
||||
function curl_share_setopt(CurlShareHandle $share_handle, int $option, mixed $value): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2166,7 +2166,7 @@ function curl_strerror(int $error_code): ?string {}
|
|||
* (PHP 5 >=5.5.0)<br/>
|
||||
* Decodes the given URL encoded string
|
||||
* @link https://secure.php.net/manual/en/function.curl-unescape.php
|
||||
* @param resource $handle <p>A cURL handle returned by
|
||||
* @param CurlHandle $handle <p>A cURL handle returned by
|
||||
* {@link https://secure.php.net/manual/en/function.curl-init.php curl_init()}.</p>
|
||||
* @param string $string <p>
|
||||
* The URL encoded string to be decoded.
|
||||
|
@ -2175,21 +2175,21 @@ function curl_strerror(int $error_code): ?string {}
|
|||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_unescape($handle, string $string): string|false {}
|
||||
function curl_unescape(CurlHandle $handle, string $string): string|false {}
|
||||
|
||||
/**
|
||||
* Perform a cURL session
|
||||
* @link https://php.net/manual/en/function.curl-exec.php
|
||||
* @param resource $handle
|
||||
* @param CurlHandle $handle
|
||||
* @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($handle): string|bool {}
|
||||
function curl_exec(CurlHandle $handle): string|bool {}
|
||||
|
||||
/**
|
||||
* Get information regarding a specific transfer
|
||||
* @link https://php.net/manual/en/function.curl-getinfo.php
|
||||
* @param resource $handle
|
||||
* @param CurlHandle $handle
|
||||
* @param int|null $option [optional] <p>
|
||||
* This may be one of the following constants:
|
||||
* <ul>
|
||||
|
@ -2447,32 +2447,32 @@ function curl_exec($handle): string|bool {}
|
|||
* </ul>
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function curl_getinfo($handle, ?int $option): mixed {}
|
||||
function curl_getinfo(CurlHandle $handle, ?int $option): mixed {}
|
||||
|
||||
/**
|
||||
* Return a string containing the last error for the current session
|
||||
* @link https://php.net/manual/en/function.curl-error.php
|
||||
* @param resource $handle
|
||||
* @param CurlHandle $handle
|
||||
* @return string the error message or '' (the empty string) if no
|
||||
* error occurred.
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function curl_error($handle): string {}
|
||||
function curl_error(CurlHandle $handle): string {}
|
||||
|
||||
/**
|
||||
* Return the last error number
|
||||
* @link https://php.net/manual/en/function.curl-errno.php
|
||||
* @param resource $handle
|
||||
* @param CurlHandle $handle
|
||||
* @return int the error number or 0 (zero) if no error
|
||||
* occurred.
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function curl_errno($handle): int {}
|
||||
function curl_errno(CurlHandle $handle): int {}
|
||||
|
||||
/**
|
||||
* URL encodes the given string
|
||||
* @link https://secure.php.net/manual/en/function.curl-escape.php
|
||||
* @param resource $handle <p>
|
||||
* @param CurlHandle $handle <p>
|
||||
* A cURL handle returned by
|
||||
* {@link https://secure.php.net/manual/en/function.curl-init.php curl_init()}.</p>
|
||||
* @param string $string <p>
|
||||
|
@ -2481,7 +2481,7 @@ function curl_errno($handle): int {}
|
|||
* @since 5.5
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_escape($handle, string $string): string|false {}
|
||||
function curl_escape(CurlHandle $handle, string $string): string|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.5.0) <br/>
|
||||
|
@ -2500,54 +2500,54 @@ function curl_file_create(string $filename, ?string $mime_type = null, ?string $
|
|||
/**
|
||||
* Close a cURL session
|
||||
* @link https://php.net/manual/en/function.curl-close.php
|
||||
* @param resource $handle
|
||||
* @param CurlHandle $handle
|
||||
* @return void
|
||||
*/
|
||||
function curl_close($handle): void {}
|
||||
function curl_close(CurlHandle $handle): void {}
|
||||
|
||||
/**
|
||||
* Returns a new cURL multi handle
|
||||
* @link https://php.net/manual/en/function.curl-multi-init.php
|
||||
* @return resource|false a cURL multi handle resource on success, false on failure.
|
||||
* @return CurlMultiHandle|false a cURL multi handle resource on success, false on failure.
|
||||
*/
|
||||
function curl_multi_init() {}
|
||||
function curl_multi_init(): CurlMultiHandle {}
|
||||
|
||||
/**
|
||||
* Add a normal cURL handle to a cURL multi handle
|
||||
* @link https://php.net/manual/en/function.curl-multi-add-handle.php
|
||||
* @param resource $multi_handle
|
||||
* @param resource $handle
|
||||
* @param CurlMultiHandle $multi_handle
|
||||
* @param CurlHandle $handle
|
||||
* @return int 0 on success, or one of the CURLM_XXX errors
|
||||
* code.
|
||||
*/
|
||||
function curl_multi_add_handle($multi_handle, $handle): int {}
|
||||
function curl_multi_add_handle(CurlMultiHandle $multi_handle, CurlHandle $handle): int {}
|
||||
|
||||
/**
|
||||
* Remove a multi handle from a set of cURL handles
|
||||
* @link https://php.net/manual/en/function.curl-multi-remove-handle.php
|
||||
* @param resource $multi_handle
|
||||
* @param resource $handle
|
||||
* @param CurlMultiHandle $multi_handle
|
||||
* @param CurlHandle $handle
|
||||
* @return int|false On success, returns one of the CURLM_XXX error codes, false on failure.
|
||||
*/
|
||||
function curl_multi_remove_handle($multi_handle, $handle): int|false {}
|
||||
function curl_multi_remove_handle(CurlMultiHandle $multi_handle, CurlHandle $handle): int {}
|
||||
|
||||
/**
|
||||
* Wait for activity on any curl_multi connection
|
||||
* @link https://php.net/manual/en/function.curl-multi-select.php
|
||||
* @param resource $multi_handle
|
||||
* @param CurlMultiHandle $multi_handle
|
||||
* @param float $timeout [optional] <p>
|
||||
* Time, in seconds, to wait for a response.
|
||||
* </p>
|
||||
* @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($multi_handle, float $timeout = 1.0): int {}
|
||||
function curl_multi_select(CurlMultiHandle $multi_handle, float $timeout = '1'): int {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
* Set an option for the cURL multi handle
|
||||
* @link https://secure.php.net/manual/en/function.curl-multi-setopt.php
|
||||
* @param resource $multi_handle
|
||||
* @param CurlMultiHandle $multi_handle
|
||||
* @param int $option <p>
|
||||
* One of the <b>CURLMOPT_*</b> constants.
|
||||
* </p>
|
||||
|
@ -2593,7 +2593,7 @@ function curl_multi_select($multi_handle, float $timeout = 1.0): int {}
|
|||
* @return bool Returns TRUE on success or FALSE on failure.
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_multi_setopt($multi_handle, int $option, mixed $value): bool {}
|
||||
function curl_multi_setopt(CurlMultiHandle $multi_handle, int $option, mixed $value): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -2611,29 +2611,29 @@ function curl_multi_strerror(int $error_code): ?string {}
|
|||
* (PHP 5 >=5.5.0)<br/>
|
||||
* Pause and unpause a connection
|
||||
* @link https://secure.php.net/manual/en/function.curl-pause.php
|
||||
* @param resource $handle
|
||||
* @param CurlHandle $handle
|
||||
* <p>A cURL handle returned by {@link https://secure.php.net/manual/en/function.curl-init.php curl_init()}.</p>
|
||||
* @param int $flags <p>One of <b>CURLPAUSE_*</b> constants.</p>
|
||||
* @return int Returns an error code (<b>CURLE_OK</b> for no error).
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_pause($handle, int $flags): int {}
|
||||
function curl_pause(CurlHandle $handle, int $flags): int {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
* Reset all options of a libcurl session handle
|
||||
* @link https://secure.php.net/manual/en/function.curl-reset.php
|
||||
* @param resource $handle <p>A cURL handle returned by
|
||||
* @param CurlHandle $handle <p>A cURL handle returned by
|
||||
* {@link https://secure.php.net/manual/en/function.curl-init.php curl_init()}.</p>
|
||||
* @return void
|
||||
* @since 5.5
|
||||
*/
|
||||
function curl_reset($handle): void {}
|
||||
function curl_reset(CurlHandle $handle): void {}
|
||||
|
||||
/**
|
||||
* Run the sub-connections of the current cURL handle
|
||||
* @link https://php.net/manual/en/function.curl-multi-exec.php
|
||||
* @param resource $multi_handle
|
||||
* @param CurlMultiHandle $multi_handle
|
||||
* @param int &$still_running <p>
|
||||
* A reference to a flag to tell whether the operations are still running.
|
||||
* </p>
|
||||
|
@ -2644,21 +2644,21 @@ function curl_reset($handle): void {}
|
|||
* CURLM_OK.
|
||||
* </p>
|
||||
*/
|
||||
function curl_multi_exec($multi_handle, &$still_running = 0): int {}
|
||||
function curl_multi_exec(CurlMultiHandle $multi_handle, &$still_running): int {}
|
||||
|
||||
/**
|
||||
* Return the content of a cURL handle if <constant>CURLOPT_RETURNTRANSFER</constant> is set
|
||||
* @link https://php.net/manual/en/function.curl-multi-getcontent.php
|
||||
* @param resource $handle
|
||||
* @param CurlHandle $handle
|
||||
* @return null|string Return the content of a cURL handle if CURLOPT_RETURNTRANSFER is set.
|
||||
*/
|
||||
#[Pure]
|
||||
function curl_multi_getcontent($handle): ?string {}
|
||||
function curl_multi_getcontent(CurlHandle $handle): ?string {}
|
||||
|
||||
/**
|
||||
* Get information about the current transfers
|
||||
* @link https://php.net/manual/en/function.curl-multi-info-read.php
|
||||
* @param resource $multi_handle
|
||||
* @param CurlMultiHandle $multi_handle
|
||||
* @param int &$queued_messages [optional] <p>
|
||||
* Number of messages that are still in the queue
|
||||
* </p>
|
||||
|
@ -2666,33 +2666,33 @@ function curl_multi_getcontent($handle): ?string {}
|
|||
*/
|
||||
#[Pure]
|
||||
#[ArrayShape(["msg" => "int", "result" => "int", "handle" => "resource"])]
|
||||
function curl_multi_info_read($multi_handle, &$queued_messages): array|false {}
|
||||
function curl_multi_info_read(CurlMultiHandle $multi_handle, &$queued_messages): array|false {}
|
||||
|
||||
/**
|
||||
* Close a set of cURL handles
|
||||
* @link https://php.net/manual/en/function.curl-multi-close.php
|
||||
* @param resource $multi_handle
|
||||
* @param CurlMultiHandle $multi_handle
|
||||
* @return void
|
||||
*/
|
||||
function curl_multi_close($multi_handle): void {}
|
||||
function curl_multi_close(CurlMultiHandle $multi_handle): void {}
|
||||
|
||||
/**
|
||||
* Return the last multi curl error number
|
||||
* @param resource $multi_handle
|
||||
* @param CurlMultiHandle $multi_handle
|
||||
* @return int
|
||||
* @since 7.1
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function curl_multi_errno($multi_handle): int {}
|
||||
function curl_multi_errno(CurlMultiHandle $multi_handle): int {}
|
||||
|
||||
/**
|
||||
* Return the last share curl error number
|
||||
* @param resource $share_handle
|
||||
* @param CurlMultiHandle $share_handle
|
||||
* @return int
|
||||
* @since 7.1
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function curl_share_errno($share_handle): int {}
|
||||
function curl_share_errno(CurlShareHandle $share_handle): int {}
|
||||
|
||||
/**
|
||||
* Return string describing the given error code
|
||||
|
@ -2717,7 +2717,7 @@ class CURLFile
|
|||
* @param string $posted_filename [optional] <p>Name of the file.</p>
|
||||
* @since 5.5
|
||||
*/
|
||||
public function __construct($filename, $mime_type = '', $posted_filename = '') {}
|
||||
public function __construct(string $filename, string|null $mime_type = '', string|null $posted_filename = '') {}
|
||||
|
||||
/**
|
||||
* Get file name
|
||||
|
@ -2756,7 +2756,7 @@ class CURLFile
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setMimeType($mime_type): void {}
|
||||
public function setMimeType(string $mime_type): void {}
|
||||
|
||||
/**
|
||||
* Set file name for POST
|
||||
|
@ -2765,7 +2765,7 @@ class CURLFile
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setPostFilename($posted_filename): void {}
|
||||
public function setPostFilename(string $posted_filename): void {}
|
||||
|
||||
/**
|
||||
* @link https://secure.php.net/manual/en/curlfile.wakeup.php
|
||||
|
@ -2774,3 +2774,39 @@ class CURLFile
|
|||
*/
|
||||
public function __wakeup() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class CurlHandle
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct CurlHandle, use curl_init() instead
|
||||
* @see curl_init()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class CurlMultiHandle
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct CurlMultiHandle, use curl_multi_init() instead
|
||||
* @see curl_multi_init()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class CurlShareHandle
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct CurlShareHandle, use curl_share_init() instead
|
||||
* @see curl_share_init()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
|
103
date/date.php
103
date/date.php
|
@ -286,12 +286,12 @@ function strtotime(string $datetime, ?int $baseTimestamp): int|false {}
|
|||
* </p>
|
||||
* @param int|null $timestamp [optional] Default value: time(). The optional timestamp parameter is an integer Unix timestamp
|
||||
* that defaults to the current local time if a timestamp is not given.
|
||||
* @return string|false a formatted date string. If a non-numeric value is used for
|
||||
* @return string a formatted date string. If a non-numeric value is used for
|
||||
* timestamp, false is returned and an
|
||||
* E_WARNING level error is emitted.
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function date(string $format, ?int $timestamp): string|false {}
|
||||
function date(string $format, ?int $timestamp): string {}
|
||||
|
||||
/**
|
||||
* Format a local time/date as integer
|
||||
|
@ -397,12 +397,12 @@ function idate(string $format, ?int $timestamp): int|false {}
|
|||
* options for the date function.
|
||||
* </p>
|
||||
* @param int|null $timestamp [optional]
|
||||
* @return string|false a formatted date string. If a non-numeric value is used for
|
||||
* @return string a formatted date string. If a non-numeric value is used for
|
||||
* timestamp, false is returned and an
|
||||
* E_WARNING level error is emitted.
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function gmdate(string $format, ?int $timestamp): string|false {}
|
||||
function gmdate(string $format, ?int $timestamp): string {}
|
||||
|
||||
/**
|
||||
* Get Unix timestamp for a date
|
||||
|
@ -430,32 +430,13 @@ function gmdate(string $format, ?int $timestamp): string|false {}
|
|||
* is somewhere between 1901 and 2038. However, before PHP 5.1.0 this
|
||||
* range was limited from 1970 to 2038 on some systems (e.g. Windows).
|
||||
* </p>
|
||||
* @param int $is_dst [optional] <p>
|
||||
* This parameter can be set to 1 if the time is during daylight savings time (DST),
|
||||
* 0 if it is not, or -1 (the default) if it is unknown whether the time is within
|
||||
* daylight savings time or not. If it's unknown, PHP tries to figure it out itself.
|
||||
* This can cause unexpected (but not incorrect) results.
|
||||
* Some times are invalid if DST is enabled on the system PHP is running on or
|
||||
* is_dst is set to 1. If DST is enabled in e.g. 2:00, all times
|
||||
* between 2:00 and 3:00 are invalid and mktime returns an undefined
|
||||
* (usually negative) value.
|
||||
* Some systems (e.g. Solaris 8) enable DST at midnight so time 0:30 of the day when DST
|
||||
* is enabled is evaluated as 23:30 of the previous day.
|
||||
* </p>
|
||||
* <p>
|
||||
* As of PHP 5.1.0, this parameter became deprecated. As a result, the
|
||||
* new timezone handling features should be used instead.
|
||||
* </p>
|
||||
* <p>
|
||||
* This parameter has been removed in PHP 7.0.0.
|
||||
* </p>
|
||||
* @return int|false mktime returns the Unix timestamp of the arguments
|
||||
* given.
|
||||
* If the arguments are invalid, the function returns false (before PHP 5.1
|
||||
* it returned -1).
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function mktime(int $hour = null, ?int $minute = null, ?int $second = null, ?int $month = null, ?int $day = null, ?int $year = null): int|false {}
|
||||
function mktime(int $hour, ?int $minute = null, ?int $second = null, ?int $month = null, ?int $day = null, ?int $year = null): int|false {}
|
||||
|
||||
/**
|
||||
* Get Unix timestamp for a GMT date
|
||||
|
@ -478,14 +459,10 @@ function mktime(int $hour = null, ?int $minute = null, ?int $second = null, ?int
|
|||
* @param int $year <p>
|
||||
* The year
|
||||
* </p>
|
||||
* @param int $is_dst <p>
|
||||
* Parameters always represent a GMT date so is_dst
|
||||
* doesn't influence the result.
|
||||
* </p>
|
||||
* @return int|false a integer Unix timestamp.
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function gmmktime(int $hour = null, ?int $minute = null, ?int $second = null, ?int $month = null, ?int $day = null, ?int $year = null): int|false {}
|
||||
function gmmktime(int $hour, ?int $minute = null, ?int $second = null, ?int $month = null, ?int $day = null, ?int $year = null): int|false {}
|
||||
|
||||
/**
|
||||
* Validate a Gregorian date
|
||||
|
@ -958,12 +935,12 @@ function date_create_from_format(string $format, string $datetime, ?DateTimeZone
|
|||
* @param string $datetime <p>
|
||||
* Date in format accepted by strtotime.
|
||||
* </p>
|
||||
* @return array|false array with information about the parsed date
|
||||
* @return array array with information about the parsed date
|
||||
* on success or false on failure.
|
||||
*/
|
||||
#[Pure(true)]
|
||||
#[ArrayShape(["year" => "int", "month" => "int", "day" => "int", "hour" => "int", "minute" => "int", "second" => "int", "fraction" => "double", "is_localtime" => "bool", "zone_type" => "int", "zone" => "int", "is_dst" => "bool", "tz_abbr" => "string", "tz_id" => "string", "relative" => "array", "warning_count" => "int", "warnings" => "array", "error_count" => "int", "errors" => "array"])]
|
||||
function date_parse(string $datetime): array|false {}
|
||||
function date_parse(string $datetime): array {}
|
||||
|
||||
/**
|
||||
* Get info about given date formatted according to the specified format
|
||||
|
@ -997,10 +974,10 @@ function date_get_last_errors(): array|false {}
|
|||
* @link https://php.net/manual/en/function.date-format.php
|
||||
* @param DateTimeInterface $object
|
||||
* @param string $format
|
||||
* @return string|false formatted date string on success or <b>FALSE</b> on failure.
|
||||
* @return string formatted date string on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function date_format(DateTimeInterface $object, string $format): string|false {}
|
||||
function date_format(DateTimeInterface $object, string $format): string {}
|
||||
|
||||
/**
|
||||
* Alter the timestamp of a DateTime object by incrementing or decrementing
|
||||
|
@ -1023,10 +1000,10 @@ function date_modify(DateTime $object, string $modifier): DateTime|false {}
|
|||
* {@see date_create()}. The function modifies this object.</p>
|
||||
* @param DateInterval $interval <p>A
|
||||
* {@see DateInterval} object</p>
|
||||
* @return DateTime|false <p>Returns the
|
||||
* {@see DateTime} object for method chaining or <b>FALSE</b> on failure.</p>
|
||||
* @return DateTime <p>Returns the
|
||||
* {@see DateTime} object for method chaining.</p>
|
||||
*/
|
||||
function date_add(DateTime $object, DateInterval $interval): DateTime|false {}
|
||||
function date_add(DateTime $object, DateInterval $interval): DateTime {}
|
||||
|
||||
/**
|
||||
* Subtracts an amount of days, months, years, hours, minutes and seconds from a datetime object
|
||||
|
@ -1038,10 +1015,10 @@ function date_add(DateTime $object, DateInterval $interval): DateTime|false {}
|
|||
* {@see date_create()}. The function modifies this object.
|
||||
* @param DateInterval $interval <p>A
|
||||
* {@see DateInterval} object</p>
|
||||
* @return DateTime|false <p>Returns the
|
||||
* {@see DateTime} object for method chaining or <b>FALSE</b> on failure.</p>
|
||||
* @return DateTime <p>Returns the
|
||||
* {@see DateTime} object for method chaining.</p>
|
||||
*/
|
||||
function date_sub(DateTime $object, DateInterval $interval): DateTime|false {}
|
||||
function date_sub(DateTime $object, DateInterval $interval): DateTime {}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -1066,15 +1043,15 @@ function date_timezone_get(DateTimeInterface $object): DateTimeZone|false {}
|
|||
* Alias:
|
||||
* {@see DateTime::setTimezone}
|
||||
* @link https://php.net/manual/en/function.date-timezone-set.php
|
||||
* @param DateTimeInterface $object <p>A
|
||||
* @param DateTime $object <p>A
|
||||
* {@see DateTime} object returned by
|
||||
* {@see date_create()}. The function modifies this object.</p>
|
||||
* @param DateTimeZone $timezone <p>A
|
||||
* {@see DateTimeZone} object representing the desired time zone.</p>
|
||||
* @return DateTime|false <p>Returns the
|
||||
* @return DateTime <p>Returns the
|
||||
* {@see DateTime} object for method chaining or <b>FALSE</b> on failure.</p>
|
||||
*/
|
||||
function date_timezone_set(DateTimeInterface $object, DateTimeZone $timezone): DateTime|false {}
|
||||
function date_timezone_set(DateTime $object, DateTimeZone $timezone): DateTime {}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -1082,10 +1059,10 @@ function date_timezone_set(DateTimeInterface $object, DateTimeZone $timezone): D
|
|||
* @link https://php.net/manual/en/function.date-offset-get.php
|
||||
* @param DateTimeInterface $object <p>Procedural style only: A {@see DateTime} object
|
||||
* returned by {@see date_create()}</p>
|
||||
* @return int|false <p>Returns the timezone offset in seconds from UTC on success or <b>FALSE</b> on failure.</p>
|
||||
* @return int <p>Returns the timezone offset in seconds from UTC on success or <b>FALSE</b> on failure.</p>
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function date_offset_get(DateTimeInterface $object): int|false {}
|
||||
function date_offset_get(DateTimeInterface $object): int {}
|
||||
|
||||
/**
|
||||
* Returns the difference between two datetime objects
|
||||
|
@ -1095,10 +1072,10 @@ function date_offset_get(DateTimeInterface $object): int|false {}
|
|||
* @param DateTimeInterface $baseObject
|
||||
* @param DateTimeInterface $targetObject The date to compare to
|
||||
* @param bool $absolute [optional] Whether to return absolute difference.
|
||||
* @return DateInterval|false The DateInterval object representing the difference between the two dates or FALSE on failure.
|
||||
* @return DateInterval The DateInterval object representing the difference between the two dates.
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function date_diff(DateTimeInterface $baseObject, DateTimeInterface $targetObject, bool $absolute = false): DateInterval|false {}
|
||||
function date_diff(DateTimeInterface $baseObject, DateTimeInterface $targetObject, bool $absolute = false): DateInterval {}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -1124,13 +1101,13 @@ function date_time_set(DateTime $object, int $hour, int $minute, int $second = 0
|
|||
* @param int $year <p>Year of the date.</p>
|
||||
* @param int $month <p>Month of the date.</p>
|
||||
* @param int $day <p>Day of the date.</p>
|
||||
* @return DateTime|false
|
||||
* @return DateTime
|
||||
* <p>
|
||||
* Returns the
|
||||
* {@see DateTime} object for method chaining or <b>FALSE</b> on failure.
|
||||
* {@see DateTime} object for method chaining.
|
||||
* </p>
|
||||
*/
|
||||
function date_date_set(DateTime $object, int $year, int $month, int $day): DateTime|false {}
|
||||
function date_date_set(DateTime $object, int $year, int $month, int $day): DateTime {}
|
||||
|
||||
/**
|
||||
* Alias:
|
||||
|
@ -1140,11 +1117,11 @@ function date_date_set(DateTime $object, int $year, int $month, int $day): DateT
|
|||
* @param int $year <p>Year of the date</p>
|
||||
* @param int $week <p>Week of the date.</p>
|
||||
* @param int $dayOfWeek [optional] <p>Offset from the first day of the week.</p>
|
||||
* @return DateTime|false <p>
|
||||
* Returns the {@see DateTime} object for method chaining or <strong><code>FALSE</code></strong> on failure.
|
||||
* @return DateTime <p>
|
||||
* Returns the {@see DateTime} object for method chaining.
|
||||
* </p>
|
||||
*/
|
||||
function date_isodate_set(DateTime $object, int $year, int $week, int $dayOfWeek = 1): DateTime|false {}
|
||||
function date_isodate_set(DateTime $object, int $year, int $week, int $dayOfWeek = 1): DateTime {}
|
||||
|
||||
/**
|
||||
* Sets the date and time based on an unix timestamp
|
||||
|
@ -1155,10 +1132,10 @@ function date_isodate_set(DateTime $object, int $year, int $week, int $dayOfWeek
|
|||
* {@see DateTime} object returned by
|
||||
* {@see date_create()}. The function modifies this object.</p>
|
||||
* @param int $timestamp <p>Unix timestamp representing the date.</p>
|
||||
* @return DateTime|false
|
||||
* {@see DateTime} object for call chaining or <b>FALSE</b> on failure
|
||||
* @return DateTime
|
||||
* {@see DateTime} object for call chaining
|
||||
*/
|
||||
function date_timestamp_set(DateTime $object, int $timestamp): DateTime|false {}
|
||||
function date_timestamp_set(DateTime $object, int $timestamp): DateTime {}
|
||||
|
||||
/**
|
||||
* Gets the unix timestamp
|
||||
|
@ -1226,10 +1203,10 @@ function timezone_name_from_abbr(string $abbr, int $utcOffset = -1, int $isDST =
|
|||
* returned by
|
||||
* {@see timezone_open()}</p>
|
||||
* @param DateTimeInterface $datetime <p>DateTime that contains the date/time to compute the offset from.</p>
|
||||
* @return int|false <p>Returns time zone offset in seconds on success or <b>FALSE</b> on failure.</p>
|
||||
* @return int <p>Returns time zone offset in seconds.</p>
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function timezone_offset_get(DateTimeZone $object, DateTimeInterface $datetime): int|false {}
|
||||
function timezone_offset_get(DateTimeZone $object, DateTimeInterface $datetime): int {}
|
||||
|
||||
/**
|
||||
* Returns all transitions for the timezone
|
||||
|
@ -1265,20 +1242,20 @@ function timezone_location_get(DateTimeZone $object): array|false {}
|
|||
* @param int $timezoneGroup [optional] One of DateTimeZone class constants.
|
||||
* @param string|null $countryCode [optional] A two-letter ISO 3166-1 compatible country code.
|
||||
* Note: This option is only used when $timezoneGroup is set to DateTimeZone::PER_COUNTRY.
|
||||
* @return array|false Returns array on success or FALSE on failure.
|
||||
* @return array
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function timezone_identifiers_list(int $timezoneGroup = DateTimeZone::ALL, ?string $countryCode): array|false {}
|
||||
function timezone_identifiers_list(int $timezoneGroup = DateTimeZone::ALL, ?string $countryCode): array {}
|
||||
|
||||
/**
|
||||
* Returns associative array containing dst, offset and the timezone name
|
||||
* Alias:
|
||||
* {@see DateTimeZone::listAbbreviations}
|
||||
* @link https://php.net/manual/en/function.timezone-abbreviations-list.php
|
||||
* @return array|false Array on success or <b>FALSE</b> on failure.
|
||||
* @return array
|
||||
*/
|
||||
#[Pure]
|
||||
function timezone_abbreviations_list(): array|false {}
|
||||
function timezone_abbreviations_list(): array {}
|
||||
|
||||
/**
|
||||
* Gets the version of the timezonedb
|
||||
|
@ -1461,7 +1438,7 @@ function date_sunset(int $timestamp, int $returnFormat = SUNFUNCS_RET_STRING, ?f
|
|||
* nautical_twilight_end: int|bool,
|
||||
* astronomical_twilight_begin: int|bool,
|
||||
* astronomical_twilight_end: int|bool,
|
||||
* }|false Returns array on success or <strong><code>false</code></strong> on failure. The structure of the array is detailed in the following list:
|
||||
* } The structure of the array is detailed in the following list:
|
||||
* <table>
|
||||
* <tr><td>sunrise</td><td>The timestamp of the sunrise (zenith angle = 90°35').</td></tr>
|
||||
* <tr><td>sunset</td><td>The timestamp of the sunset (zenith angle = 90°35').</td></tr>
|
||||
|
@ -1481,4 +1458,4 @@ function date_sunset(int $timestamp, int $returnFormat = SUNFUNCS_RET_STRING, ?f
|
|||
*/
|
||||
#[Pure(true)]
|
||||
#[ArrayShape(["sunrise" => "int", "sunset" => "int", "transit" => "int", "civil_twilight_begin" => "int", "civil_twilight_end" => "int", "nautical_twilight_begin" => "int", "nautical_twilight_end" => "int", "astronomical_twilight_begin" => "int", "astronomical_twilight_end" => "int"])]
|
||||
function date_sun_info(int $timestamp, float $latitude, float $longitude): array|false {}
|
||||
function date_sun_info(int $timestamp, float $latitude, float $longitude): array {}
|
||||
|
|
|
@ -90,7 +90,7 @@ interface DateTimeInterface
|
|||
* difference between the two dates.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function diff(DateTimeInterface $targetObject, $absolute = false): DateInterval;
|
||||
public function diff(DateTimeInterface $targetObject, bool $absolute = false): DateInterval;
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -105,18 +105,17 @@ interface DateTimeInterface
|
|||
* Since PHP8, it always returns <b>STRING</b>.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function format($format): string;
|
||||
public function format(string $format): string;
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
* Returns the timezone offset
|
||||
* @return int|false
|
||||
* Returns the timezone offset in seconds from UTC on success
|
||||
* or <b>FALSE</b> on failure. Since PHP8, it always returns <b>INT</b>.
|
||||
* Returns the timezone offset in seconds from UTC.
|
||||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getOffset(): int|false;
|
||||
public function getOffset(): int;
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -173,7 +172,7 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
* @throws Exception Emits Exception in case of an error.
|
||||
* @since 5.5
|
||||
*/
|
||||
public function __construct($datetime = 'now', DateTimeZone $timezone = null) {}
|
||||
public function __construct(string $datetime = 'now', DateTimeZone|null $timezone = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -186,7 +185,7 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function createFromFormat($format, $datetime, DateTimeZone $timezone = null): DateTimeImmutable|false {}
|
||||
public static function createFromFormat(string $format, string $datetime, DateTimeZone|null $timezone = null): DateTimeImmutable|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.6.0)<br/>
|
||||
|
@ -221,6 +220,13 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
*/
|
||||
public static function __set_state(array $array) {}
|
||||
|
||||
/**
|
||||
* @param DateTimeInterface $object
|
||||
* @return DateTimeImmutable
|
||||
* @since 8.0
|
||||
*/
|
||||
public static function createFromInterface(DateTimeInterface $object): DateTimeImmutable {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
* Adds an amount of days, months, years, hours, minutes and seconds
|
||||
|
@ -243,7 +249,7 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function modify($modifier): DateTimeImmutable|false {}
|
||||
public function modify(string $modifier): DateTimeImmutable|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -257,7 +263,7 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setDate($year, $month, $day): DateTimeImmutable {}
|
||||
public function setDate(int $year, int $month, int $day): DateTimeImmutable {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -271,7 +277,7 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setISODate($year, $week, $dayOfWeek = 1): DateTimeImmutable {}
|
||||
public function setISODate(int $year, int $week, int $dayOfWeek = 1): DateTimeImmutable {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -286,7 +292,7 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setTime($hour, $minute, $second = 0, $microsecond = 0): DateTimeImmutable {}
|
||||
public function setTime(int $hour, int $minute, int $second = 0, int $microsecond = 0): DateTimeImmutable {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -298,7 +304,7 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setTimestamp($timestamp): DateTimeImmutable {}
|
||||
public function setTimestamp(int $timestamp): DateTimeImmutable {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -335,13 +341,13 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
* @link https://secure.php.net/manual/en/datetime.diff.php
|
||||
* @param DateTimeInterface $targetObject <p>The date to compare to.</p>
|
||||
* @param bool $absolute [optional] <p>Should the interval be forced to be positive?</p>
|
||||
* @return DateInterval|false
|
||||
* @return DateInterval
|
||||
* The {@link https://secure.php.net/manual/en/class.dateinterval.php DateInterval} object representing the
|
||||
* difference between the two dates or <b>FALSE</b> on failure.
|
||||
* difference between the two dates.
|
||||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function diff($targetObject, $absolute = false): DateInterval {}
|
||||
public function diff(DateTimeInterface $targetObject, bool $absolute = false): DateInterval {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -355,7 +361,7 @@ class DateTimeImmutable implements DateTimeInterface
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function format($format): string {}
|
||||
public function format(string $format): string {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
|
@ -501,7 +507,7 @@ class DateTime implements DateTimeInterface
|
|||
* @throws Exception Emits Exception in case of an error.
|
||||
* @since 5.2
|
||||
*/
|
||||
public function __construct($datetime = 'now', DateTimeZone $timezone = null) {}
|
||||
public function __construct(string $datetime = 'now', DateTimeZone|null $timezone = null) {}
|
||||
|
||||
/**
|
||||
* @param DateTimeImmutable $object
|
||||
|
@ -520,7 +526,7 @@ class DateTime implements DateTimeInterface
|
|||
* @link https://php.net/manual/en/datetime.createfromformat.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function createFromFormat($format, $datetime, DateTimeZone $timezone = null): DateTime|false {}
|
||||
public static function createFromFormat(string $format, string $datetime, DateTimeZone|null $timezone = null): DateTime|false {}
|
||||
|
||||
/**
|
||||
* Returns an array of warnings and errors found while parsing a date/time string
|
||||
|
@ -539,6 +545,13 @@ class DateTime implements DateTimeInterface
|
|||
*/
|
||||
public static function __set_state($array) {}
|
||||
|
||||
/**
|
||||
* @param DateTimeInterface $object
|
||||
* @return DateTime
|
||||
* @since 8.0
|
||||
*/
|
||||
public static function createFromInterface(DateTimeInterface $object): DateTime {}
|
||||
|
||||
/**
|
||||
* @return void
|
||||
* @link https://php.net/manual/en/datetime.wakeup.php
|
||||
|
@ -553,7 +566,7 @@ class DateTime implements DateTimeInterface
|
|||
* @link https://php.net/manual/en/datetime.format.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function format($format): string {}
|
||||
public function format(string $format): string {}
|
||||
|
||||
/**
|
||||
* Alter the timestamp of a DateTime object by incrementing or decrementing
|
||||
|
@ -563,7 +576,7 @@ class DateTime implements DateTimeInterface
|
|||
* @link https://php.net/manual/en/datetime.modify.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function modify($modifier): DateTime|false {}
|
||||
public function modify(string $modifier): DateTime|false {}
|
||||
|
||||
/**
|
||||
* Adds an amount of days, months, years, hours, minutes and seconds to a DateTime object
|
||||
|
@ -598,7 +611,7 @@ class DateTime implements DateTimeInterface
|
|||
* @link https://php.net/manual/en/datetime.settimezone.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setTimezone($timezone): DateTime {}
|
||||
public function setTimezone(DateTimeZone $timezone): DateTime {}
|
||||
|
||||
/**
|
||||
* Returns the timezone offset
|
||||
|
@ -618,7 +631,7 @@ class DateTime implements DateTimeInterface
|
|||
* @link https://php.net/manual/en/datetime.settime.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setTime($hour, $minute, $second = 0, $microsecond = 0): DateTime {}
|
||||
public function setTime(int $hour, int $minute, int $second = 0, int $microsecond = 0): DateTime {}
|
||||
|
||||
/**
|
||||
* Sets the current date of the DateTime object to a different date.
|
||||
|
@ -629,7 +642,7 @@ class DateTime implements DateTimeInterface
|
|||
* @link https://php.net/manual/en/datetime.setdate.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setDate($year, $month, $day): DateTime {}
|
||||
public function setDate(int $year, int $month, int $day): DateTime {}
|
||||
|
||||
/**
|
||||
* Set a date according to the ISO 8601 standard - using weeks and day offsets rather than specific dates.
|
||||
|
@ -640,7 +653,7 @@ class DateTime implements DateTimeInterface
|
|||
* @link https://php.net/manual/en/datetime.setisodate.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setISODate($year, $week, $dayOfWeek = 1): DateTime {}
|
||||
public function setISODate(int $year, int $week, int $dayOfWeek = 1): DateTime {}
|
||||
|
||||
/**
|
||||
* Sets the date and time based on a Unix timestamp.
|
||||
|
@ -649,7 +662,7 @@ class DateTime implements DateTimeInterface
|
|||
* @link https://php.net/manual/en/datetime.settimestamp.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setTimestamp($timestamp): DateTime {}
|
||||
public function setTimestamp(int $timestamp): DateTime {}
|
||||
|
||||
/**
|
||||
* Gets the Unix timestamp.
|
||||
|
@ -663,11 +676,11 @@ class DateTime implements DateTimeInterface
|
|||
* Returns the difference between two DateTime objects represented as a DateInterval.
|
||||
* @param DateTimeInterface $targetObject The date to compare to.
|
||||
* @param bool $absolute [optional] Whether to return absolute difference.
|
||||
* @return DateInterval|false The DateInterval object representing the difference between the two dates.
|
||||
* @return DateInterval The DateInterval object representing the difference between the two dates.
|
||||
* @link https://php.net/manual/en/datetime.diff.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function diff($targetObject, $absolute = false): DateInterval {}
|
||||
public function diff(DateTimeInterface $targetObject, bool $absolute = false): DateInterval {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -695,7 +708,7 @@ class DateTimeZone
|
|||
* @param string $timezone
|
||||
* @link https://php.net/manual/en/datetimezone.construct.php
|
||||
*/
|
||||
public function __construct($timezone) {}
|
||||
public function __construct(string $timezone) {}
|
||||
|
||||
/**
|
||||
* Returns associative array containing dst, offset and the timezone name
|
||||
|
@ -713,7 +726,7 @@ class DateTimeZone
|
|||
* @link https://php.net/manual/en/datetimezone.listidentifiers.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function listIdentifiers($timezoneGroup = DateTimeZone::ALL, $countryCode = null): array|false {}
|
||||
public static function listIdentifiers(int $timezoneGroup = DateTimeZone::ALL, string|null $countryCode = null): array {}
|
||||
|
||||
public static function __set_state($an_array) {}
|
||||
|
||||
|
@ -751,7 +764,7 @@ class DateTimeZone
|
|||
* @link https://php.net/manual/en/datetimezone.gettransitions.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getTransitions($timestampBegin = null, $timestampEnd = null): array|false {}
|
||||
public function getTransitions(int $timestampBegin = null, int $timestampEnd = null): array|false {}
|
||||
|
||||
/**
|
||||
* @link https://php.net/manual/en/datetime.wakeup.php
|
||||
|
@ -828,7 +841,7 @@ class DateInterval
|
|||
* @throws Exception when the $duration cannot be parsed as an interval.
|
||||
* @link https://php.net/manual/en/dateinterval.construct.php
|
||||
*/
|
||||
public function __construct($duration) {}
|
||||
public function __construct(string $duration) {}
|
||||
|
||||
/**
|
||||
* Sets up a DateInterval from the relative parts of the string
|
||||
|
@ -838,7 +851,7 @@ class DateInterval
|
|||
* @link https://php.net/manual/en/dateinterval.createfromdatestring.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function createFromDateString($datetime): DateInterval|false {}
|
||||
public static function createFromDateString(string $datetime): DateInterval|false {}
|
||||
|
||||
public static function __set_state($an_array) {}
|
||||
|
||||
|
@ -849,7 +862,7 @@ class DateInterval
|
|||
* @link https://php.net/manual/en/dateinterval.format.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function format($format): string {}
|
||||
public function format(string $format): string {}
|
||||
|
||||
#[TentativeType]
|
||||
public function __wakeup(): void {}
|
||||
|
@ -981,4 +994,10 @@ class DatePeriod implements IteratorAggregate
|
|||
*/
|
||||
#[TentativeType]
|
||||
public function getRecurrences(): ?int {}
|
||||
|
||||
/**
|
||||
* @return Iterator<int, TDate>
|
||||
* @since 8.0
|
||||
*/
|
||||
public function getIterator(): Iterator {}
|
||||
}
|
||||
|
|
|
@ -216,6 +216,6 @@ define('DOM_VALIDATION_ERR', 16);
|
|||
* @param SimpleXMLElement $node <p>
|
||||
* The <b>SimpleXMLElement</b> node.
|
||||
* </p>
|
||||
* @return DOMElement|null The <b>DOMElement</b> node added or <b>NULL</b> if any errors occur.
|
||||
* @return DOMElement The <b>DOMElement</b> node added.
|
||||
*/
|
||||
function dom_import_simplexml(object $node): DOMElement|null {}
|
||||
function dom_import_simplexml(object $node): DOMElement {}
|
||||
|
|
244
dom/dom_c.php
244
dom/dom_c.php
|
@ -5,6 +5,81 @@ use JetBrains\PhpStorm\Immutable;
|
|||
use JetBrains\PhpStorm\Internal\TentativeType;
|
||||
use JetBrains\PhpStorm\Language;
|
||||
|
||||
/**
|
||||
* @property-read DOMElement|null $firstElementChild
|
||||
* @property-read DOMElement|null $lastElementChild
|
||||
* @property-read int $childElementCount
|
||||
*
|
||||
* @since 8.0
|
||||
*/
|
||||
interface DOMParentNode
|
||||
{
|
||||
/**
|
||||
* Appends one or many nodes to the list of children behind the last
|
||||
* child node.
|
||||
*
|
||||
* @param DOMNode|string|null ...$nodes
|
||||
* @return void
|
||||
* @since 8.0
|
||||
*/
|
||||
public function append(...$nodes): void;
|
||||
|
||||
/**
|
||||
* Prepends one or many nodes to the list of children before the first
|
||||
* child node.
|
||||
*
|
||||
* @param DOMNode|string|null ...$nodes
|
||||
* @return void
|
||||
* @since 8.0
|
||||
*/
|
||||
public function prepend(...$nodes): void;
|
||||
}
|
||||
|
||||
/**
|
||||
* @property-read DOMElement|null $previousElementSibling
|
||||
* @property-read DOMElement|null $nextElementSibling
|
||||
*
|
||||
* @since 8.0
|
||||
*/
|
||||
interface DOMChildNode
|
||||
{
|
||||
/**
|
||||
* Acts as a simpler version of {@see DOMNode::removeChild()}.
|
||||
*
|
||||
* @return void
|
||||
* @since 8.0
|
||||
*/
|
||||
public function remove(): void;
|
||||
|
||||
/**
|
||||
* Add passed node(s) before the current node
|
||||
*
|
||||
* @param DOMNode|string|null ...$nodes
|
||||
* @return void
|
||||
* @since 8.0
|
||||
*/
|
||||
public function before(...$nodes): void;
|
||||
|
||||
/**
|
||||
* Add passed node(s) after the current node
|
||||
*
|
||||
* @param DOMNode|string|null ...$nodes
|
||||
* @return void
|
||||
* @since 8.0
|
||||
*/
|
||||
public function after(...$nodes): void;
|
||||
|
||||
/**
|
||||
* Replace current node with new node(s), a combination
|
||||
* of {@see DOMChildNode::remove()} + {@see DOMChildNode::append()}.
|
||||
*
|
||||
* @param DOMNode|string|null ...$nodes
|
||||
* @return void
|
||||
* @since 8.0
|
||||
*/
|
||||
public function replaceWith(...$nodes): void;
|
||||
}
|
||||
|
||||
/**
|
||||
* The DOMNode class
|
||||
* @link https://php.net/manual/en/class.domnode.php
|
||||
|
@ -136,7 +211,7 @@ class DOMNode
|
|||
* </p>
|
||||
* @return DOMNode The inserted node.
|
||||
*/
|
||||
public function insertBefore(DOMNode $node, DOMNode $child = null) {}
|
||||
public function insertBefore(DOMNode $node, DOMNode|null $child = null) {}
|
||||
|
||||
/**
|
||||
* Replaces a child
|
||||
|
@ -190,7 +265,7 @@ class DOMNode
|
|||
* </p>
|
||||
* @return static The cloned node.
|
||||
*/
|
||||
public function cloneNode($deep = false) {}
|
||||
public function cloneNode(bool $deep = false) {}
|
||||
|
||||
/**
|
||||
* Normalizes the node
|
||||
|
@ -214,7 +289,7 @@ class DOMNode
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function isSupported($feature, $version): bool {}
|
||||
public function isSupported(string $feature, string $version): bool {}
|
||||
|
||||
/**
|
||||
* Checks if node has attributes
|
||||
|
@ -249,7 +324,7 @@ class DOMNode
|
|||
* @return string The prefix of the namespace.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function lookupPrefix($namespace): ?string {}
|
||||
public function lookupPrefix(string $namespace): ?string {}
|
||||
|
||||
/**
|
||||
* Checks if the specified namespaceURI is the default namespace or not
|
||||
|
@ -261,17 +336,18 @@ class DOMNode
|
|||
* namespace, false otherwise.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function isDefaultNamespace($namespace): bool {}
|
||||
public function isDefaultNamespace(string $namespace): bool {}
|
||||
|
||||
/**
|
||||
* Gets the namespace URI of the node based on the prefix
|
||||
* @link https://php.net/manual/en/domnode.lookupnamespaceuri.php
|
||||
* @param string $prefix <p>
|
||||
* @param string|null $prefix <p>
|
||||
* The prefix of the namespace.
|
||||
* </p>
|
||||
* @return string The namespace URI of the node.
|
||||
* @return string|null The namespace URI of the node.
|
||||
*/
|
||||
public function lookupNamespaceUri($prefix) {}
|
||||
#[TentativeType]
|
||||
public function lookupNamespaceURI(?string $prefix): ?string {}
|
||||
|
||||
/**
|
||||
* @param DOMNode $arg
|
||||
|
@ -324,7 +400,7 @@ class DOMNode
|
|||
* @return string|false Canonicalized nodes as a string or FALSE on failure
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function C14N($exclusive = false, $withComments = false, array $xpath = null, array $nsPrefixes = null): string|false {}
|
||||
public function C14N(bool $exclusive = false, bool $withComments = false, array|null $xpath = null, array|null $nsPrefixes = null): string|false {}
|
||||
|
||||
/**
|
||||
* Canonicalize nodes to a file.
|
||||
|
@ -337,7 +413,7 @@ class DOMNode
|
|||
* @return int|false Number of bytes written or FALSE on failure
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function C14NFile($uri, $exclusive = false, $withComments = false, array $xpath = null, array $nsPrefixes = null): int|false {}
|
||||
public function C14NFile(string $uri, bool $exclusive = false, bool $withComments = false, array|null $xpath = null, array|null $nsPrefixes = null): int|false {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -426,7 +502,7 @@ class DOMImplementation
|
|||
* @return mixed
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getFeature($feature, $version) {}
|
||||
public function getFeature(string $feature, string $version): never {}
|
||||
|
||||
/**
|
||||
* Test if the DOM implementation implements a specific feature
|
||||
|
@ -458,7 +534,7 @@ class DOMImplementation
|
|||
* ownerDocument set to null.
|
||||
* @throws DOMException If there is an error with the namespace
|
||||
*/
|
||||
public function createDocumentType($qualifiedName, $publicId, $systemId) {}
|
||||
public function createDocumentType(string $qualifiedName, string $publicId = '', string $systemId = '') {}
|
||||
|
||||
/**
|
||||
* Creates a DOMDocument object of the specified type with its document element
|
||||
|
@ -480,7 +556,7 @@ class DOMImplementation
|
|||
* implementation. If there is an error with the namespace,
|
||||
* as determined by $namespace and $qualifiedName.
|
||||
*/
|
||||
public function createDocument($namespace, $qualifiedName, DOMDocumentType $doctype = null) {}
|
||||
public function createDocument(?string $namespace = null, string $qualifiedName = '', DOMDocumentType|null $doctype = null) {}
|
||||
}
|
||||
|
||||
class DOMNameSpaceNode
|
||||
|
@ -499,7 +575,7 @@ class DOMNameSpaceNode
|
|||
* The DOMDocumentFragment class
|
||||
* @link https://php.net/manual/en/class.domdocumentfragment.php
|
||||
*/
|
||||
class DOMDocumentFragment extends DOMNode
|
||||
class DOMDocumentFragment extends DOMNode implements DOMParentNode
|
||||
{
|
||||
public $childElementCount;
|
||||
public $lastElementChild;
|
||||
|
@ -516,7 +592,7 @@ class DOMDocumentFragment extends DOMNode
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function appendXML($data): bool {}
|
||||
public function appendXML(string $data): bool {}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
|
@ -534,7 +610,7 @@ class DOMDocumentFragment extends DOMNode
|
|||
* document; serves as the root of the document tree.
|
||||
* @link https://php.net/manual/en/class.domdocument.php
|
||||
*/
|
||||
class DOMDocument extends DOMNode
|
||||
class DOMDocument extends DOMNode implements DOMParentNode
|
||||
{
|
||||
/**
|
||||
* @var string|null
|
||||
|
@ -688,7 +764,7 @@ class DOMDocument extends DOMNode
|
|||
* @param string $version [optional] The version number of the document as part of the XML declaration.
|
||||
* @param string $encoding [optional] The encoding of the document as part of the XML declaration.
|
||||
*/
|
||||
public function __construct($version = '1.0', $encoding = '') {}
|
||||
public function __construct(string $version = '1.0', string $encoding = '') {}
|
||||
|
||||
/**
|
||||
* Create new element node
|
||||
|
@ -704,7 +780,7 @@ class DOMDocument extends DOMNode
|
|||
* if an error occurred.
|
||||
* @throws DOMException If invalid $localName
|
||||
*/
|
||||
public function createElement($localName, $value = '') {}
|
||||
public function createElement(string $localName, string $value = '') {}
|
||||
|
||||
/**
|
||||
* Create new document fragment
|
||||
|
@ -723,7 +799,7 @@ class DOMDocument extends DOMNode
|
|||
* @return DOMText|false The new DOMText or false if an error occurred.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function createTextNode($data): DOMText {}
|
||||
public function createTextNode(string $data): DOMText {}
|
||||
|
||||
/**
|
||||
* Create new comment node
|
||||
|
@ -734,7 +810,7 @@ class DOMDocument extends DOMNode
|
|||
* @return DOMComment|false The new DOMComment or false if an error occurred.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function createComment($data): DOMComment {}
|
||||
public function createComment(string $data): DOMComment {}
|
||||
|
||||
/**
|
||||
* Create new cdata node
|
||||
|
@ -744,7 +820,7 @@ class DOMDocument extends DOMNode
|
|||
* </p>
|
||||
* @return DOMCDATASection|false The new DOMCDATASection or false if an error occurred.
|
||||
*/
|
||||
public function createCDATASection($data) {}
|
||||
public function createCDATASection(string $data) {}
|
||||
|
||||
/**
|
||||
* Creates new PI node
|
||||
|
@ -757,7 +833,7 @@ class DOMDocument extends DOMNode
|
|||
* </p>
|
||||
* @return DOMProcessingInstruction|false The new DOMProcessingInstruction or false if an error occurred.
|
||||
*/
|
||||
public function createProcessingInstruction($target, $data = null) {}
|
||||
public function createProcessingInstruction(string $target, string $data = null) {}
|
||||
|
||||
/**
|
||||
* Create new attribute
|
||||
|
@ -768,7 +844,7 @@ class DOMDocument extends DOMNode
|
|||
* @return DOMAttr|false The new DOMAttr or false if an error occurred.
|
||||
* @throws DOMException If invalid $localName
|
||||
*/
|
||||
public function createAttribute($localName) {}
|
||||
public function createAttribute(string $localName) {}
|
||||
|
||||
/**
|
||||
* Create new entity reference node
|
||||
|
@ -781,7 +857,7 @@ class DOMDocument extends DOMNode
|
|||
* @return DOMEntityReference|false The new DOMEntityReference or false if an error
|
||||
* occurred.
|
||||
*/
|
||||
public function createEntityReference($name) {}
|
||||
public function createEntityReference(string $name) {}
|
||||
|
||||
/**
|
||||
* Searches for all elements with given tag name
|
||||
|
@ -794,7 +870,7 @@ class DOMDocument extends DOMNode
|
|||
* elements.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getElementsByTagName($qualifiedName): DOMNodeList {}
|
||||
public function getElementsByTagName(string $qualifiedName): DOMNodeList {}
|
||||
|
||||
/**
|
||||
* Import node into current document
|
||||
|
@ -811,7 +887,7 @@ class DOMDocument extends DOMNode
|
|||
* </p>
|
||||
* @return DOMNode|false The copied node or false, if it cannot be copied.
|
||||
*/
|
||||
public function importNode(DOMNode $node, $deep = false) {}
|
||||
public function importNode(DOMNode $node, bool $deep = false) {}
|
||||
|
||||
/**
|
||||
* Create new element node with an associated namespace
|
||||
|
@ -829,7 +905,7 @@ class DOMDocument extends DOMNode
|
|||
* @return DOMElement|false The new DOMElement or false if an error occurred.
|
||||
* @throws DOMException If invalid $namespace or $qualifiedName
|
||||
*/
|
||||
public function createElementNS($namespace, $qualifiedName, $value = '') {}
|
||||
public function createElementNS(string|null $namespace, string $qualifiedName, string $value = '') {}
|
||||
|
||||
/**
|
||||
* Create new attribute node with an associated namespace
|
||||
|
@ -843,7 +919,7 @@ class DOMDocument extends DOMNode
|
|||
* @return DOMAttr|false The new DOMAttr or false if an error occurred.
|
||||
* @throws DOMException If invalid $namespace or $qualifiedName
|
||||
*/
|
||||
public function createAttributeNS($namespace, $qualifiedName) {}
|
||||
public function createAttributeNS(string|null $namespace, string $qualifiedName) {}
|
||||
|
||||
/**
|
||||
* Searches for all elements with given tag name in specified namespace
|
||||
|
@ -860,7 +936,7 @@ class DOMDocument extends DOMNode
|
|||
* elements.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getElementsByTagNameNS($namespace, $localName): DOMNodeList {}
|
||||
public function getElementsByTagNameNS(string|null $namespace, string $localName): DOMNodeList {}
|
||||
|
||||
/**
|
||||
* Searches for an element with a certain id
|
||||
|
@ -872,7 +948,7 @@ class DOMDocument extends DOMNode
|
|||
* not found.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getElementById($elementId): ?DOMElement {}
|
||||
public function getElementById(string $elementId): ?DOMElement {}
|
||||
|
||||
/**
|
||||
* @param DOMNode $node
|
||||
|
@ -918,7 +994,7 @@ class DOMDocument extends DOMNode
|
|||
* DOMDocument and issues E_STRICT
|
||||
* warning.
|
||||
*/
|
||||
public function load($filename, $options = null) {}
|
||||
public function load(string $filename, int $options = null) {}
|
||||
|
||||
/**
|
||||
* Dumps the internal XML tree back into a file
|
||||
|
@ -947,7 +1023,7 @@ class DOMDocument extends DOMNode
|
|||
* DOMDocument and issues E_STRICT
|
||||
* warning.
|
||||
*/
|
||||
public function loadXML($source, $options = null) {}
|
||||
public function loadXML(string $source, int $options = null) {}
|
||||
|
||||
/**
|
||||
* Dumps the internal XML tree back into a string
|
||||
|
@ -962,7 +1038,7 @@ class DOMDocument extends DOMNode
|
|||
* @return string|false the XML, or false if an error occurred.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function saveXML(?DOMNode $node = null, $options = null): string|false {}
|
||||
public function saveXML(?DOMNode $node = null, int $options = null): string|false {}
|
||||
|
||||
/**
|
||||
* Validates the document based on its DTD
|
||||
|
@ -983,7 +1059,7 @@ class DOMDocument extends DOMNode
|
|||
* @return int|false the number of XIncludes in the document.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function xinclude($options = null): int|false {}
|
||||
public function xinclude(int $options = null): int|false {}
|
||||
|
||||
/**
|
||||
* Load HTML from a string
|
||||
|
@ -999,7 +1075,7 @@ class DOMDocument extends DOMNode
|
|||
* DOMDocument and issues E_STRICT
|
||||
* warning.
|
||||
*/
|
||||
public function loadHTML($source, $options = 0) {}
|
||||
public function loadHTML(string $source, int $options = 0) {}
|
||||
|
||||
/**
|
||||
* Load HTML from a file
|
||||
|
@ -1015,7 +1091,7 @@ class DOMDocument extends DOMNode
|
|||
* DOMDocument and issues E_STRICT
|
||||
* warning.
|
||||
*/
|
||||
public function loadHTMLFile($filename, $options = 0) {}
|
||||
public function loadHTMLFile(string $filename, int $options = 0) {}
|
||||
|
||||
/**
|
||||
* Dumps the internal document into a string using HTML formatting
|
||||
|
@ -1034,7 +1110,7 @@ class DOMDocument extends DOMNode
|
|||
* @return int|false the number of bytes written or false if an error occurred.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function saveHTMLFile($filename): int|false {}
|
||||
public function saveHTMLFile(string $filename): int|false {}
|
||||
|
||||
/**
|
||||
* Validates a document based on a schema
|
||||
|
@ -1071,7 +1147,7 @@ class DOMDocument extends DOMNode
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function relaxNGValidate($filename): bool {}
|
||||
public function relaxNGValidate(string $filename): bool {}
|
||||
|
||||
/**
|
||||
* Performs relaxNG validation on the document
|
||||
|
@ -1082,7 +1158,7 @@ class DOMDocument extends DOMNode
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function relaxNGValidateSource($source): bool {}
|
||||
public function relaxNGValidateSource(string $source): bool {}
|
||||
|
||||
/**
|
||||
* Register extended class used to create base node type
|
||||
|
@ -1099,7 +1175,7 @@ class DOMDocument extends DOMNode
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function registerNodeClass($baseClass, $extendedClass): bool {}
|
||||
public function registerNodeClass(string $baseClass, string|null $extendedClass): bool {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1127,7 +1203,7 @@ class DOMNodeList implements IteratorAggregate, Countable
|
|||
* DOMNodeList, or null if that is not a valid
|
||||
* index.
|
||||
*/
|
||||
public function item($index) {}
|
||||
public function item(int $index) {}
|
||||
|
||||
/**
|
||||
* @return int<0, max>
|
||||
|
@ -1135,6 +1211,12 @@ class DOMNodeList implements IteratorAggregate, Countable
|
|||
*/
|
||||
#[TentativeType]
|
||||
public function count(): int {}
|
||||
|
||||
/**
|
||||
* @return Iterator
|
||||
* @since 8.0
|
||||
*/
|
||||
public function getIterator(): Iterator {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1154,7 +1236,7 @@ class DOMNamedNodeMap implements IteratorAggregate, Countable
|
|||
* null if no node is found.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getNamedItem($qualifiedName): ?DOMNode {}
|
||||
public function getNamedItem(string $qualifiedName): ?DOMNode {}
|
||||
|
||||
/**
|
||||
* @param DOMNode $arg
|
||||
|
@ -1177,7 +1259,7 @@ class DOMNamedNodeMap implements IteratorAggregate, Countable
|
|||
* in this map).
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function item($index): ?DOMNode {}
|
||||
public function item(int $index): ?DOMNode {}
|
||||
|
||||
/**
|
||||
* Retrieves a node specified by local name and namespace URI
|
||||
|
@ -1192,7 +1274,7 @@ class DOMNamedNodeMap implements IteratorAggregate, Countable
|
|||
* null if no node is found.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getNamedItemNS($namespaceURI = '', $localName = ''): ?DOMNode {}
|
||||
public function getNamedItemNS(?string $namespace, string $localName): ?DOMNode {}
|
||||
|
||||
/**
|
||||
* @param DOMNode $arg [optional]
|
||||
|
@ -1211,6 +1293,12 @@ class DOMNamedNodeMap implements IteratorAggregate, Countable
|
|||
*/
|
||||
#[TentativeType]
|
||||
public function count(): int {}
|
||||
|
||||
/**
|
||||
* @return Iterator
|
||||
* @since 8.0
|
||||
*/
|
||||
public function getIterator(): Iterator {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1218,7 +1306,7 @@ class DOMNamedNodeMap implements IteratorAggregate, Countable
|
|||
* No nodes directly correspond to this class, but other nodes do inherit from it.
|
||||
* @link https://php.net/manual/en/class.domcharacterdata.php
|
||||
*/
|
||||
class DOMCharacterData extends DOMNode
|
||||
class DOMCharacterData extends DOMNode implements DOMChildNode
|
||||
{
|
||||
/**
|
||||
* @var string
|
||||
|
@ -1249,7 +1337,7 @@ class DOMCharacterData extends DOMNode
|
|||
* and count exceeds the length, then all 16-bit units
|
||||
* to the end of the data are returned.
|
||||
*/
|
||||
public function substringData($offset, $count) {}
|
||||
public function substringData(int $offset, int $count) {}
|
||||
|
||||
/**
|
||||
* Append the string to the end of the character data of the node
|
||||
|
@ -1260,7 +1348,7 @@ class DOMCharacterData extends DOMNode
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function appendData($data): bool {}
|
||||
public function appendData(string $data): bool {}
|
||||
|
||||
/**
|
||||
* Insert a string at the specified 16-bit unit offset
|
||||
|
@ -1274,7 +1362,7 @@ class DOMCharacterData extends DOMNode
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function insertData($offset, $data): bool {}
|
||||
public function insertData(int $offset, string $data): bool {}
|
||||
|
||||
/**
|
||||
* Remove a range of characters from the node
|
||||
|
@ -1290,7 +1378,7 @@ class DOMCharacterData extends DOMNode
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function deleteData($offset, $count): bool {}
|
||||
public function deleteData(int $offset, int $count): bool {}
|
||||
|
||||
/**
|
||||
* Replace a substring within the DOMCharacterData node
|
||||
|
@ -1309,7 +1397,7 @@ class DOMCharacterData extends DOMNode
|
|||
* @return bool
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function replaceData($offset, $count, $data): bool {}
|
||||
public function replaceData(int $offset, int $count, string $data): bool {}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
|
@ -1385,7 +1473,7 @@ class DOMAttr extends DOMNode
|
|||
* @param string $value [optional] <p>The value of the attribute.</p>
|
||||
* @throws DOMException If invalid $name
|
||||
*/
|
||||
public function __construct($name, $value = '') {}
|
||||
public function __construct(string $name, string $value = '') {}
|
||||
|
||||
/**
|
||||
* Checks if attribute is a defined ID
|
||||
|
@ -1400,7 +1488,7 @@ class DOMAttr extends DOMNode
|
|||
* The DOMElement class
|
||||
* @link https://php.net/manual/en/class.domelement.php
|
||||
*/
|
||||
class DOMElement extends DOMNode
|
||||
class DOMElement extends DOMNode implements DOMParentNode, DOMChildNode
|
||||
{
|
||||
/**
|
||||
* @var DOMNode|null
|
||||
|
@ -1464,7 +1552,7 @@ class DOMElement extends DOMNode
|
|||
* @param string $namespace [optional] A namespace URI to create the element within a specific namespace.
|
||||
* @throws DOMException If invalid $qualifiedName
|
||||
*/
|
||||
public function __construct($qualifiedName, $value = null, $namespace = null) {}
|
||||
public function __construct(string $qualifiedName, string|null $value = null, string $namespace = null) {}
|
||||
|
||||
/**
|
||||
* Returns value of attribute
|
||||
|
@ -1476,7 +1564,7 @@ class DOMElement extends DOMNode
|
|||
* given name is found.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getAttribute($qualifiedName): string {}
|
||||
public function getAttribute(string $qualifiedName): string {}
|
||||
|
||||
/**
|
||||
* Adds new attribute
|
||||
|
@ -1489,7 +1577,7 @@ class DOMElement extends DOMNode
|
|||
* </p>
|
||||
* @return DOMAttr|false The new DOMAttr or false if an error occurred.
|
||||
*/
|
||||
public function setAttribute($qualifiedName, $value) {}
|
||||
public function setAttribute(string $qualifiedName, string $value) {}
|
||||
|
||||
/**
|
||||
* Removes attribute
|
||||
|
@ -1500,7 +1588,7 @@ class DOMElement extends DOMNode
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function removeAttribute($qualifiedName): bool {}
|
||||
public function removeAttribute(string $qualifiedName): bool {}
|
||||
|
||||
/**
|
||||
* Returns attribute node
|
||||
|
@ -1510,7 +1598,7 @@ class DOMElement extends DOMNode
|
|||
* </p>
|
||||
* @return DOMAttr The attribute node.
|
||||
*/
|
||||
public function getAttributeNode($qualifiedName) {}
|
||||
public function getAttributeNode(string $qualifiedName) {}
|
||||
|
||||
/**
|
||||
* Adds new attribute node to element
|
||||
|
@ -1543,7 +1631,7 @@ class DOMElement extends DOMNode
|
|||
* DOMNodeList of all matched elements.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getElementsByTagName($qualifiedName): DOMNodeList {}
|
||||
public function getElementsByTagName(string $qualifiedName): DOMNodeList {}
|
||||
|
||||
/**
|
||||
* Returns value of attribute
|
||||
|
@ -1559,7 +1647,7 @@ class DOMElement extends DOMNode
|
|||
* is found.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getAttributeNS($namespace, $localName): string {}
|
||||
public function getAttributeNS(string|null $namespace, string $localName): string {}
|
||||
|
||||
/**
|
||||
* Adds new attribute
|
||||
|
@ -1576,7 +1664,7 @@ class DOMElement extends DOMNode
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setAttributeNS($namespace, $qualifiedName, $value): void {}
|
||||
public function setAttributeNS(string|null $namespace, string $qualifiedName, string $value): void {}
|
||||
|
||||
/**
|
||||
* Removes attribute
|
||||
|
@ -1590,7 +1678,7 @@ class DOMElement extends DOMNode
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function removeAttributeNS($namespace, $localName): void {}
|
||||
public function removeAttributeNS(string|null $namespace, string $localName): void {}
|
||||
|
||||
/**
|
||||
* Returns attribute node
|
||||
|
@ -1603,7 +1691,7 @@ class DOMElement extends DOMNode
|
|||
* </p>
|
||||
* @return DOMAttr The attribute node.
|
||||
*/
|
||||
public function getAttributeNodeNS($namespace, $localName) {}
|
||||
public function getAttributeNodeNS(string|null $namespace, string $localName) {}
|
||||
|
||||
/**
|
||||
* Adds new attribute node to element
|
||||
|
@ -1628,7 +1716,7 @@ class DOMElement extends DOMNode
|
|||
* which they are encountered in a preorder traversal of this element tree.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getElementsByTagNameNS($namespace, $localName): DOMNodeList {}
|
||||
public function getElementsByTagNameNS(string|null $namespace, string $localName): DOMNodeList {}
|
||||
|
||||
/**
|
||||
* Checks to see if attribute exists
|
||||
|
@ -1639,7 +1727,7 @@ class DOMElement extends DOMNode
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function hasAttribute($qualifiedName): bool {}
|
||||
public function hasAttribute(string $qualifiedName): bool {}
|
||||
|
||||
/**
|
||||
* Checks to see if attribute exists
|
||||
|
@ -1653,7 +1741,7 @@ class DOMElement extends DOMNode
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function hasAttributeNS($namespace, $localName): bool {}
|
||||
public function hasAttributeNS(string|null $namespace, string $localName): bool {}
|
||||
|
||||
/**
|
||||
* Declares the attribute specified by name to be of type ID
|
||||
|
@ -1668,7 +1756,7 @@ class DOMElement extends DOMNode
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setIdAttribute($qualifiedName, $isId): void {}
|
||||
public function setIdAttribute(string $qualifiedName, bool $isId): void {}
|
||||
|
||||
/**
|
||||
* Declares the attribute specified by local name and namespace URI to be of type ID
|
||||
|
@ -1686,7 +1774,7 @@ class DOMElement extends DOMNode
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setIdAttributeNS($namespace, $qualifiedName, $isId): void {}
|
||||
public function setIdAttributeNS(string $namespace, string $qualifiedName, bool $isId): void {}
|
||||
|
||||
/**
|
||||
* Declares the attribute specified by node to be of type ID
|
||||
|
@ -1701,7 +1789,7 @@ class DOMElement extends DOMNode
|
|||
* @return void
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setIdAttributeNode(DOMAttr $attr, $isId): void {}
|
||||
public function setIdAttributeNode(DOMAttr $attr, bool $isId): void {}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
|
@ -1752,7 +1840,7 @@ class DOMText extends DOMCharacterData
|
|||
* @link https://php.net/manual/en/domtext.construct.php
|
||||
* @param string $data [optional] The value of the text node. If not supplied an empty text node is created.
|
||||
*/
|
||||
public function __construct($data) {}
|
||||
public function __construct(string $data) {}
|
||||
|
||||
/**
|
||||
* Breaks this node into two nodes at the specified offset
|
||||
|
@ -1763,7 +1851,7 @@ class DOMText extends DOMCharacterData
|
|||
* @return DOMText The new node of the same type, which contains all the content at and after the
|
||||
* offset.
|
||||
*/
|
||||
public function splitText($offset) {}
|
||||
public function splitText(int $offset) {}
|
||||
|
||||
/**
|
||||
* Indicates whether this text node contains whitespace
|
||||
|
@ -1794,7 +1882,7 @@ class DOMComment extends DOMCharacterData
|
|||
* @link https://php.net/manual/en/domcomment.construct.php
|
||||
* @param string $data [optional] The value of the comment
|
||||
*/
|
||||
public function __construct($data) {}
|
||||
public function __construct(string $data) {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1865,7 +1953,7 @@ class DOMCdataSection extends DOMText
|
|||
* @param string $data The value of the CDATA node. If not supplied, an empty CDATA node is created.
|
||||
* @link https://secure.php.net/manual/en/domcdatasection.construct.php
|
||||
*/
|
||||
public function __construct($data) {}
|
||||
public function __construct(string $data) {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -2002,7 +2090,7 @@ class DOMEntityReference extends DOMNode
|
|||
* @link https://php.net/manual/en/domentityreference.construct.php
|
||||
* @param string $name The name of the entity reference.
|
||||
*/
|
||||
public function __construct($name) {}
|
||||
public function __construct(string $name) {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -2027,7 +2115,7 @@ class DOMProcessingInstruction extends DOMNode
|
|||
* @param string $name The tag name of the processing instruction.
|
||||
* @param string $value [optional] The value of the processing instruction.
|
||||
*/
|
||||
public function __construct($name, $value) {}
|
||||
public function __construct(string $name, string $value) {}
|
||||
}
|
||||
|
||||
class DOMStringExtend
|
||||
|
@ -2063,7 +2151,7 @@ class DOMXPath
|
|||
* @param DOMDocument $document The <classname>DOMDocument</classname> associated with the <classname>DOMXPath</classname>.
|
||||
* @param bool $registerNodeNS [optional] allow global flag to configure query() or evaluate() calls. Since 8.0.
|
||||
*/
|
||||
public function __construct(DOMDocument $document) {}
|
||||
public function __construct(DOMDocument $document, bool $registerNodeNS = true) {}
|
||||
|
||||
/**
|
||||
* Registers the namespace with the <classname>DOMXPath</classname> object
|
||||
|
@ -2077,7 +2165,7 @@ class DOMXPath
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function registerNamespace($prefix, $namespace): bool {}
|
||||
public function registerNamespace(string $prefix, string $namespace): bool {}
|
||||
|
||||
/**
|
||||
* Evaluates the given XPath expression
|
||||
|
@ -2098,7 +2186,7 @@ class DOMXPath
|
|||
* is malformed or the contextnode is invalid.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function query(#[Language("XPath")] $expression, $contextNode = null, $registerNodeNS = true): mixed {}
|
||||
public function query(#[Language("XPath")] string $expression, DOMNode|null $contextNode = null, bool $registerNodeNS = true): mixed {}
|
||||
|
||||
/**
|
||||
* Evaluates the given XPath expression and returns a typed result if possible.
|
||||
|
@ -2119,7 +2207,7 @@ class DOMXPath
|
|||
* containing all nodes matching the given XPath expression.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function evaluate(#[Language("XPath")] $expression, $contextNode = null, $registerNodeNS = true): mixed {}
|
||||
public function evaluate(#[Language("XPath")] string $expression, DOMNode|null $contextNode = null, bool $registerNodeNS = true): mixed {}
|
||||
|
||||
/**
|
||||
* Register PHP functions as XPath functions
|
||||
|
|
|
@ -217,6 +217,21 @@ function enchant_dict_add_to_personal($dict, $word) {}
|
|||
*/
|
||||
function enchant_dict_add_to_session($dict, $word) {}
|
||||
|
||||
/**
|
||||
* (PHP 8)<br/>
|
||||
* Add a word to personal word list
|
||||
* @link https://php.net/manual/en/function.enchant-dict-add.php
|
||||
* @param EnchantDictionary $dictionary <p>
|
||||
* An Enchant dictionary returned by enchant_broker_request_dict() or enchant_broker_request_pwl_dict().
|
||||
* </p>
|
||||
* @param string $word <p>
|
||||
* The word to add
|
||||
* </p>
|
||||
* @return void
|
||||
* @since 8.0
|
||||
*/
|
||||
function enchant_dict_add($dictionary, $word) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.3.0, PECL enchant >= 0.1.0 )<br/>
|
||||
* whether or not 'word' exists in this spelling-session
|
||||
|
@ -261,6 +276,21 @@ function enchant_dict_store_replacement($dict, $mis, $cor) {}
|
|||
*/
|
||||
function enchant_dict_get_error($dict) {}
|
||||
|
||||
/**
|
||||
* (PHP 8)<br/>
|
||||
* Whether or not 'word' exists in this spelling-session
|
||||
* @link https://php.net/manual/en/function.enchant-dict-is-added.php
|
||||
* @param EnchantDictionary $dictionary <p>
|
||||
* An Enchant dictionary returned by enchant_broker_request_dict() or enchant_broker_request_pwl_dict().
|
||||
* </p>
|
||||
* @param string $word <p>
|
||||
* The word to lookup
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> if the word exists or <b>FALSE</b>
|
||||
* @since 8.0
|
||||
*/
|
||||
function enchant_dict_is_added($dictionary, $word) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.3.0, PECL enchant >= 0.1.0 )<br/>
|
||||
* Describes an individual dictionary
|
||||
|
|
|
@ -170,13 +170,7 @@ class finfo
|
|||
* @param int $flags [optional]
|
||||
* @param string $magic_database [optional]
|
||||
*/
|
||||
public function __construct($flags, $magic_database) {}
|
||||
|
||||
/**
|
||||
* @param $options [optional]
|
||||
* @param $arg [optional]
|
||||
*/
|
||||
public function finfo($options, $arg) {}
|
||||
public function __construct(int $flags, string|null $magic_database) {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL fileinfo >= 0.1.0)<br/>
|
||||
|
@ -188,7 +182,7 @@ class finfo
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function set_flags($flags) {}
|
||||
public function set_flags(int $flags) {}
|
||||
|
||||
/**
|
||||
* (PHP >= 5.3.0, PECL fileinfo >= 0.1.0)<br/>
|
||||
|
@ -209,7 +203,7 @@ class finfo
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function file($filename, $flags = FILEINFO_NONE, $context = null): string|false {}
|
||||
public function file(string $filename, int $flags = FILEINFO_NONE, $context = null): string|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.3.0, PECL fileinfo >= 0.1.0)<br/>
|
||||
|
@ -228,5 +222,5 @@ class finfo
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public function buffer($string, $flags = FILEINFO_NONE, $context = null): string|false {}
|
||||
public function buffer(string $string, int $flags = FILEINFO_NONE, $context = null): string|false {}
|
||||
}
|
||||
|
|
|
@ -91,6 +91,14 @@ define('FILTER_VALIDATE_INT', 257);
|
|||
*/
|
||||
define('FILTER_VALIDATE_BOOLEAN', 258);
|
||||
|
||||
/**
|
||||
* ID of "boolean" filter.
|
||||
* @link https://php.net/manual/en/filter.constants.php
|
||||
* @link https://php.net/manual/en/filter.filters.validate.php
|
||||
* @since 8.0 Using `FILTER_VALIDATE_BOOL` is preferred.
|
||||
*/
|
||||
define('FILTER_VALIDATE_BOOL', 258);
|
||||
|
||||
/**
|
||||
* ID of "float" filter.
|
||||
* @link https://php.net/manual/en/filter.constants.php
|
||||
|
|
|
@ -213,11 +213,11 @@ function ftp_exec($ftp, string $command): bool {}
|
|||
* @param string $command <p>
|
||||
* The command to execute.
|
||||
* </p>
|
||||
* @return string[] the server's response as an array of strings.
|
||||
* @return string[]|null the server's response as an array of strings.
|
||||
* 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): array {}
|
||||
function ftp_raw($ftp, string $command): array|null {}
|
||||
|
||||
/**
|
||||
* Creates a directory
|
||||
|
|
|
@ -78,7 +78,7 @@ function dcgettext(string $domain, string $message, int $category): string {}
|
|||
* </p>
|
||||
* @return string|false The full pathname for the <i>domain</i> currently being set.
|
||||
*/
|
||||
function bindtextdomain(string $domain, string $directory): string|false {}
|
||||
function bindtextdomain(string $domain, string|null $directory): string|false {}
|
||||
|
||||
/**
|
||||
* Plural version of gettext
|
||||
|
@ -133,4 +133,4 @@ function dcngettext(string $domain, string $singular, string $plural, int $count
|
|||
* </p>
|
||||
* @return string|false A string on success.
|
||||
*/
|
||||
function bind_textdomain_codeset(string $domain, string $codeset): string|false {}
|
||||
function bind_textdomain_codeset(string $domain, string|null $codeset): string|false {}
|
||||
|
|
|
@ -308,13 +308,13 @@ function hash_algos(): array {}
|
|||
* If <b>length</b> is 0, the output length will default to the chosen hash function size.</p>
|
||||
* @param string $info [optional] <p>Application/context-specific info string.</p>
|
||||
* @param string $salt [optional] <p>Salt to use during derivation. While optional, adding random salt significantly improves the strength of HKDF.</p>
|
||||
* @return string|false <p>Returns a string containing a raw binary representation of the derived key (also known as output keying material - OKM); or <b>FALSE</b> on failure.</p>
|
||||
* @return string <p>Returns a string containing a raw binary representation of the derived key (also known as output keying material - OKM)</p>
|
||||
* @since 7.1.2
|
||||
* Generate a HKDF key derivation of a supplied key input
|
||||
* @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 = ''): string|false {}
|
||||
function hash_hkdf(string $algo, string $key, int $length = 0, string $info = '', string $salt = ''): string {}
|
||||
|
||||
/**
|
||||
* Return a list of registered hashing algorithms suitable for hash_hmac
|
||||
|
@ -457,5 +457,5 @@ final class HashContext
|
|||
/**
|
||||
* @param array $data
|
||||
*/
|
||||
public function __unserialize($data): void {}
|
||||
public function __unserialize(array $data): void {}
|
||||
}
|
||||
|
|
|
@ -412,7 +412,7 @@ function imap_headers($imap): array|false {}
|
|||
* <dt>fetchsubject</dt><dd>subject line formatted to fit subjectlength characters</dd>
|
||||
* </dl>
|
||||
*/
|
||||
function imap_headerinfo($imap, int $message_num, int $from_length = 0, int $subject_length = 0, $default_host = null): stdClass|false {}
|
||||
function imap_headerinfo($imap, int $message_num, int $from_length = 0, int $subject_length = 0): stdClass|false {}
|
||||
|
||||
/**
|
||||
* Parse mail headers from a string
|
||||
|
@ -710,7 +710,7 @@ function imap_fetchstructure($imap, int $message_num, int $flags = 0): stdClass|
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function imap_gc($imap, int $flags = 0): bool {}
|
||||
function imap_gc($imap, int $flags): bool {}
|
||||
|
||||
/**
|
||||
* Delete all messages marked for deletion
|
||||
|
@ -1143,7 +1143,7 @@ function imap_clearflag_full($imap, string $sequence, string $flag, int $options
|
|||
* @return array|false an array of message numbers sorted by the given
|
||||
* parameters.
|
||||
*/
|
||||
function imap_sort($imap, int $criteria, int $reverse, int $flags = 0, ?string $search_criteria = null, ?string $charset = null): array|false {}
|
||||
function imap_sort($imap, int $criteria, bool $reverse, int $flags = 0, ?string $search_criteria = null, ?string $charset = null): array|false {}
|
||||
|
||||
/**
|
||||
* This function returns the UID for the given message sequence number
|
||||
|
@ -1538,56 +1538,6 @@ function imap_getannotation($stream_id, $mailbox, $entry, $attr) {}
|
|||
*/
|
||||
function imap_mail(string $to, string $subject, string $message, ?string $additional_headers = null, ?string $cc = null, ?string $bcc = null, ?string $return_path = null): bool {}
|
||||
|
||||
/**
|
||||
* Alias of <b>imap_headerinfo</b>
|
||||
* @link https://php.net/manual/en/function.imap-header.php
|
||||
* @param resource $stream_id An IMAP stream returned by imap_open().
|
||||
* @param int $msg_no The message number
|
||||
* @param int $from_length [optional] Number of characters for the fetchfrom property. Must be greater than or equal to zero.
|
||||
* @param int $subject_length [optional] Number of characters for the fetchsubject property Must be greater than or equal to zero.
|
||||
* @param $default_host [optional]
|
||||
* @return object Returns the information in an object with following properties:
|
||||
* <dl>
|
||||
* <dt>toaddress</dt><dd>full to: line, up to 1024 characters</dd>
|
||||
* <dt>to</dt><dd>an array of objects from the To: line, with the following properties: personal, adl, mailbox, and host</dd>
|
||||
* <dt>fromaddress</dt><dd>full from: line, up to 1024 characters</dd>
|
||||
* <dt>from</dt><dd>an array of objects from the From: line, with the following properties: personal, adl, mailbox, and host</dd>
|
||||
* <dt>ccaddress</dt><dd>full cc: line, up to 1024 characters</dd>
|
||||
* <dt>cc</dt><dd>an array of objects from the Cc: line, with the following properties: personal, adl, mailbox, and host</dd>
|
||||
* <dt>bccaddress</dt><dd>full bcc: line, up to 1024 characters</dd>
|
||||
* <dt>bcc</dt><dd>an array of objects from the Bcc: line, with the following properties: personal, adl, mailbox, and host</dd>
|
||||
* <dt>reply_toaddress</dt><dd>full Reply-To: line, up to 1024 characters</dd>
|
||||
* <dt>reply_to</dt><dd>an array of objects from the Reply-To: line, with the following properties: personal, adl, mailbox, and host</dd>
|
||||
* <dt>senderaddress</dt><dd>full sender: line, up to 1024 characters</dd>
|
||||
* <dt>sender</dt><dd>an array of objects from the Sender: line, with the following properties: personal, adl, mailbox, and host</dd>
|
||||
* <dt>return_pathaddress</dt><dd>full Return-Path: line, up to 1024 characters</dd>
|
||||
* <dt>return_path</dt><dd>an array of objects from the Return-Path: line, with the following properties: personal, adl, mailbox, and host</dd>
|
||||
* <dt>remail -</dt>
|
||||
* <dt>date</dt><dd>The message date as found in its headers</dd>
|
||||
* <dt>Date</dt><dd>Same as date</dd>
|
||||
* <dt>subject</dt><dd>The message subject</dd>
|
||||
* <dt>Subject</dt><dd>Same a subject</dd>
|
||||
* <dt>in_reply_to -</dt>
|
||||
* <dt>message_id -</dt>
|
||||
* <dt>newsgroups -</dt>
|
||||
* <dt>followup_to -</dt>
|
||||
* <dt>references -</dt>
|
||||
* <dt>Recent</dt><dd>R if recent and seen, N if recent and not seen, ' ' if not recent.</dd>
|
||||
* <dt>Unseen</dt><dd>U if not seen AND not recent, ' ' if seen OR not seen and recent</dd>
|
||||
* <dt>Flagged</dt><dd>F if flagged, ' ' if not flagged</dd>
|
||||
* <dt>Answered</dt><dd>A if answered, ' ' if unanswered</dd>
|
||||
* <dt>Deleted</dt><dd>D if deleted, ' ' if not deleted</dd>
|
||||
* <dt>Draft</dt><dd>X if draft, ' ' if not draft</dd>
|
||||
* <dt>Msgno</dt><dd>The message number</dd>
|
||||
* <dt>MailDate -</dt>
|
||||
* <dt>Size</dt><dd>The message size</dd>
|
||||
* <dt>udate</dt><dd>mail message date in Unix time</dd>
|
||||
* <dt>fetchfrom</dt><dd>from line formatted to fit fromlength characters</dd>
|
||||
* <dt>fetchsubject</dt><dd>subject line formatted to fit subjectlength characters</dd>
|
||||
* </dl>
|
||||
*/
|
||||
function imap_header($stream_id, $msg_no, $from_length = 0, $subject_length = 0, $default_host = null) {}
|
||||
|
||||
/**
|
||||
* Alias of <b>imap_list</b>
|
||||
* @link https://php.net/manual/en/function.imap-listmailbox.php
|
||||
|
|
|
@ -686,7 +686,7 @@ class IntlChar
|
|||
*/
|
||||
#[Pure]
|
||||
#[TentativeType]
|
||||
public static function hasBinaryProperty($codepoint, $property): ?bool {}
|
||||
public static function hasBinaryProperty(int|string $codepoint, int $property): ?bool {}
|
||||
|
||||
/**
|
||||
* @link https://php.net/manual/en/intlchar.charage.php
|
||||
|
@ -697,7 +697,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function charAge($codepoint): ?array {}
|
||||
public static function charAge(int|string $codepoint): ?array {}
|
||||
|
||||
/**
|
||||
* @link https://php.net/manual/en/intlchar.chardigitvalue.php
|
||||
|
@ -708,7 +708,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function charDigitValue($codepoint): ?int {}
|
||||
public static function charDigitValue(int|string $codepoint): ?int {}
|
||||
|
||||
/**
|
||||
* Get bidirectional category value for a code point
|
||||
|
@ -746,7 +746,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function charDirection($codepoint): ?int {}
|
||||
public static function charDirection(int|string $codepoint): ?int {}
|
||||
|
||||
/**
|
||||
* @link https://php.net/manual/en/intlchar.charfromname.php
|
||||
|
@ -765,7 +765,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function charFromName($name, $type = IntlChar::UNICODE_CHAR_NAME): ?int {}
|
||||
public static function charFromName(string $name, int $type = IntlChar::UNICODE_CHAR_NAME): ?int {}
|
||||
|
||||
/**
|
||||
* @link https://php.net/manual/en/intlchar.charmirror.php
|
||||
|
@ -776,7 +776,7 @@ class IntlChar
|
|||
* Or NULL if <em>codepoint</em> will be out of bound.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function charMirror($codepoint): string|int|null {}
|
||||
public static function charMirror(int|string $codepoint): string|int|null {}
|
||||
|
||||
/**
|
||||
* Retrieve the name of a Unicode character
|
||||
|
@ -794,7 +794,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function charName($codepoint, $type = IntlChar::UNICODE_CHAR_NAME): ?string {}
|
||||
public static function charName(int|string $codepoint, int $type = IntlChar::UNICODE_CHAR_NAME): ?string {}
|
||||
|
||||
/**
|
||||
* Get the general category value for a code point
|
||||
|
@ -838,7 +838,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function charType($codepoint): ?int {}
|
||||
public static function charType(int|string $codepoint): ?int {}
|
||||
|
||||
/**
|
||||
* Return Unicode character by code point value
|
||||
|
@ -849,7 +849,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function chr($codepoint): ?string {}
|
||||
public static function chr(int|string $codepoint): ?string {}
|
||||
|
||||
/**
|
||||
* Get the decimal digit value of a code point for a given radix
|
||||
|
@ -862,7 +862,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function digit($codepoint, $base = 10): int|false|null {}
|
||||
public static function digit(int|string $codepoint, int $base = 10): int|false|null {}
|
||||
|
||||
/**
|
||||
* Enumerate all assigned Unicode characters within a range
|
||||
|
@ -888,7 +888,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function enumCharNames($start, $end, $callback, $type = IntlChar::UNICODE_CHAR_NAME): ?bool {}
|
||||
public static function enumCharNames(int|string $start, int|string $end, callable $callback, int $type = IntlChar::UNICODE_CHAR_NAME): ?bool {}
|
||||
|
||||
/**
|
||||
* Enumerate all code points with their Unicode general categories
|
||||
|
@ -904,7 +904,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function enumCharTypes($callback = null): void {}
|
||||
public static function enumCharTypes(callable $callback): void {}
|
||||
|
||||
/**
|
||||
* Perform case folding on a code point
|
||||
|
@ -916,7 +916,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function foldCase($codepoint, $options = IntlChar::FOLD_CASE_DEFAULT): string|int|null {}
|
||||
public static function foldCase(int|string $codepoint, int $options = IntlChar::FOLD_CASE_DEFAULT): string|int|null {}
|
||||
|
||||
/**
|
||||
* Get character representation for a given digit and radix
|
||||
|
@ -927,7 +927,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function forDigit($digit, $base = 10): int {}
|
||||
public static function forDigit(int $digit, int $base = 10): int {}
|
||||
|
||||
/**
|
||||
* Get the paired bracket character for a code point
|
||||
|
@ -939,7 +939,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getBidiPairedBracket($codepoint): string|int|null {}
|
||||
public static function getBidiPairedBracket(int|string $codepoint): string|int|null {}
|
||||
|
||||
/**
|
||||
* Get the Unicode allocation block containing a code point
|
||||
|
@ -950,7 +950,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getBlockCode($codepoint): ?int {}
|
||||
public static function getBlockCode(int|string $codepoint): ?int {}
|
||||
|
||||
/**
|
||||
* Get the combining class of a code point
|
||||
|
@ -961,7 +961,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getCombiningClass($codepoint): ?int {}
|
||||
public static function getCombiningClass(int|string $codepoint): ?int {}
|
||||
|
||||
/**
|
||||
* Get the FC_NFKC_Closure property for a code point
|
||||
|
@ -973,7 +973,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getFC_NFKC_Closure($codepoint): string|false|null {}
|
||||
public static function getFC_NFKC_Closure(int|string $codepoint): string|false|null {}
|
||||
|
||||
/**
|
||||
* Get the max value for a Unicode property
|
||||
|
@ -983,7 +983,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getIntPropertyMaxValue($property): int {}
|
||||
public static function getIntPropertyMaxValue(int $property): int {}
|
||||
|
||||
/**
|
||||
* Get the min value for a Unicode property
|
||||
|
@ -993,7 +993,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getIntPropertyMinValue($property): int {}
|
||||
public static function getIntPropertyMinValue(int $property): int {}
|
||||
|
||||
/**
|
||||
* Get the value for a Unicode property for a code point
|
||||
|
@ -1020,7 +1020,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getIntPropertyValue($codepoint, $property): ?int {}
|
||||
public static function getIntPropertyValue(int|string $codepoint, int $property): ?int {}
|
||||
|
||||
/**
|
||||
* Get the numeric value for a Unicode code point
|
||||
|
@ -1030,7 +1030,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getNumericValue($codepoint): ?float {}
|
||||
public static function getNumericValue(int|string $codepoint): ?float {}
|
||||
|
||||
/**
|
||||
* Get the property constant value for a given property name
|
||||
|
@ -1040,7 +1040,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getPropertyEnum($alias): int {}
|
||||
public static function getPropertyEnum(string $alias): int {}
|
||||
|
||||
/**
|
||||
* Get the Unicode name for a property
|
||||
|
@ -1062,7 +1062,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getPropertyName($property, $type = IntlChar::LONG_PROPERTY_NAME): string|false {}
|
||||
public static function getPropertyName(int $property, int $type = IntlChar::LONG_PROPERTY_NAME): string|false {}
|
||||
|
||||
/**
|
||||
* Get the property value for a given value name
|
||||
|
@ -1074,7 +1074,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getPropertyValueEnum($property, $name): int {}
|
||||
public static function getPropertyValueEnum(int $property, string $name): int {}
|
||||
|
||||
/**
|
||||
* Get the Unicode name for a property value
|
||||
|
@ -1105,7 +1105,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function getPropertyValueName($property, $value, $type = IntlChar::LONG_PROPERTY_NAME): string|false {}
|
||||
public static function getPropertyValueName(int $property, int $value, int $type = IntlChar::LONG_PROPERTY_NAME): string|false {}
|
||||
|
||||
/**
|
||||
* Get the Unicode version
|
||||
|
@ -1124,7 +1124,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isalnum($codepoint): ?bool {}
|
||||
public static function isalnum(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a letter character
|
||||
|
@ -1134,7 +1134,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isalpha($codepoint): ?bool {}
|
||||
public static function isalpha(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a base character
|
||||
|
@ -1144,7 +1144,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isbase($codepoint): ?bool {}
|
||||
public static function isbase(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a "blank" or "horizontal space" character
|
||||
|
@ -1154,7 +1154,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isblank($codepoint): ?bool {}
|
||||
public static function isblank(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a control character
|
||||
|
@ -1164,7 +1164,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function iscntrl($codepoint): ?bool {}
|
||||
public static function iscntrl(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check whether the code point is defined
|
||||
|
@ -1174,7 +1174,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isdefined($codepoint): ?bool {}
|
||||
public static function isdefined(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a digit character
|
||||
|
@ -1184,7 +1184,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isdigit($codepoint): ?bool {}
|
||||
public static function isdigit(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a graphic character
|
||||
|
@ -1194,7 +1194,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isgraph($codepoint): ?bool {}
|
||||
public static function isgraph(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is an ignorable character
|
||||
|
@ -1204,7 +1204,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isIDIgnorable($codepoint): ?bool {}
|
||||
public static function isIDIgnorable(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is permissible in an identifier
|
||||
|
@ -1214,7 +1214,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isIDPart($codepoint): ?bool {}
|
||||
public static function isIDPart(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is permissible as the first character in an identifier
|
||||
|
@ -1224,7 +1224,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isIDStart($codepoint): ?bool {}
|
||||
public static function isIDStart(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is an ISO control code
|
||||
|
@ -1234,7 +1234,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isISOControl($codepoint): ?bool {}
|
||||
public static function isISOControl(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is permissible in a Java identifier
|
||||
|
@ -1244,7 +1244,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isJavaIDPart($codepoint): ?bool {}
|
||||
public static function isJavaIDPart(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is permissible as the first character in a Java identifier
|
||||
|
@ -1254,7 +1254,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isJavaIDStart($codepoint): ?bool {}
|
||||
public static function isJavaIDStart(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a space character according to Java
|
||||
|
@ -1264,7 +1264,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isJavaSpaceChar($codepoint): ?bool {}
|
||||
public static function isJavaSpaceChar(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a lowercase letter
|
||||
|
@ -1275,7 +1275,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function islower($codepoint): ?bool {}
|
||||
public static function islower(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point has the Bidi_Mirrored property
|
||||
|
@ -1285,7 +1285,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isMirrored($codepoint): ?bool {}
|
||||
public static function isMirrored(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a printable character
|
||||
|
@ -1295,7 +1295,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isprint($codepoint): ?bool {}
|
||||
public static function isprint(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is punctuation character
|
||||
|
@ -1306,7 +1306,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function ispunct($codepoint): ?bool {}
|
||||
public static function ispunct(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a space character
|
||||
|
@ -1316,7 +1316,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isspace($codepoint): ?bool {}
|
||||
public static function isspace(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a titlecase letter
|
||||
|
@ -1326,7 +1326,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function istitle($codepoint): ?bool {}
|
||||
public static function istitle(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point has the Alphabetic Unicode property
|
||||
|
@ -1336,7 +1336,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isUAlphabetic($codepoint): ?bool {}
|
||||
public static function isUAlphabetic(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point has the Lowercase Unicode property
|
||||
|
@ -1346,7 +1346,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isULowercase($codepoint): ?bool {}
|
||||
public static function isULowercase(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point has the general category "Lu" (uppercase letter)
|
||||
|
@ -1357,7 +1357,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isupper($codepoint): ?bool {}
|
||||
public static function isupper(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point has the Uppercase Unicode property
|
||||
|
@ -1367,7 +1367,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isUUppercase($codepoint): ?bool {}
|
||||
public static function isUUppercase(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point has the White_Space Unicode property
|
||||
|
@ -1377,7 +1377,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isUWhiteSpace($codepoint): ?bool {}
|
||||
public static function isUWhiteSpace(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a whitespace character according to ICU
|
||||
|
@ -1387,7 +1387,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isWhitespace($codepoint): ?bool {}
|
||||
public static function isWhitespace(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Check if code point is a hexadecimal digit
|
||||
|
@ -1396,7 +1396,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function isxdigit($codepoint): ?bool {}
|
||||
public static function isxdigit(int|string $codepoint): ?bool {}
|
||||
|
||||
/**
|
||||
* Return Unicode code point value of character
|
||||
|
@ -1406,7 +1406,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function ord($character): ?int {}
|
||||
public static function ord(int|string $character): ?int {}
|
||||
|
||||
/**
|
||||
* Make Unicode character lowercase
|
||||
|
@ -1418,7 +1418,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function tolower($codepoint): string|int|null {}
|
||||
public static function tolower(int|string $codepoint): string|int|null {}
|
||||
|
||||
/**
|
||||
* Make Unicode character titlecase
|
||||
|
@ -1430,7 +1430,7 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function totitle($codepoint): string|int|null {}
|
||||
public static function totitle(int|string $codepoint): string|int|null {}
|
||||
|
||||
/**
|
||||
* Make Unicode character uppercase
|
||||
|
@ -1442,5 +1442,5 @@ class IntlChar
|
|||
* @since 7.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function toupper($codepoint): string|int|null {}
|
||||
public static function toupper(int|string $codepoint): string|int|null {}
|
||||
}
|
||||
|
|
348
intl/intl.php
348
intl/intl.php
File diff suppressed because it is too large
Load Diff
|
@ -434,7 +434,7 @@ function ldap_exop_whoami($ldap): string|false {}
|
|||
* @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 = null, &$response_data, &$response_oid) {}
|
||||
function ldap_exop($ldap, string $request_oid, ?string $request_data, null|array $controls = null, &$response_data, &$response_oid) {}
|
||||
|
||||
/**
|
||||
* Parse LDAP extended operation data from result object result
|
||||
|
@ -446,7 +446,7 @@ function ldap_exop($ldap, string $request_oid, ?string $request_data, array $con
|
|||
* @return bool Returns TRUE on success or FALSE on failure.
|
||||
* @since 7.2
|
||||
*/
|
||||
function ldap_parse_exop($ldap, $result, &$response_data, &$response_oid): bool {}
|
||||
function ldap_parse_exop($ldap, $result, &$response_data = null, &$response_oid = null): bool {}
|
||||
|
||||
/**
|
||||
* Translate 8859 characters to t61 characters
|
||||
|
@ -522,7 +522,7 @@ function ldap_bind($ldap, ?string $dn, ?string $password): bool {}
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_bind_ext($ldap, ?string $dn, ?string $password, array $controls = null) {}
|
||||
function ldap_bind_ext($ldap, ?string $dn, ?string $password, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* Bind to LDAP directory using SASL
|
||||
|
@ -611,7 +611,7 @@ function ldap_unbind($ldap): bool {}
|
|||
* @param array|null $controls 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 = 0, int $sizelimit = -1, int $timelimit = -1, int $deref = 0, array $controls = null) {}
|
||||
function ldap_read($ldap, array|string $base, array|string $filter, array $attributes = [], int $attributes_only = 0, int $sizelimit = -1, int $timelimit = -1, int $deref = 0, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* Single-level search
|
||||
|
@ -669,7 +669,7 @@ function ldap_read($ldap, array|string $base, array|string $filter, array $attri
|
|||
* @param array|null $controls 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 = 0, int $sizelimit = -1, int $timelimit = -1, int $deref = 0, array $controls = null) {}
|
||||
function ldap_list($ldap, array|string $base, array|string $filter, array $attributes = [], int $attributes_only = 0, int $sizelimit = -1, int $timelimit = -1, int $deref = 0, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* Search LDAP tree
|
||||
|
@ -731,7 +731,7 @@ function ldap_list($ldap, array|string $base, array|string $filter, array $attri
|
|||
* @param array|null $controls 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 = 0, int $sizelimit = -1, int $timelimit = -1, int $deref = 0, array $controls = null) {}
|
||||
function ldap_search($ldap, array|string $base, array|string $filter, array $attributes = [], int $attributes_only = 0, int $sizelimit = -1, int $timelimit = -1, int $deref = 0, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* Free result memory
|
||||
|
@ -752,7 +752,7 @@ function ldap_free_result($ldap): bool {}
|
|||
* </p>
|
||||
* @return int|false number of entries in the result or <b>FALSE</b> on error.
|
||||
*/
|
||||
function ldap_count_entries($ldap, $result): int|false {}
|
||||
function ldap_count_entries($ldap, $result): int {}
|
||||
|
||||
/**
|
||||
* Return first result id
|
||||
|
@ -945,7 +945,7 @@ function ldap_dn2ufn(string $dn): string|false {}
|
|||
* @param array|null $controls 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 = null): bool {}
|
||||
function ldap_add($ldap, string $dn, array $entry, null|array $controls = null): bool {}
|
||||
|
||||
/**
|
||||
* Add entries to LDAP directory
|
||||
|
@ -972,7 +972,7 @@ function ldap_add($ldap, string $dn, array $entry, array $controls = null): bool
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_add_ext($ldap, string $dn, array $entry, array $controls = null) {}
|
||||
function ldap_add_ext($ldap, string $dn, array $entry, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* Delete an entry from a directory
|
||||
|
@ -986,7 +986,7 @@ function ldap_add_ext($ldap, string $dn, array $entry, array $controls = null) {
|
|||
* @param array|null $controls 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 = null): bool {}
|
||||
function ldap_delete($ldap, string $dn, null|array $controls = null): bool {}
|
||||
|
||||
/**
|
||||
* Delete an entry from a directory
|
||||
|
@ -1002,7 +1002,7 @@ function ldap_delete($ldap, string $dn, array $controls = null): bool {}
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_delete_ext($ldap, string $dn, array $controls = null) {}
|
||||
function ldap_delete_ext($ldap, string $dn, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* This function is an alias of: ldap_mod_replace().
|
||||
|
@ -1018,7 +1018,7 @@ function ldap_delete_ext($ldap, string $dn, array $controls = null) {}
|
|||
* @param array|null $controls Array of LDAP Controls to send with the request.
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function ldap_modify($ldap, string $dn, array $entry, array $controls = null): bool {}
|
||||
function ldap_modify($ldap, string $dn, array $entry, null|array $controls = null): bool {}
|
||||
|
||||
/**
|
||||
* Add attribute values to current attributes
|
||||
|
@ -1033,7 +1033,7 @@ function ldap_modify($ldap, string $dn, array $entry, array $controls = null): b
|
|||
* @param array|null $controls 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 = null): bool {}
|
||||
function ldap_mod_add($ldap, string $dn, array $entry, null|array $controls = null): bool {}
|
||||
|
||||
/**
|
||||
* Add attribute values to current attributes
|
||||
|
@ -1050,7 +1050,7 @@ function ldap_mod_add($ldap, string $dn, array $entry, array $controls = null):
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_mod_add_ext($ldap, string $dn, array $entry, array $controls = null) {}
|
||||
function ldap_mod_add_ext($ldap, string $dn, array $entry, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* Replace attribute values with new ones
|
||||
|
@ -1065,7 +1065,7 @@ function ldap_mod_add_ext($ldap, string $dn, array $entry, array $controls = nul
|
|||
* @param array|null $controls 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 = null): bool {}
|
||||
function ldap_mod_replace($ldap, string $dn, array $entry, null|array $controls = null): bool {}
|
||||
|
||||
/**
|
||||
* Replace attribute values with new ones
|
||||
|
@ -1082,7 +1082,7 @@ function ldap_mod_replace($ldap, string $dn, array $entry, array $controls = nul
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_mod_replace_ext($ldap, string $dn, array $entry, array $controls = null) {}
|
||||
function ldap_mod_replace_ext($ldap, string $dn, array $entry, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* Delete attribute values from current attributes
|
||||
|
@ -1097,7 +1097,7 @@ function ldap_mod_replace_ext($ldap, string $dn, array $entry, array $controls =
|
|||
* @param array|null $controls 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 = null): bool {}
|
||||
function ldap_mod_del($ldap, string $dn, array $entry, null|array $controls = null): bool {}
|
||||
|
||||
/**
|
||||
* Delete attribute values from current attributes
|
||||
|
@ -1114,7 +1114,7 @@ function ldap_mod_del($ldap, string $dn, array $entry, array $controls = null):
|
|||
* @return resource|false
|
||||
* @since 7.3
|
||||
*/
|
||||
function ldap_mod_del_ext($ldap, string $dn, array $entry, array $controls = null) {}
|
||||
function ldap_mod_del_ext($ldap, string $dn, array $entry, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* Return the LDAP error number of the last LDAP command
|
||||
|
@ -1166,7 +1166,7 @@ function ldap_error($ldap): string {}
|
|||
* @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 = null): int|bool {}
|
||||
function ldap_compare($ldap, string $dn, string $attribute, string $value, null|array $controls = null): int|bool {}
|
||||
|
||||
/**
|
||||
* Sort LDAP result entries
|
||||
|
@ -1209,7 +1209,7 @@ function ldap_sort($ldap, $result, string $sortfilter): bool {}
|
|||
* @param array|null $controls 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 = null): bool {}
|
||||
function ldap_rename($ldap, string $dn, string $new_rdn, string $new_parent, bool $delete_old_rdn, null|array $controls = null): bool {}
|
||||
|
||||
/**
|
||||
* Modify the name of an entry
|
||||
|
@ -1235,7 +1235,7 @@ function ldap_rename($ldap, string $dn, string $new_rdn, string $new_parent, boo
|
|||
* @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 = null) {}
|
||||
function ldap_rename_ext($ldap, string $dn, string $new_rdn, string $new_parent, bool $delete_old_rdn, null|array $controls = null) {}
|
||||
|
||||
/**
|
||||
* Get the current value for given option
|
||||
|
@ -1307,7 +1307,7 @@ 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): bool {}
|
||||
function ldap_get_option($ldap, int $option, &$value = null): bool {}
|
||||
|
||||
/**
|
||||
* Set the value of the given option
|
||||
|
@ -1597,4 +1597,12 @@ function ldap_escape(string $value, string $ignore = '', int $flags = 0): string
|
|||
* @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 = null): bool {}
|
||||
function ldap_modify_batch($ldap, string $dn, array $modifications_info, null|array $controls = null): bool {}
|
||||
|
||||
/**
|
||||
* @param resource $ldap
|
||||
* @param resource $result
|
||||
* @return int returns the number of reference messages in a search result.
|
||||
* @since 8.0
|
||||
*/
|
||||
function ldap_count_references($ldap, $result): int {}
|
||||
|
|
|
@ -214,7 +214,7 @@ function libxml_set_streams_context($context): void {}
|
|||
* @return bool This function returns the previous value of
|
||||
* <i>use_errors</i>.
|
||||
*/
|
||||
function libxml_use_internal_errors(bool $use_errors = false): bool {}
|
||||
function libxml_use_internal_errors(?bool $use_errors = null): bool {}
|
||||
|
||||
/**
|
||||
* Retrieve last error from libxml
|
||||
|
|
|
@ -242,7 +242,7 @@ function mb_substitute_character(string|int|null $substitute_character = null):
|
|||
* @param string $string <p>
|
||||
* The URL encoded data.
|
||||
* </p>
|
||||
* @param array &$result [optional] <p>
|
||||
* @param array &$result <p>
|
||||
* An array containing decoded and character encoded converted values.
|
||||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
|
@ -288,7 +288,7 @@ function mb_preferred_mime_name(string $encoding): string|false {}
|
|||
* counted as 1.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_strlen(string $string, string $encoding): int|false {}
|
||||
function mb_strlen(string $string, string|null $encoding): int {}
|
||||
|
||||
/**
|
||||
* Find position of first occurrence of string in a string
|
||||
|
@ -652,11 +652,11 @@ function mb_list_encodings(): array {}
|
|||
/**
|
||||
* Get aliases of a known encoding type
|
||||
* @param string $encoding The encoding type being checked, for aliases.
|
||||
* @return string[]|false a numerically indexed array of encoding aliases on success, or FALSE on failure
|
||||
* @return string[] a numerically indexed array of encoding aliases on success
|
||||
* @link https://php.net/manual/en/function.mb-encoding-aliases.php
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_encoding_aliases(string $encoding): array|false {}
|
||||
function mb_encoding_aliases(string $encoding): array {}
|
||||
|
||||
/**
|
||||
* Convert "kana" one from another ("zen-kaku", "han-kaku" and more)
|
||||
|
@ -843,7 +843,7 @@ function mb_decode_mimeheader(string $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 &...$vars): string|false {}
|
||||
function mb_convert_variables(string $to_encoding, array|string $from_encoding, mixed &$var, mixed &...$vars): string|false {}
|
||||
|
||||
/**
|
||||
* Encode character to HTML numeric string reference
|
||||
|
@ -873,13 +873,10 @@ function mb_encode_numericentity(string $string, array $map, ?string $encoding =
|
|||
* the code area to convert.
|
||||
* </p>
|
||||
* @param null|string $encoding
|
||||
* @param bool $is_hex [optional] <p>
|
||||
* this parameter is not used.
|
||||
* </p>
|
||||
* @return string|false|null The converted string.
|
||||
* @return string The converted string.
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_decode_numericentity(string $string, array $map, ?string $encoding = null, $is_hex = false): string|false|null {}
|
||||
function mb_decode_numericentity(string $string, array $map, ?string $encoding = null): string {}
|
||||
|
||||
/**
|
||||
* Send encoded mail
|
||||
|
@ -999,9 +996,9 @@ function mb_ereg(string $pattern, string $string, &$matches): bool {}
|
|||
* @param string[] &$matches [optional] <p>
|
||||
* Contains a substring of the matched string.
|
||||
* </p>
|
||||
* @return bool|int
|
||||
* @return bool
|
||||
*/
|
||||
function mb_eregi(string $pattern, string $string, &$matches): false|int {}
|
||||
function mb_eregi(string $pattern, string $string, &$matches): bool {}
|
||||
|
||||
/**
|
||||
* Replace regular expression with multibyte support
|
||||
|
@ -1379,11 +1376,11 @@ function mb_ord(string $string, ?string $encoding): int|false {}
|
|||
* @link https://www.php.net/manual/en/function.mb-scrub.php
|
||||
* @param string $string
|
||||
* @param string|null $encoding [optional]
|
||||
* @return string|false
|
||||
* @return string
|
||||
* @since 7.2
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_scrub(string $string, ?string $encoding): string|false {}
|
||||
function mb_scrub(string $string, ?string $encoding): string {}
|
||||
|
||||
/**
|
||||
* @param $position
|
||||
|
@ -1405,8 +1402,8 @@ function mbereg_search_setpos($position) {}
|
|||
* Character encoding name to use.
|
||||
* If it is omitted, internal character encoding is used.
|
||||
* </p>
|
||||
* @return string[]|false
|
||||
* @return string[]
|
||||
* @since 7.4
|
||||
*/
|
||||
#[Pure]
|
||||
function mb_str_split(string $string, int $length = 1, ?string $encoding): array|false {}
|
||||
function mb_str_split(string $string, int $length = 1, ?string $encoding): array {}
|
||||
|
|
|
@ -1038,7 +1038,7 @@ function mysqli_get_charset(mysqli $mysql): ?object {}
|
|||
* @param mysqli|null $mysql A link identifier returned by mysqli_connect() or mysqli_init()
|
||||
* @return string|null A string that represents the MySQL client library version
|
||||
*/
|
||||
function mysqli_get_client_info(): ?string {}
|
||||
function mysqli_get_client_info(?mysqli $mysql = null): string {}
|
||||
|
||||
/**
|
||||
* Returns the MySQL client version as an integer
|
||||
|
@ -1196,7 +1196,7 @@ function mysqli_more_results(mysqli $mysql): bool {}
|
|||
* @param string $query A string containing the queries to be executed. Multiple queries must be separated by a semicolon.
|
||||
* @return bool Returns FALSE if the first statement failed. To retrieve subsequent errors from other statements you have to call mysqli_next_result() first.
|
||||
*/
|
||||
function mysqli_multi_query(mysqli $mysql, string $query = null): bool {}
|
||||
function mysqli_multi_query(mysqli $mysql, string $query): bool {}
|
||||
|
||||
/**
|
||||
* Prepare next result from multi_query
|
||||
|
@ -1348,7 +1348,7 @@ function mysqli_real_escape_string(mysqli $mysql, string $string): string {}
|
|||
* @param string $query
|
||||
* @return bool
|
||||
*/
|
||||
function mysqli_real_query(mysqli $mysql, string $query = null): bool {}
|
||||
function mysqli_real_query(mysqli $mysql, string $query): bool {}
|
||||
|
||||
/**
|
||||
* Get result from async query
|
||||
|
@ -1421,9 +1421,9 @@ function mysqli_stmt_affected_rows(mysqli_stmt $statement): string|int {}
|
|||
* @link https://php.net/manual/en/mysqli-stmt.attr-get.php
|
||||
* @param mysqli_stmt $statement
|
||||
* @param int $attribute
|
||||
* @return int|false Returns FALSE if the attribute is not found, otherwise returns the value of the attribute.
|
||||
* @return int returns the value of the attribute.
|
||||
*/
|
||||
function mysqli_stmt_attr_get(mysqli_stmt $statement, int $attribute): int|false {}
|
||||
function mysqli_stmt_attr_get(mysqli_stmt $statement, int $attribute): int {}
|
||||
|
||||
/**
|
||||
* Used to modify the behavior of a prepared statement
|
||||
|
@ -1612,7 +1612,7 @@ function mysqli_stat(mysqli $mysql): string|false {}
|
|||
* @param string|null $cipher_algos A list of allowable ciphers to use for SSL encryption
|
||||
* @return bool This function always returns TRUE value.
|
||||
*/
|
||||
function mysqli_ssl_set(mysqli $mysql, string $key, string $certificate, string $ca_certificate, string $ca_path, string $cipher_algos): bool {}
|
||||
function mysqli_ssl_set(mysqli $mysql, string|null $key, string|null $certificate, string|null $ca_certificate, string|null $ca_path, string|null $cipher_algos): bool {}
|
||||
|
||||
/**
|
||||
* Closes a prepared statement
|
||||
|
@ -1774,7 +1774,7 @@ function mysqli_client_encoding(mysqli $mysql): string {}
|
|||
* @param string $string The string to be escaped
|
||||
* @return string
|
||||
*/
|
||||
function mysqli_escape_string(mysqli $mysql, string $string, $resultmode = null): string {}
|
||||
function mysqli_escape_string(mysqli $mysql, string $string): string {}
|
||||
|
||||
/**
|
||||
* Alias for <b>mysqli_stmt_fetch</b>
|
||||
|
@ -1826,7 +1826,7 @@ function mysqli_send_long_data(mysqli_stmt $statement, int $param_num, string $d
|
|||
* @param string|int $value
|
||||
* @return bool
|
||||
*/
|
||||
function mysqli_set_opt(): bool {}
|
||||
function mysqli_set_opt(mysqli $mysql, int $option, $value): bool {}
|
||||
|
||||
/**
|
||||
* mysqli_sql_exception
|
||||
|
@ -2035,7 +2035,7 @@ class mysqli
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function begin_transaction($flags = 0, $name = null): bool {}
|
||||
public function begin_transaction(int $flags = 0, string|null $name = null): bool {}
|
||||
|
||||
/**
|
||||
* Changes the user of the specified database connection
|
||||
|
@ -2515,7 +2515,7 @@ class mysqli
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function release_savepoint($name): bool {}
|
||||
public function release_savepoint(string $name): bool {}
|
||||
|
||||
/**
|
||||
* Rolls back current transaction
|
||||
|
@ -2526,7 +2526,7 @@ class mysqli
|
|||
* @since 5.5 Added flags and name parameters.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function rollback($flags = 0, $name = null): bool {}
|
||||
public function rollback(int $flags = 0, string|null $name = null): bool {}
|
||||
|
||||
/**
|
||||
* Set a named transaction savepoint
|
||||
|
@ -2536,7 +2536,7 @@ class mysqli
|
|||
* @since 5.5
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function savepoint($name): bool {}
|
||||
public function savepoint(string $name): bool {}
|
||||
|
||||
/**
|
||||
* Selects the default database for database queries
|
||||
|
@ -2652,7 +2652,7 @@ class mysqli
|
|||
* @since 5.3
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function refresh($flags): bool {}
|
||||
public function refresh(int $flags): bool {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -2680,7 +2680,7 @@ final class mysqli_warning
|
|||
* The __construct purpose
|
||||
* @link https://php.net/manual/en/mysqli-warning.construct.php
|
||||
*/
|
||||
protected function __construct() {}
|
||||
private function __construct() {}
|
||||
|
||||
/**
|
||||
* Move to the next warning
|
||||
|
@ -2727,7 +2727,7 @@ class mysqli_result implements IteratorAggregate
|
|||
* @param object $mysql
|
||||
* @param int $result_mode [optional]
|
||||
*/
|
||||
public function __construct() {}
|
||||
public function __construct(mysqli $mysql, int $result_mode = MYSQLI_STORE_RESULT) {}
|
||||
|
||||
/**
|
||||
* Frees the memory associated with a result
|
||||
|
@ -3051,6 +3051,12 @@ class mysqli_result implements IteratorAggregate
|
|||
*/
|
||||
#[TentativeType]
|
||||
public function free_result(): void {}
|
||||
|
||||
/**
|
||||
* @return Iterator
|
||||
* @since 8.0
|
||||
*/
|
||||
public function getIterator(): Iterator {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
491
oci8/oci8.php
491
oci8/oci8.php
|
@ -1586,24 +1586,24 @@ function oci_free_descriptor($descriptor) {}
|
|||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Compares two LOB/FILE locators for equality
|
||||
* @link https://php.net/manual/en/function.oci-lob-is-equal.php
|
||||
* @param OCI_Lob $lob1 <p>
|
||||
* @param OCILob $lob1 <p>
|
||||
* A LOB identifier.
|
||||
* </p>
|
||||
* @param OCI_Lob $lob2 <p>
|
||||
* @param OCILob $lob2 <p>
|
||||
* A LOB identifier.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> if these objects are equal, <b>FALSE</b> otherwise.
|
||||
*/
|
||||
function oci_lob_is_equal(OCI_Lob $lob1, OCI_Lob $lob2) {}
|
||||
function oci_lob_is_equal(OCILob $lob1, OCILob $lob2) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Copies large object
|
||||
* @link https://php.net/manual/en/function.oci-lob-copy.php
|
||||
* @param OCI_Lob $lob_to <p>
|
||||
* @param OCILob $lob_to <p>
|
||||
* The destination LOB.
|
||||
* </p>
|
||||
* @param OCI_Lob $lob_from <p>
|
||||
* @param OCILob $lob_from <p>
|
||||
* The copied LOB.
|
||||
* </p>
|
||||
* @param int $length [optional] <p>
|
||||
|
@ -1611,7 +1611,7 @@ function oci_lob_is_equal(OCI_Lob $lob1, OCI_Lob $lob2) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function oci_lob_copy(OCI_Lob $lob_to, OCI_Lob $lob_from, $length = 0) {}
|
||||
function oci_lob_copy(OCILob $lob_to, OCILob $lob_from, $length = 0) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
|
@ -1651,9 +1651,9 @@ function oci_rollback($connection) {}
|
|||
* <b>OCI_DTYPE_FILE</b>, <b>OCI_DTYPE_LOB</b> and
|
||||
* <b>OCI_DTYPE_ROWID</b>.
|
||||
* </p>
|
||||
* @return OCI_Lob|OCILob|false A new LOB or FILE descriptor on success, <b>FALSE</b> on error.
|
||||
* @return OCILob|false A new LOB or FILE descriptor on success, <b>FALSE</b> on error.
|
||||
*/
|
||||
function oci_new_descriptor($connection, $type = OCI_DTYPE_LOB): OCI_Lob|false {}
|
||||
function oci_new_descriptor($connection, $type = OCI_DTYPE_LOB): OCILob|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
|
@ -1774,10 +1774,10 @@ function oci_password_change($connection, $username, $old_password, $new_passwor
|
|||
* Should point to the scheme, where the named type was created. The name
|
||||
* of the current user is the default value.
|
||||
* </p>
|
||||
* @return OCI_Collection|false A new <b>OCICollection</b> object or <b>FALSE</b> on
|
||||
* @return OCICollection|false A new <b>OCICollection</b> object or <b>FALSE</b> on
|
||||
* error.
|
||||
*/
|
||||
function oci_new_collection($connection, $tdo, $schema = null): OCI_Collection|false {}
|
||||
function oci_new_collection($connection, $tdo, $schema = null): OCICollection|false {}
|
||||
|
||||
/**
|
||||
* Alias of {@see oci_free_statement()}
|
||||
|
@ -2122,50 +2122,50 @@ function ocifreedesc($lob_descriptor) {}
|
|||
* Alias of
|
||||
* {@see OCI-Lob::save}
|
||||
* @link https://php.net/manual/en/function.ocisavelob.php
|
||||
* @param OCI_Lob|OCILob $lob_descriptor
|
||||
* @param OCILob $lob_descriptor
|
||||
* @param string $data
|
||||
* @param int $offset [optional]
|
||||
* @return bool
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI-Lob::save", since: "5.4")]
|
||||
function ocisavelob(OCI_Lob $lob_descriptor, $data, $offset) {}
|
||||
function ocisavelob(OCILob $lob_descriptor, $data, $offset) {}
|
||||
|
||||
/**
|
||||
* (PHP 4, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of
|
||||
* {@see OCI_Lob::import}
|
||||
* {@see OCILob::import}
|
||||
* @link https://php.net/manual/en/function.ocisavelobfile.php
|
||||
* @param OCI_Lob|OCILob $lob_descriptor
|
||||
* @param OCILob $lob_descriptor
|
||||
* @param string $filename
|
||||
* @return bool
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_Lob::import", since: "5.4")]
|
||||
function ocisavelobfile(OCI_Lob $lob_descriptor, $filename) {}
|
||||
#[Deprecated(replacement: "OCILob::import", since: "5.4")]
|
||||
function ocisavelobfile(OCILob $lob_descriptor, $filename) {}
|
||||
|
||||
/**
|
||||
* (PHP 4, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of
|
||||
* {@see OCI_Lob::export}
|
||||
* {@see OCILob::export}
|
||||
* @link https://php.net/manual/en/function.ociwritelobtofile.php
|
||||
* @param OCI_Lob|OCILob $lob_descriptor
|
||||
* @param OCILob $lob_descriptor
|
||||
* @param string $filename <p>Path to the file.</p>
|
||||
* @param int $start [optional] <p>Indicates from where to start exporting.</p>
|
||||
* @param int $length [optional] <p>Indicates the length of data to be exported.</p>
|
||||
* @return bool Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_Lob::export", since: "5.4")]
|
||||
function ociwritelobtofile(OCI_Lob $lob_descriptor, $filename, $start, $length) {}
|
||||
#[Deprecated(replacement: "OCILob::export", since: "5.4")]
|
||||
function ociwritelobtofile(OCILob $lob_descriptor, $filename, $start, $length) {}
|
||||
|
||||
/**
|
||||
* (PHP 4, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of
|
||||
* {@see OCI_Lob::load}
|
||||
* {@see OCILob::load}
|
||||
* @link https://php.net/manual/en/function.ociloadlob.php
|
||||
* @param OCI_Lob|OCILob $lob_descriptor
|
||||
* @param OCILob $lob_descriptor
|
||||
* @return string|false <p>Returns the contents of the object, or <b>FALSE</b> on errors.</p>
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_Lob::load", since: "5.4")]
|
||||
function ociloadlob(OCI_Lob $lob_descriptor) {}
|
||||
#[Deprecated(replacement: "OCILob::load", since: "5.4")]
|
||||
function ociloadlob(OCILob $lob_descriptor) {}
|
||||
|
||||
/**
|
||||
* (PHP 4, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
|
@ -2204,10 +2204,10 @@ function ocirollback($connection_resource) {}
|
|||
* {@see oci_connect()} or {@see oci_pconnect()}.
|
||||
* </p>
|
||||
* @param $type [optional] <p>Valid values for type are: <b>OCI_DTYPE_FILE</b>, <b>OCI_DTYPE_LOB</b> and <b>OCI_DTYPE_ROWID</b>.</p>
|
||||
* @return OCI_LOB|false Returns a new LOB or FILE descriptor on success, FALSE on error.
|
||||
* @return OCILob|false Returns a new LOB or FILE descriptor on success, FALSE on error.
|
||||
*/
|
||||
#[Deprecated(replacement: "oci_new_descriptor", since: "5.4")]
|
||||
function ocinewdescriptor($connection_resource, $type = OCI_DTYPE_LOB): OCI_Lob|false {}
|
||||
function ocinewdescriptor($connection_resource, $type = OCI_DTYPE_LOB): OCILob|false {}
|
||||
|
||||
/**
|
||||
* (PHP 4, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
|
@ -2239,13 +2239,13 @@ function ocipasswordchange($connection_resource_or_connection_string_or_dbname,
|
|||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.7, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of {@see OCI_Collection::free}
|
||||
* Alias of {@see OCICollection::free}
|
||||
* @link https://php.net/manual/en/function.ocifreecollection.php
|
||||
* @param OCI_Collection|OCICollection $collection
|
||||
* @param OCICollection $collection
|
||||
* @return bool Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_Collection::free", since: "5.4")]
|
||||
function ocifreecollection(OCI_Collection $collection) {}
|
||||
#[Deprecated(replacement: "OCICollection::free", since: "5.4")]
|
||||
function ocifreecollection(OCICollection $collection) {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
|
@ -2259,88 +2259,88 @@ function ocifreecollection(OCI_Collection $collection) {}
|
|||
* @param $tdo <p>Should be a valid named type (uppercase).</p>
|
||||
* @param $schema <p>Should point to the scheme, where the named type was created. The name of the current user is the default value.</p>
|
||||
* </p>
|
||||
* @return OCI_Collection|false <p>Returns a new OCI_Collection object or FALSE on error.</p>
|
||||
* @return OCICollection|false <p>Returns a new OCICollection object or FALSE on error.</p>
|
||||
*/
|
||||
#[Deprecated(replacement: "oci_new_collection", since: "5.4")]
|
||||
function ocinewcollection($connection_resource, $tdo, $schema = null): OCI_Collection|false {}
|
||||
function ocinewcollection($connection_resource, $tdo, $schema = null): OCICollection|false {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of
|
||||
* (@param OCI_Collection $collection
|
||||
* (@param OCICollection $collection
|
||||
* @param mixed $value <p>The value to be added to the collection. Can be a string or a number.</p>
|
||||
* @return bool <p>Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.</p>
|
||||
* @link https://php.net/manual/en/function.ocicollappend.php
|
||||
* @see OCI_Collection::append)
|
||||
* @see OCICollection::append)
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_Collection::append", since: "5.4")]
|
||||
function ocicollappend(OCI_Collection $collection, $value) {}
|
||||
#[Deprecated(replacement: "OCICollection::append", since: "5.4")]
|
||||
function ocicollappend(OCICollection $collection, $value) {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of
|
||||
* {@see OCI_COLLection::getElem}
|
||||
* {@see OCICollection::getElem}
|
||||
* @link https://php.net/manual/en/function.ocicollgetelem.php
|
||||
* @param OCI_Collection $collection
|
||||
* @param OCICollection $collection
|
||||
* @param int $index <p>The element index. First index is 0.</p>
|
||||
* @return mixed <p>Returns <b>FALSE</b> if such element doesn't exist; <b>NULL</b> if element is <b>NULL</b>; string if element is column of a string datatype or number if element is numeric field.</p>
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_COLLection::getElem", since: "5.4")]
|
||||
function ocicollgetelem(OCI_Collection $collection, $index) {}
|
||||
#[Deprecated(replacement: "OCICollection::getElem", since: "5.4")]
|
||||
function ocicollgetelem(OCICollection $collection, $index) {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of {@see OCI_Collection::assignElem}
|
||||
* Alias of {@see OCICollection::assignElem}
|
||||
* @link https://php.net/manual/en/function.ocicollassignelem.php
|
||||
* @param OCI_Collection $collection
|
||||
* @param OCICollection $collection
|
||||
* @param $index <p>The element index. First index is 0.</p>
|
||||
* @param $value <p>Can be a string or a number.</p>
|
||||
* @return bool <p>Returns TRUE on success or FALSE on failure.</p>
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_Collection::assignElem", since: "5.4")]
|
||||
function ocicollassignelem(OCI_Collection $collection, $index, $value) {}
|
||||
#[Deprecated(replacement: "OCICollection::assignElem", since: "5.4")]
|
||||
function ocicollassignelem(OCICollection $collection, $index, $value) {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of
|
||||
* {@see OCI_COLLection::size}
|
||||
* {@see OCICollection::size}
|
||||
* @link https://php.net/manual/en/function.ocicollsize.php
|
||||
* @param OCI_Collection $collection
|
||||
* @param OCICollection $collection
|
||||
* @return int|false <p>Returns the number of elements in the collection or <b>FALSE</b> on error.</p>
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_COLLection::size", since: "5.4")]
|
||||
function ocicollsize(OCI_Collection $collection) {}
|
||||
#[Deprecated(replacement: "OCICollection::size", since: "5.4")]
|
||||
function ocicollsize(OCICollection $collection) {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of
|
||||
* {@see OCI_COLLection::max}
|
||||
* {@see OCICollection::max}
|
||||
* @link https://php.net/manual/en/function.ocicollmax.php
|
||||
* @param OCI_Collection $collection
|
||||
* @param OCICollection $collection
|
||||
* @return int|false <p> Returns the maximum number as an integer, or <b>FALSE</b> on errors.
|
||||
* If the returned value is 0, then the number of elements is not limited.</p>
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_COLLection::max", since: "5.4")]
|
||||
function ocicollmax(OCI_Collection $collection) {}
|
||||
#[Deprecated(replacement: "OCICollection::max", since: "5.4")]
|
||||
function ocicollmax(OCICollection $collection) {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PHP 5, PECL OCI8 >= 1.0.0)<br/>
|
||||
* Alias of
|
||||
* {@see OCI_Collection::trim}
|
||||
* {@see OCICollection::trim}
|
||||
* @link https://php.net/manual/en/function.ocicolltrim.php
|
||||
* @param OCI_Collection $collection
|
||||
* @param OCICollection $collection
|
||||
* @param int|float $number
|
||||
* @return bool Returns <b>TRUE</b> or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI_Collection::trim", since: "5.4")]
|
||||
function ocicolltrim(OCI_Collection $collection, $number) {}
|
||||
#[Deprecated(replacement: "OCICollection::trim", since: "5.4")]
|
||||
function ocicolltrim(OCICollection $collection, $number) {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PECL OCI8 1.0)
|
||||
* Writes a temporary large object
|
||||
* Alias of {@see OCI-Lob::writeTemporary()}
|
||||
* @link https://php.net/manual/en/function.ociwritetemporarylob.php
|
||||
* @param OCI_Lob|OCILob $lob_descriptor
|
||||
* @param OCILob $lob_descriptor
|
||||
* @param string $data <p>The data to write.</p>
|
||||
* @param int $lob_type <p>
|
||||
* Can be one of the following:
|
||||
|
@ -2356,391 +2356,26 @@ function ocicolltrim(OCI_Collection $collection, $number) {}
|
|||
* @return bool <p>Returns TRUE on success or FALSE on failure.</p>
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI-Lob::writeTemporary", since: "5.4")]
|
||||
function ociwritetemporarylob(OCI_Lob $lob_descriptor, $data, $lob_type = OCI_TEMP_CLOB) {}
|
||||
function ociwritetemporarylob(OCILob $lob_descriptor, $data, $lob_type = OCI_TEMP_CLOB) {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PECL OCI8 1.0)
|
||||
* Alias of {@see OCI-Lob::close()}
|
||||
* @link https://php.net/manual/en/function.ocicloselob.php
|
||||
* @param OCI_Lob|OCILob $lob_descriptor
|
||||
* @param OCILob $lob_descriptor
|
||||
* @return bool <p>Returns TRUE on success or FALSE on failure.</p>
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI-Lob::close()", since: "5.4")]
|
||||
function ocicloselob(OCI_Lob $lob_descriptor) {}
|
||||
function ocicloselob(OCILob $lob_descriptor) {}
|
||||
|
||||
/**
|
||||
* (PHP 4 >= 4.0.6, PECL OCI8 1.0)
|
||||
* Alias of {@see OCI-Collection::assign()}
|
||||
* Assigns a value to the collection from another existing collection
|
||||
* @link https://php.net/manual/en/function.ocicollassign.php
|
||||
* @param OCI_Collection $to
|
||||
* @param OCI_Collection $from An instance of OCI-Collection.
|
||||
* @param OCICollection $to
|
||||
* @param OCICollection $from An instance of OCI-Collection.
|
||||
* @return bool <p>Returns TRUE on success or FALSE on failure.</p>
|
||||
*/
|
||||
#[Deprecated(replacement: "OCI-Collection::assign", since: "5.4")]
|
||||
function ocicollassign(OCI_Collection $to, OCI_Collection $from) {}
|
||||
|
||||
/**
|
||||
* OCI8 LOB functionality for large binary (BLOB) and character (CLOB) objects.
|
||||
* @link https://php.net/manual/en/class.OCI-Lob.php
|
||||
* @removed 8.0
|
||||
*/
|
||||
class OCI_Lob
|
||||
{
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns large object's contents
|
||||
* @link https://php.net/manual/en/oci-lob.load.php
|
||||
* @return string|false The contents of the object, or <b>FALSE</b> on errors.
|
||||
*/
|
||||
public function load() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns the current position of internal pointer of large object
|
||||
* @link https://php.net/manual/en/oci-lob.tell.php
|
||||
* @return int|false Current position of a LOB's internal pointer or <b>FALSE</b> if an
|
||||
* error occurred.
|
||||
*/
|
||||
public function tell() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Truncates large object
|
||||
* @link https://php.net/manual/en/oci-lob.truncate.php
|
||||
* @param int $length [optional] <p>
|
||||
* If provided, this method will truncate the LOB to
|
||||
* <i>length</i> bytes. Otherwise, it will completely
|
||||
* purge the LOB.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function truncate($length = 0) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Erases a specified portion of the internal LOB data
|
||||
* @link https://php.net/manual/en/oci-lob.erase.php
|
||||
* @param int $offset [optional]
|
||||
* @param int $length [optional]
|
||||
* @return int|false The actual number of characters/bytes erased or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function erase($offset = null, $length = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Flushes/writes buffer of the LOB to the server
|
||||
* @link https://php.net/manual/en/oci-lob.flush.php
|
||||
* @param int $flag [optional] <p>
|
||||
* By default, resources are not freed, but using flag
|
||||
* <b>OCI_LOB_BUFFER_FREE</b> you can do it explicitly.
|
||||
* Be sure you know what you're doing - next read/write operation to the
|
||||
* same part of LOB will involve a round-trip to the server and initialize
|
||||
* new buffer resources. It is recommended to use
|
||||
* <b>OCI_LOB_BUFFER_FREE</b> flag only when you are not
|
||||
* going to work with the LOB anymore.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* </p>
|
||||
* <p>
|
||||
* Returns <b>FALSE</b> if buffering was not enabled or an error occurred.
|
||||
*/
|
||||
public function flush($flag = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Changes current state of buffering for the large object
|
||||
* @link https://php.net/manual/en/oci-lob.setbuffering.php
|
||||
* @param bool $on_off <p>
|
||||
* <b>TRUE</b> for on and <b>FALSE</b> for off.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure. Repeated calls to this method with the same flag will
|
||||
* return <b>TRUE</b>.
|
||||
*/
|
||||
public function setbuffering($on_off) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns current state of buffering for the large object
|
||||
* @link https://php.net/manual/en/oci-lob.getbuffering.php
|
||||
* @return bool <b>FALSE</b> if buffering for the large object is off and <b>TRUE</b> if
|
||||
* buffering is used.
|
||||
*/
|
||||
public function getbuffering() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Moves the internal pointer to the beginning of the large object
|
||||
* @link https://php.net/manual/en/oci-lob.rewind.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function rewind() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Reads part of the large object
|
||||
* @link https://php.net/manual/en/oci-lob.read.php
|
||||
* @param int $length <p>
|
||||
* The length of data to read, in bytes. Large values will be rounded down to 1 MB.
|
||||
* </p>
|
||||
* @return string|false The contents as a string, or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function read($length) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Tests for end-of-file on a large object's descriptor
|
||||
* @link https://php.net/manual/en/oci-lob.eof.php
|
||||
* @return bool <b>TRUE</b> if internal pointer of large object is at the end of LOB.
|
||||
* Otherwise returns <b>FALSE</b>.
|
||||
*/
|
||||
public function eof() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Sets the internal pointer of the large object
|
||||
* @link https://php.net/manual/en/oci-lob.seek.php
|
||||
* @param int $offset <p>
|
||||
* Indicates the amount of bytes, on which internal pointer should be
|
||||
* moved from the position, pointed by <i>whence</i>.
|
||||
* </p>
|
||||
* @param int $whence [optional] <p>
|
||||
* May be one of:
|
||||
* <b>OCI_SEEK_SET</b> - sets the position equal to
|
||||
* <i>offset</i>
|
||||
* <b>OCI_SEEK_CUR</b> - adds <i>offset</i>
|
||||
* bytes to the current position
|
||||
* <b>OCI_SEEK_END</b> - adds <i>offset</i>
|
||||
* bytes to the end of large object (use negative value to move to a position
|
||||
* before the end of large object)
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function seek($offset, $whence = OCI_SEEK_SET) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Writes data to the large object
|
||||
* @link https://php.net/manual/en/oci-lob.write.php
|
||||
* @param string $data <p>
|
||||
* The data to write in the LOB.
|
||||
* </p>
|
||||
* @param int $length [optional] <p>
|
||||
* If this parameter is given, writing will stop after
|
||||
* <i>length</i> bytes have been written or the end of
|
||||
* <i>data</i> is reached, whichever comes first.
|
||||
* </p>
|
||||
* @return int|false The number of bytes written or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function write($data, $length = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Appends data from the large object to another large object
|
||||
* @link https://php.net/manual/en/oci-lob.append.php
|
||||
* @param OCI_Lob $lob_from <p>
|
||||
* The copied LOB.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function append(OCI_Lob $lob_from) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns size of large object
|
||||
* @link https://php.net/manual/en/oci-lob.size.php
|
||||
* @return int|false Length of large object value or <b>FALSE</b> on failure.
|
||||
* Empty objects have zero length.
|
||||
*/
|
||||
public function size() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Alias of {@see OCI_Lob::export}
|
||||
* @link https://php.net/manual/en/oci-lob.writetofile.php
|
||||
* @param $filename
|
||||
* @param $start [optional]
|
||||
* @param $length [optional]
|
||||
* @return bool TRUE on success or FALSE on failure.
|
||||
*/
|
||||
public function writetofile($filename, $start, $length) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Exports LOB's contents to a file
|
||||
* @link https://php.net/manual/en/oci-lob.export.php
|
||||
* @param string $filename <p>
|
||||
* Path to the file.
|
||||
* </p>
|
||||
* @param int $start [optional] <p>
|
||||
* Indicates from where to start exporting.
|
||||
* </p>
|
||||
* @param int $length [optional] <p>
|
||||
* Indicates the length of data to be exported.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function export($filename, $start = null, $length = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Imports file data to the LOB
|
||||
* @link https://php.net/manual/en/oci-lob.import.php
|
||||
* @param string $filename <p>
|
||||
* Path to the file.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function import($filename) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Writes a temporary large object
|
||||
* @link https://php.net/manual/en/oci-lob.writetemporary.php
|
||||
* @param string $data <p>
|
||||
* The data to write.
|
||||
* </p>
|
||||
* @param int $lob_type [optional] <p>
|
||||
* Can be one of the following:
|
||||
* <b>OCI_TEMP_BLOB</b> is used to create temporary BLOBs
|
||||
* <b>OCI_TEMP_CLOB</b> is used to create
|
||||
* temporary CLOBs
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function writeTemporary($data, $lob_type = OCI_TEMP_CLOB) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Closes LOB descriptor
|
||||
* @link https://php.net/manual/en/oci-lob.close.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function close() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Saves data to the large object
|
||||
* @link https://php.net/manual/en/oci-lob.save.php
|
||||
* @param string $data <p>
|
||||
* The data to be saved.
|
||||
* </p>
|
||||
* @param int $offset [optional] <p>
|
||||
* Can be used to indicate offset from the beginning of the large object.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function save($data, $offset = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Alias of {@see OCI_Lob::import}
|
||||
* @link https://php.net/manual/en/oci-lob.savefile.php
|
||||
* @param $filename
|
||||
* @return bool Return true on success and false on failure
|
||||
*/
|
||||
public function savefile($filename) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Frees resources associated with the LOB descriptor
|
||||
* @link https://php.net/manual/en/oci-lob.free.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function free() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* OCI8 Collection functionality.
|
||||
* @link https://php.net/manual/en/class.OCI-Collection.php
|
||||
* @removed 8.0
|
||||
*/
|
||||
class OCI_Collection
|
||||
{
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Appends element to the collection
|
||||
* @link https://php.net/manual/en/oci-collection.append.php
|
||||
* @param mixed $value <p>
|
||||
* The value to be added to the collection. Can be a string or a number.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function append($value) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns value of the element
|
||||
* @link https://php.net/manual/en/oci-collection.getelem.php
|
||||
* @param int $index <p>
|
||||
* The element index. First index is 0.
|
||||
* </p>
|
||||
* @return mixed <b>FALSE</b> if such element doesn't exist; <b>NULL</b> if element is <b>NULL</b>;
|
||||
* string if element is column of a string datatype or number if element is
|
||||
* numeric field.
|
||||
*/
|
||||
public function getelem($index) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Assigns a value to the element of the collection
|
||||
* @link https://php.net/manual/en/oci-collection.assignelem.php
|
||||
* @param int $index <p>
|
||||
* The element index. First index is 0.
|
||||
* </p>
|
||||
* @param mixed $value <p>
|
||||
* Can be a string or a number.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function assignelem($index, $value) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Assigns a value to the collection from another existing collection
|
||||
* @link https://php.net/manual/en/oci-collection.assign.php
|
||||
* @param OCI_Collection $from <p>
|
||||
* An instance of OCI-Collection.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function assign(OCI_Collection $from) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns size of the collection
|
||||
* @link https://php.net/manual/en/oci-collection.size.php
|
||||
* @return int|false The number of elements in the collection or <b>FALSE</b> on error.
|
||||
*/
|
||||
public function size() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns the maximum number of elements in the collection
|
||||
* @link https://php.net/manual/en/oci-collection.max.php
|
||||
* @return int|false The maximum number as an integer, or <b>FALSE</b> on errors.
|
||||
* </p>
|
||||
* <p>
|
||||
* If the returned value is 0, then the number of elements is not limited.
|
||||
*/
|
||||
public function max() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Trims elements from the end of the collection
|
||||
* @link https://php.net/manual/en/oci-collection.trim.php
|
||||
* @param int $num <p>
|
||||
* The number of elements to be trimmed.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function trim($num) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Frees the resources associated with the collection object
|
||||
* @link https://php.net/manual/en/oci-collection.free.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function free() {}
|
||||
}
|
||||
function ocicollassign(OCICollection $to, OCICollection $from) {}
|
||||
|
|
365
oci8/oci8v3.php
365
oci8/oci8v3.php
|
@ -27,3 +27,368 @@ function oci_set_call_timeout($connection, int $time_out) {}
|
|||
* @since 7.2
|
||||
*/
|
||||
function oci_set_db_operation($connection, string $dbop) {}
|
||||
|
||||
/**
|
||||
* OCI8 LOB functionality for large binary (BLOB) and character (CLOB) objects.
|
||||
* @link https://php.net/manual/en/class.OCI-Lob.php
|
||||
* @since 8.0
|
||||
*/
|
||||
class OCILob
|
||||
{
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns large object's contents
|
||||
* @link https://php.net/manual/en/oci-lob.load.php
|
||||
* @return string|false The contents of the object, or <b>FALSE</b> on errors.
|
||||
*/
|
||||
public function load() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns the current position of internal pointer of large object
|
||||
* @link https://php.net/manual/en/oci-lob.tell.php
|
||||
* @return int|false Current position of a LOB's internal pointer or <b>FALSE</b> if an
|
||||
* error occurred.
|
||||
*/
|
||||
public function tell() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Truncates large object
|
||||
* @link https://php.net/manual/en/oci-lob.truncate.php
|
||||
* @param int $length [optional] <p>
|
||||
* If provided, this method will truncate the LOB to
|
||||
* <i>length</i> bytes. Otherwise, it will completely
|
||||
* purge the LOB.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function truncate($length = 0) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Erases a specified portion of the internal LOB data
|
||||
* @link https://php.net/manual/en/oci-lob.erase.php
|
||||
* @param int $offset [optional]
|
||||
* @param int $length [optional]
|
||||
* @return int|false The actual number of characters/bytes erased or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function erase($offset = null, $length = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Flushes/writes buffer of the LOB to the server
|
||||
* @link https://php.net/manual/en/oci-lob.flush.php
|
||||
* @param int $flag [optional] <p>
|
||||
* By default, resources are not freed, but using flag
|
||||
* <b>OCI_LOB_BUFFER_FREE</b> you can do it explicitly.
|
||||
* Be sure you know what you're doing - next read/write operation to the
|
||||
* same part of LOB will involve a round-trip to the server and initialize
|
||||
* new buffer resources. It is recommended to use
|
||||
* <b>OCI_LOB_BUFFER_FREE</b> flag only when you are not
|
||||
* going to work with the LOB anymore.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* </p>
|
||||
* <p>
|
||||
* Returns <b>FALSE</b> if buffering was not enabled or an error occurred.
|
||||
*/
|
||||
public function flush($flag = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Changes current state of buffering for the large object
|
||||
* @link https://php.net/manual/en/oci-lob.setbuffering.php
|
||||
* @param bool $on_off <p>
|
||||
* <b>TRUE</b> for on and <b>FALSE</b> for off.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure. Repeated calls to this method with the same flag will
|
||||
* return <b>TRUE</b>.
|
||||
*/
|
||||
public function setbuffering($on_off) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns current state of buffering for the large object
|
||||
* @link https://php.net/manual/en/oci-lob.getbuffering.php
|
||||
* @return bool <b>FALSE</b> if buffering for the large object is off and <b>TRUE</b> if
|
||||
* buffering is used.
|
||||
*/
|
||||
public function getbuffering() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Moves the internal pointer to the beginning of the large object
|
||||
* @link https://php.net/manual/en/oci-lob.rewind.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function rewind() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Reads part of the large object
|
||||
* @link https://php.net/manual/en/oci-lob.read.php
|
||||
* @param int $length <p>
|
||||
* The length of data to read, in bytes. Large values will be rounded down to 1 MB.
|
||||
* </p>
|
||||
* @return string|false The contents as a string, or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function read($length) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Tests for end-of-file on a large object's descriptor
|
||||
* @link https://php.net/manual/en/oci-lob.eof.php
|
||||
* @return bool <b>TRUE</b> if internal pointer of large object is at the end of LOB.
|
||||
* Otherwise returns <b>FALSE</b>.
|
||||
*/
|
||||
public function eof() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Sets the internal pointer of the large object
|
||||
* @link https://php.net/manual/en/oci-lob.seek.php
|
||||
* @param int $offset <p>
|
||||
* Indicates the amount of bytes, on which internal pointer should be
|
||||
* moved from the position, pointed by <i>whence</i>.
|
||||
* </p>
|
||||
* @param int $whence [optional] <p>
|
||||
* May be one of:
|
||||
* <b>OCI_SEEK_SET</b> - sets the position equal to
|
||||
* <i>offset</i>
|
||||
* <b>OCI_SEEK_CUR</b> - adds <i>offset</i>
|
||||
* bytes to the current position
|
||||
* <b>OCI_SEEK_END</b> - adds <i>offset</i>
|
||||
* bytes to the end of large object (use negative value to move to a position
|
||||
* before the end of large object)
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function seek($offset, $whence = OCI_SEEK_SET) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Writes data to the large object
|
||||
* @link https://php.net/manual/en/oci-lob.write.php
|
||||
* @param string $data <p>
|
||||
* The data to write in the LOB.
|
||||
* </p>
|
||||
* @param int $length [optional] <p>
|
||||
* If this parameter is given, writing will stop after
|
||||
* <i>length</i> bytes have been written or the end of
|
||||
* <i>data</i> is reached, whichever comes first.
|
||||
* </p>
|
||||
* @return int|false The number of bytes written or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function write($data, $length = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Appends data from the large object to another large object
|
||||
* @link https://php.net/manual/en/oci-lob.append.php
|
||||
* @param OCILob $lob_from <p>
|
||||
* The copied LOB.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function append(OCILob $lob_from) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns size of large object
|
||||
* @link https://php.net/manual/en/oci-lob.size.php
|
||||
* @return int|false Length of large object value or <b>FALSE</b> on failure.
|
||||
* Empty objects have zero length.
|
||||
*/
|
||||
public function size() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Alias of {@see OCILob::export}
|
||||
* @link https://php.net/manual/en/oci-lob.writetofile.php
|
||||
* @param $filename
|
||||
* @param $start [optional]
|
||||
* @param $length [optional]
|
||||
* @return bool TRUE on success or FALSE on failure.
|
||||
*/
|
||||
public function writetofile($filename, $start, $length) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Exports LOB's contents to a file
|
||||
* @link https://php.net/manual/en/oci-lob.export.php
|
||||
* @param string $filename <p>
|
||||
* Path to the file.
|
||||
* </p>
|
||||
* @param int $start [optional] <p>
|
||||
* Indicates from where to start exporting.
|
||||
* </p>
|
||||
* @param int $length [optional] <p>
|
||||
* Indicates the length of data to be exported.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function export($filename, $start = null, $length = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Imports file data to the LOB
|
||||
* @link https://php.net/manual/en/oci-lob.import.php
|
||||
* @param string $filename <p>
|
||||
* Path to the file.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function import($filename) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Writes a temporary large object
|
||||
* @link https://php.net/manual/en/oci-lob.writetemporary.php
|
||||
* @param string $data <p>
|
||||
* The data to write.
|
||||
* </p>
|
||||
* @param int $lob_type [optional] <p>
|
||||
* Can be one of the following:
|
||||
* <b>OCI_TEMP_BLOB</b> is used to create temporary BLOBs
|
||||
* <b>OCI_TEMP_CLOB</b> is used to create
|
||||
* temporary CLOBs
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function writeTemporary($data, $lob_type = OCI_TEMP_CLOB) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Closes LOB descriptor
|
||||
* @link https://php.net/manual/en/oci-lob.close.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function close() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Saves data to the large object
|
||||
* @link https://php.net/manual/en/oci-lob.save.php
|
||||
* @param string $data <p>
|
||||
* The data to be saved.
|
||||
* </p>
|
||||
* @param int $offset [optional] <p>
|
||||
* Can be used to indicate offset from the beginning of the large object.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function save($data, $offset = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Alias of {@see OCILob::import}
|
||||
* @link https://php.net/manual/en/oci-lob.savefile.php
|
||||
* @param $filename
|
||||
* @return bool Return true on success and false on failure
|
||||
*/
|
||||
public function savefile($filename) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Frees resources associated with the LOB descriptor
|
||||
* @link https://php.net/manual/en/oci-lob.free.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function free() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* OCI8 Collection functionality.
|
||||
* @link https://php.net/manual/en/class.OCICollection.php
|
||||
* @since 8.0
|
||||
*/
|
||||
class OCICollection
|
||||
{
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Appends element to the collection
|
||||
* @link https://php.net/manual/en/oci-collection.append.php
|
||||
* @param mixed $value <p>
|
||||
* The value to be added to the collection. Can be a string or a number.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function append($value) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns value of the element
|
||||
* @link https://php.net/manual/en/oci-collection.getelem.php
|
||||
* @param int $index <p>
|
||||
* The element index. First index is 0.
|
||||
* </p>
|
||||
* @return mixed <b>FALSE</b> if such element doesn't exist; <b>NULL</b> if element is <b>NULL</b>;
|
||||
* string if element is column of a string datatype or number if element is
|
||||
* numeric field.
|
||||
*/
|
||||
public function getelem($index) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Assigns a value to the element of the collection
|
||||
* @link https://php.net/manual/en/oci-collection.assignelem.php
|
||||
* @param int $index <p>
|
||||
* The element index. First index is 0.
|
||||
* </p>
|
||||
* @param mixed $value <p>
|
||||
* Can be a string or a number.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function assignelem($index, $value) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Assigns a value to the collection from another existing collection
|
||||
* @link https://php.net/manual/en/oci-collection.assign.php
|
||||
* @param OCICollection $from <p>
|
||||
* An instance of OCICollection.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function assign(OCICollection $from) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns size of the collection
|
||||
* @link https://php.net/manual/en/oci-collection.size.php
|
||||
* @return int|false The number of elements in the collection or <b>FALSE</b> on error.
|
||||
*/
|
||||
public function size() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Returns the maximum number of elements in the collection
|
||||
* @link https://php.net/manual/en/oci-collection.max.php
|
||||
* @return int|false The maximum number as an integer, or <b>FALSE</b> on errors.
|
||||
* </p>
|
||||
* <p>
|
||||
* If the returned value is 0, then the number of elements is not limited.
|
||||
*/
|
||||
public function max() {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Trims elements from the end of the collection
|
||||
* @link https://php.net/manual/en/oci-collection.trim.php
|
||||
* @param int $num <p>
|
||||
* The number of elements to be trimmed.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function trim($num) {}
|
||||
|
||||
/**
|
||||
* (PHP 5, PECL OCI8 >= 1.1.0)<br/>
|
||||
* Frees the resources associated with the collection object
|
||||
* @link https://php.net/manual/en/oci-collection.free.php
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function free() {}
|
||||
}
|
||||
|
|
|
@ -347,7 +347,7 @@ function odbc_errormsg($connection_id = null) {}
|
|||
* @return resource|false an ODBC result identifier if the SQL command was executed
|
||||
* successfully, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function odbc_exec($connection_id, $query_string, $flags = null) {}
|
||||
function odbc_exec($connection_id, $query_string) {}
|
||||
|
||||
/**
|
||||
* Fetch a result row as an associative array
|
||||
|
|
|
@ -175,6 +175,61 @@ define('OPENSSL_ZERO_PADDING', 2);
|
|||
|
||||
define('OPENSSL_DONT_ZERO_PAD_KEY', 4);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_CMS_DETACHED', 64);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_CMS_TEXT', 1);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_CMS_NOINTERN', 16);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_CMS_NOVERIFY', 32);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_CMS_NOCERTS', 2);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_CMS_NOATTR', 256);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_CMS_BINARY', 128);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_CMS_NOSIGS', 12);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_ENCODING_DER', 0);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_ENCODING_SMIME', 1);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('OPENSSL_ENCODING_PEM', 2);
|
||||
|
||||
define('OPENSSL_DEFAULT_STREAM_CIPHERS', null);
|
||||
|
||||
/**
|
||||
|
@ -186,7 +241,7 @@ define('OPENSSL_DEFAULT_STREAM_CIPHERS', null);
|
|||
* @return void
|
||||
*/
|
||||
#[Deprecated(since: "8.0")]
|
||||
function openssl_pkey_free($key): void {}
|
||||
function openssl_pkey_free(OpenSSLAsymmetricKey $key): void {}
|
||||
|
||||
/**
|
||||
* Generates a new private key
|
||||
|
@ -200,7 +255,7 @@ function openssl_pkey_free($key): void {}
|
|||
* @return OpenSSLAsymmetricKey|resource|false a resource identifier for the pkey on success, or false on
|
||||
* error.
|
||||
*/
|
||||
function openssl_pkey_new(?array $options) {}
|
||||
function openssl_pkey_new(?array $options): OpenSSLAsymmetricKey|false {}
|
||||
|
||||
/**
|
||||
* Gets an exportable representation of a key into a string
|
||||
|
@ -260,7 +315,7 @@ function openssl_pkey_export_to_file($key, string $output_filename, ?string $pas
|
|||
* </p>
|
||||
* @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 = null) {}
|
||||
function openssl_pkey_get_private($private_key, ?string $passphrase = null): OpenSSLAsymmetricKey|false {}
|
||||
|
||||
/**
|
||||
* Extract public key from certificate and prepare it for use
|
||||
|
@ -276,7 +331,7 @@ function openssl_pkey_get_private($private_key, ?string $passphrase = null) {}
|
|||
* </ol></p>
|
||||
* @return OpenSSLAsymmetricKey|resource|false a positive key resource identifier on success, or false on error.
|
||||
*/
|
||||
function openssl_pkey_get_public($public_key) {}
|
||||
function openssl_pkey_get_public($public_key): OpenSSLAsymmetricKey|false {}
|
||||
|
||||
/**
|
||||
* Returns an array with the key details
|
||||
|
@ -298,7 +353,7 @@ function openssl_pkey_get_public($public_key) {}
|
|||
* some elements may not always be available.
|
||||
*/
|
||||
#[ArrayShape(["bits" => "int", "key" => "string", "rsa" => "array", "dsa" => "array", "dh" => "array", "type" => "int"])]
|
||||
function openssl_pkey_get_details($key): array|false {}
|
||||
function openssl_pkey_get_details(OpenSSLAsymmetricKey $key): array|false {}
|
||||
|
||||
/**
|
||||
* Free key resource
|
||||
|
@ -307,7 +362,7 @@ function openssl_pkey_get_details($key): array|false {}
|
|||
* @return void
|
||||
*/
|
||||
#[Deprecated(since: "8.0")]
|
||||
function openssl_free_key($key): void {}
|
||||
function openssl_free_key(OpenSSLAsymmetricKey $key): void {}
|
||||
|
||||
/**
|
||||
* Alias of <b>openssl_pkey_get_private</b>
|
||||
|
@ -328,7 +383,7 @@ function openssl_free_key($key): void {}
|
|||
* </p>
|
||||
* @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) {}
|
||||
function openssl_get_privatekey($private_key, ?string $passphrase): OpenSSLAsymmetricKey|false {}
|
||||
|
||||
/**
|
||||
* Alias of <b>openssl_pkey_get_public</b>
|
||||
|
@ -345,7 +400,7 @@ function openssl_get_privatekey($private_key, ?string $passphrase) {}
|
|||
* </ol></p>
|
||||
* @return OpenSSLAsymmetricKey|false a positive key resource identifier on success, or FALSE on error.
|
||||
*/
|
||||
function openssl_get_publickey($public_key) {}
|
||||
function openssl_get_publickey($public_key): OpenSSLAsymmetricKey|false {}
|
||||
|
||||
/**
|
||||
* Generate a new signed public key and challenge
|
||||
|
@ -362,7 +417,7 @@ function openssl_get_publickey($public_key) {}
|
|||
* @return string|false Returns a signed public key and challenge string or NULL on failure.
|
||||
* @since 5.6
|
||||
*/
|
||||
function openssl_spki_new($private_key, string $challenge, int $digest_algo = 2): string|false {}
|
||||
function openssl_spki_new(OpenSSLAsymmetricKey $private_key, string $challenge, int $digest_algo = 2): string|false {}
|
||||
|
||||
/**
|
||||
* Verifies a signed public key and challenge
|
||||
|
@ -398,7 +453,7 @@ function openssl_spki_export(string $spki): string|false {}
|
|||
* @param OpenSSLCertificate|string|resource $certificate
|
||||
* @return OpenSSLCertificate|resource|false a resource identifier on success or false on failure.
|
||||
*/
|
||||
function openssl_x509_read($certificate) {}
|
||||
function openssl_x509_read(OpenSSLCertificate|string $certificate): OpenSSLCertificate|false {}
|
||||
|
||||
/**
|
||||
* @param string $certificate
|
||||
|
@ -407,7 +462,7 @@ function openssl_x509_read($certificate) {}
|
|||
* @return string|false <b>FALSE</b> on failure
|
||||
* @since 5.6
|
||||
*/
|
||||
function openssl_x509_fingerprint($certificate, string $digest_algo = 'sha1', bool $binary = false): string|false {}
|
||||
function openssl_x509_fingerprint(OpenSSLCertificate|string $certificate, string $digest_algo = 'sha1', bool $binary = false): string|false {}
|
||||
|
||||
/**
|
||||
* Free certificate resource
|
||||
|
@ -416,7 +471,7 @@ function openssl_x509_fingerprint($certificate, string $digest_algo = 'sha1', bo
|
|||
* @return void
|
||||
*/
|
||||
#[Deprecated(since: "8.0")]
|
||||
function openssl_x509_free($certificate): void {}
|
||||
function openssl_x509_free(OpenSSLCertificate $certificate): void {}
|
||||
|
||||
/**
|
||||
* Parse an X509 certificate and return the information as an array
|
||||
|
@ -432,7 +487,7 @@ function openssl_x509_free($certificate): void {}
|
|||
* yet documented, as it is still subject to change.
|
||||
*/
|
||||
#[ArrayShape(["name" => "string", "subject" => "string", "hash" => "string", "issuer" => "string", "version" => "int", "serialNumber" => "string", "serialNumberHex" => "string", "validFrom" => "string", "validTo" => "string", "validFrom_time_t" => "int", "validTo_time_t" => "int", "alias" => "string", "signatureTypeSN" => "string", "signatureTypeLN" => "string", "signatureTypeNID" => "int", "purposes" => "array", "extensions" => "array"])]
|
||||
function openssl_x509_parse($certificate, bool $short_names = true): array|false {}
|
||||
function openssl_x509_parse(OpenSSLCertificate|string $certificate, bool $short_names = true): array|false {}
|
||||
|
||||
/**
|
||||
* Verifies if a certificate can be used for a particular purpose
|
||||
|
@ -494,7 +549,7 @@ function openssl_x509_parse($certificate, bool $short_names = true): array|false
|
|||
* @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($certificate, int $purpose, array $ca_info = [], ?string $untrusted_certificates_file): int|bool {}
|
||||
function openssl_x509_checkpurpose(OpenSSLCertificate|string $certificate, int $purpose, array $ca_info = [], ?string $untrusted_certificates_file): int|bool {}
|
||||
|
||||
/**
|
||||
* Checks if a private key corresponds to a certificate
|
||||
|
@ -508,7 +563,7 @@ function openssl_x509_checkpurpose($certificate, int $purpose, array $ca_info =
|
|||
* @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($certificate, $private_key): bool {}
|
||||
function openssl_x509_check_private_key(OpenSSLCertificate|string $certificate, $private_key): bool {}
|
||||
|
||||
/**
|
||||
* Exports a certificate as a string
|
||||
|
@ -520,7 +575,7 @@ function openssl_x509_check_private_key($certificate, $private_key): bool {}
|
|||
* @param bool $no_text [optional]
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_x509_export($certificate, &$output, bool $no_text = true): bool {}
|
||||
function openssl_x509_export(OpenSSLCertificate|string $certificate, &$output, bool $no_text = true): bool {}
|
||||
|
||||
/**
|
||||
* Exports a certificate to file
|
||||
|
@ -532,7 +587,7 @@ function openssl_x509_export($certificate, &$output, bool $no_text = true): bool
|
|||
* @param bool $no_text [optional]
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_x509_export_to_file($certificate, string $output_filename, bool $no_text = true): bool {}
|
||||
function openssl_x509_export_to_file(OpenSSLCertificate|string $certificate, string $output_filename, bool $no_text = true): bool {}
|
||||
|
||||
/**
|
||||
* Verifies digital signature of x509 certificate against a public key
|
||||
|
@ -542,7 +597,7 @@ function openssl_x509_export_to_file($certificate, string $output_filename, bool
|
|||
* @return int Returns 1 if the signature is correct, 0 if it is incorrect, and -1 on error.
|
||||
* @since 7.4
|
||||
*/
|
||||
function openssl_x509_verify($certificate, $public_key): int {}
|
||||
function openssl_x509_verify(OpenSSLCertificate|string $certificate, $public_key): int {}
|
||||
|
||||
/**
|
||||
* Exports a PKCS#12 Compatible Certificate Store File to variable.
|
||||
|
@ -561,7 +616,7 @@ function openssl_x509_verify($certificate, $public_key): int {}
|
|||
* @return bool true on success or false on failure.
|
||||
* @since 5.2.2
|
||||
*/
|
||||
function openssl_pkcs12_export($certificate, &$output, $private_key, string $passphrase, array $options = []): bool {}
|
||||
function openssl_pkcs12_export(OpenSSLCertificate|string $certificate, &$output, $private_key, string $passphrase, array $options = []): bool {}
|
||||
|
||||
/**
|
||||
* Exports a PKCS#12 Compatible Certificate Store File
|
||||
|
@ -580,7 +635,7 @@ function openssl_pkcs12_export($certificate, &$output, $private_key, string $pas
|
|||
* @return bool true on success or false on failure.
|
||||
* @since 5.2.2
|
||||
*/
|
||||
function openssl_pkcs12_export_to_file($certificate, string $output_filename, $private_key, string $passphrase, array $options = []): bool {}
|
||||
function openssl_pkcs12_export_to_file(OpenSSLCertificate|string $certificate, string $output_filename, $private_key, string $passphrase, array $options = []): bool {}
|
||||
|
||||
/**
|
||||
* Parse a PKCS#12 Certificate Store into an array
|
||||
|
@ -690,7 +745,7 @@ function openssl_pkcs12_read(string $pkcs12, &$certificates, string $passphrase)
|
|||
* </p>
|
||||
* @return OpenSSLCertificateSigningRequest|resource|false the CSR.
|
||||
*/
|
||||
function openssl_csr_new(array $distinguished_names, &$private_key, ?array $options, ?array $extra_attributes) {}
|
||||
function openssl_csr_new(array $distinguished_names, &$private_key, ?array $options, ?array $extra_attributes): OpenSSLCertificateSigningRequest|false {}
|
||||
|
||||
/**
|
||||
* Exports a CSR as a string
|
||||
|
@ -700,7 +755,7 @@ function openssl_csr_new(array $distinguished_names, &$private_key, ?array $opti
|
|||
* @param bool $no_text [optional]
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_csr_export($csr, &$output, bool $no_text = true): bool {}
|
||||
function openssl_csr_export(OpenSSLCertificateSigningRequest|string $csr, &$output, bool $no_text = true): bool {}
|
||||
|
||||
/**
|
||||
* Exports a CSR to a file
|
||||
|
@ -712,7 +767,7 @@ function openssl_csr_export($csr, &$output, bool $no_text = true): bool {}
|
|||
* @param bool $no_text [optional]
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function openssl_csr_export_to_file($csr, string $output_filename, bool $no_text = true): bool {}
|
||||
function openssl_csr_export_to_file(OpenSSLCertificateSigningRequest|string $csr, string $output_filename, bool $no_text = true): bool {}
|
||||
|
||||
/**
|
||||
* Sign a CSR with another certificate (or itself) and generate a certificate
|
||||
|
@ -747,7 +802,7 @@ function openssl_csr_export_to_file($csr, string $output_filename, bool $no_text
|
|||
* </p>
|
||||
* @return OpenSSLCertificate|resource|false an x509 certificate resource on success, false on failure.
|
||||
*/
|
||||
function openssl_csr_sign($csr, $ca_certificate, $private_key, int $days, ?array $options, int $serial = 0) {}
|
||||
function openssl_csr_sign(OpenSSLCertificateSigningRequest|string $csr, OpenSSLCertificate|string|null $ca_certificate, $private_key, int $days, ?array $options, int $serial = 0): OpenSSLCertificate|false {}
|
||||
|
||||
/**
|
||||
* Returns the subject of a CERT
|
||||
|
@ -756,7 +811,7 @@ function openssl_csr_sign($csr, $ca_certificate, $private_key, int $days, ?array
|
|||
* @param bool $short_names [optional]
|
||||
* @return array|false
|
||||
*/
|
||||
function openssl_csr_get_subject($csr, bool $short_names = true): array|false {}
|
||||
function openssl_csr_get_subject(OpenSSLCertificateSigningRequest|string $csr, bool $short_names = true): array|false {}
|
||||
|
||||
/**
|
||||
* Returns the public key of a CERT
|
||||
|
@ -765,7 +820,7 @@ function openssl_csr_get_subject($csr, bool $short_names = true): array|false {}
|
|||
* @param bool $short_names [optional]
|
||||
* @return OpenSSLAsymmetricKey|resource|false
|
||||
*/
|
||||
function openssl_csr_get_public_key($csr, bool $short_names = true) {}
|
||||
function openssl_csr_get_public_key(OpenSSLCertificateSigningRequest|string $csr, bool $short_names = true): OpenSSLAsymmetricKey|false {}
|
||||
|
||||
/**
|
||||
* Computes a digest
|
||||
|
@ -894,7 +949,7 @@ 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 = null): int|false {}
|
||||
function openssl_seal(string $data, &$sealed_data, &$encrypted_keys, array $public_key, string $cipher_algo, &$iv = null): int|false {}
|
||||
|
||||
/**
|
||||
* Open sealed data
|
||||
|
@ -910,7 +965,7 @@ function openssl_seal(string $data, &$sealed_data, &$encrypted_keys, array $publ
|
|||
* @param string|null $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 = '', ?string $iv): bool {}
|
||||
function openssl_open(string $data, &$output, string $encrypted_key, $private_key, string $cipher_algo, ?string $iv): bool {}
|
||||
|
||||
/**
|
||||
* Generates a PKCS5 v2 PBKDF2 string, defaults to SHA-1
|
||||
|
@ -1000,7 +1055,7 @@ 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, $certificate, $private_key, ?array $headers, int $flags = PKCS7_DETACHED, ?string $untrusted_certificates_filename): bool {}
|
||||
function openssl_pkcs7_sign(string $input_filename, string $output_filename, OpenSSLCertificate|string $certificate, $private_key, ?array $headers, int $flags = PKCS7_DETACHED, ?string $untrusted_certificates_filename): bool {}
|
||||
|
||||
/**
|
||||
* Encrypt an S/MIME message
|
||||
|
@ -1139,7 +1194,7 @@ function openssl_get_cipher_methods(bool $aliases = false): array {}
|
|||
* @return string|false computed key on success or false on failure.
|
||||
* @since 5.3
|
||||
*/
|
||||
function openssl_dh_compute_key(string $public_key, $private_key): string|false {}
|
||||
function openssl_dh_compute_key(string $public_key, OpenSSLAsymmetricKey $private_key): string|false {}
|
||||
|
||||
/**
|
||||
* @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $public_key
|
||||
|
@ -1164,9 +1219,9 @@ function openssl_pkey_derive($public_key, $private_key, int $key_length = 0): st
|
|||
* if the algorithm used was "cryptographically strong", e.g., safe for usage with GPG,
|
||||
* passwords, etc. true if it did, otherwise false
|
||||
* </p>
|
||||
* @return string|false the generated string of bytes on success, or false on failure.
|
||||
* @return string the generated string of bytes.
|
||||
*/
|
||||
function openssl_random_pseudo_bytes(int $length, &$strong_result): string|false {}
|
||||
function openssl_random_pseudo_bytes(int $length, &$strong_result): string {}
|
||||
|
||||
/**
|
||||
* Return openSSL error message
|
||||
|
@ -1194,3 +1249,105 @@ function openssl_get_curve_names(): array|false {}
|
|||
* @since 7.2
|
||||
*/
|
||||
function openssl_pkcs7_read(string $data, &$certificates): bool {}
|
||||
|
||||
/**
|
||||
* Verifies that the data block is intact, the signer is who they say they are, and returns the certs of the signers.
|
||||
* @param string $input_filename
|
||||
* @param int $flags [optional]
|
||||
* @param string|null $certificates [optional]
|
||||
* @param array $ca_info
|
||||
* @param string|null $untrusted_certificates_filename [optional]
|
||||
* @param string|null $content [optional]
|
||||
* @param string|null $pk7 [optional]
|
||||
* @param string|null $sigfile [optional]
|
||||
* @param int $encoding [optional]
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
function openssl_cms_verify(string $input_filename, int $flags = 0, ?string $certificates, array $ca_info = [], ?string $untrusted_certificates_filename, ?string $content, ?string $pk7, ?string $sigfile, int $encoding = OPENSSL_ENCODING_SMIME): bool {}
|
||||
|
||||
/**
|
||||
* Encrypts the message in the file with the certificates and outputs the result to the supplied file.
|
||||
* @param string $input_filename
|
||||
* @param string $output_filename
|
||||
* @param resource|string|array $certificate
|
||||
* @param null|array $headers
|
||||
* @param int $flags
|
||||
* @param int $encoding
|
||||
* @param int $cipher_algo
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
function openssl_cms_encrypt(string $input_filename, string $output_filename, $certificate, ?array $headers, int $flags = 0, int $encoding = OPENSSL_ENCODING_SMIME, int $cipher_algo = OPENSSL_CIPHER_AES_128_CBC): bool {}
|
||||
|
||||
/**
|
||||
* Signs the MIME message in the file with a cert and key and output the result to the supplied file.
|
||||
* @param string $input_filename
|
||||
* @param string $output_filename
|
||||
* @param OpenSSLCertificate|string $certificate
|
||||
* @param OpenSSLAsymmetricKey|OpenSSLCertificate|array|string $private_key
|
||||
* @param array|null $headers
|
||||
* @param int $flags [optional]
|
||||
* @param int $encoding [optional]
|
||||
* @param string|null $untrusted_certificates_filename [optional]
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
function openssl_cms_sign(string $input_filename, string $output_filename, OpenSSLCertificate|string $certificate, $private_key, ?array $headers, int $flags = 0, int $encoding = OPENSSL_ENCODING_SMIME, ?string $untrusted_certificates_filename): bool {}
|
||||
|
||||
/**
|
||||
* Decrypts the S/MIME message in the file and outputs the results to the supplied file.
|
||||
* @param string $input_filename
|
||||
* @param string $output_filename
|
||||
* @param resource|string $certificate
|
||||
* @param resource|string|array $private_key
|
||||
* @param int $encoding
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
function openssl_cms_decrypt(string $input_filename, string $output_filename, $certificate, $private_key = null, int $encoding = OPENSSL_ENCODING_SMIME): bool {}
|
||||
|
||||
/**
|
||||
* Exports the CMS file to an array of PEM certificates.
|
||||
* @param string $input_filename
|
||||
* @param array &$certificates
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
function openssl_cms_read(string $input_filename, &$certificates): bool {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class OpenSSLCertificate
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct OpenSSLCertificate, use openssl_x509_read() instead
|
||||
* @see openssl_x509_read()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class OpenSSLCertificateSigningRequest
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct OpenSSLCertificateSigningRequest, use openssl_csr_new() instead
|
||||
* @see openssl_csr_new()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class OpenSSLAsymmetricKey
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct OpenSSLAsymmetricKey, use openssl_pkey_new() instead
|
||||
* @see openssl_pkey_new()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
|
|
@ -724,11 +724,11 @@ function pcntl_errno(): int {}
|
|||
* @link https://php.net/manual/en/function.pcntl-strerror.php
|
||||
* @param int $error_code <p>
|
||||
* </p>
|
||||
* @return string|false error description on success or <b>FALSE</b> on failure.
|
||||
* @return string error description.
|
||||
* @since 5.3.4
|
||||
*/
|
||||
#[Pure]
|
||||
function pcntl_strerror(int $error_code): string|false {}
|
||||
function pcntl_strerror(int $error_code): string {}
|
||||
|
||||
/**
|
||||
* Get the priority of any process
|
||||
|
@ -867,7 +867,7 @@ function pcntl_sigtimedwait(array $signals, &$info = [], int $seconds = 0, int $
|
|||
* @return bool
|
||||
* @since 7.1
|
||||
*/
|
||||
function pcntl_async_signals(?bool $enable): bool {}
|
||||
function pcntl_async_signals(?bool $enable = null): bool {}
|
||||
|
||||
/**
|
||||
* Get the current handler for specified signal.
|
||||
|
|
|
@ -337,10 +337,10 @@ function preg_match(string $pattern, string $subject, &$matches, int $flags = 0,
|
|||
* So, $out[0] contains array of strings that matched full pattern,
|
||||
* and $out[1] contains array of strings enclosed by tags.
|
||||
* </p>
|
||||
* @return int|false|null the number of full pattern matches (which might be zero),
|
||||
* @return int|false 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 = 0, int $offset = 0): int|false|null {}
|
||||
function preg_match_all(string $pattern, string $subject, &$matches, int $flags = 0, int $offset = 0): int|false {}
|
||||
|
||||
/**
|
||||
* Perform a regular expression search and replace
|
||||
|
@ -612,3 +612,12 @@ function preg_grep(string $pattern, array $array, int $flags = 0): array|false {
|
|||
*/
|
||||
#[Pure(true)]
|
||||
function preg_last_error(): int {}
|
||||
|
||||
/**
|
||||
* Returns the error message of the last PCRE regex execution
|
||||
*
|
||||
* @return string one of the error messages or "No error" if there is no error.
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function preg_last_error_msg(): string {}
|
||||
|
|
|
@ -419,7 +419,7 @@ define('PGSQL_DIAG_SEVERITY_NONLOCALIZED', 86);
|
|||
* </p>
|
||||
* @return resource|false PostgreSQL connection resource on success, <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_connect(string $connection_string, int $flags = 0, string $host = '', string $port = '', string $options = '', string $tty = '', string $dbname = '') {}
|
||||
function pg_connect(string $connection_string, int $flags = 0) {}
|
||||
|
||||
/**
|
||||
* Open a persistent PostgreSQL connection
|
||||
|
@ -450,7 +450,7 @@ function pg_connect(string $connection_string, int $flags = 0, string $host = ''
|
|||
* </p>
|
||||
* @return resource|false PostgreSQL connection resource on success, <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_pconnect(string $connection_string, string $host = '', string $port = '', string $options = '', string $tty = '', string $dbname = '') {}
|
||||
function pg_pconnect(string $connection_string, int $flags = 0) {}
|
||||
|
||||
/**
|
||||
* Closes a PostgreSQL connection
|
||||
|
@ -475,7 +475,7 @@ function pg_close($connection = null): bool {}
|
|||
* <b>PGSQL_POLLING_OK</b>, or <b>PGSQL_POLLING_ACTIVE</b>.
|
||||
* @since 5.6
|
||||
*/
|
||||
function pg_connect_poll($connection = null): int {}
|
||||
function pg_connect_poll($connection): int {}
|
||||
|
||||
/**
|
||||
* Get connection status
|
||||
|
@ -682,7 +682,7 @@ function pg_transaction_status($connection): int {}
|
|||
* </p>
|
||||
* @return resource|false A query result resource on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_query($connection = null, string $query = null) {}
|
||||
function pg_query($connection, string $query = null) {}
|
||||
|
||||
/**
|
||||
* Submits a command to the server and waits for the result, with the ability to pass parameters separately from the SQL command text.
|
||||
|
@ -718,7 +718,7 @@ function pg_query($connection = null, string $query = null) {}
|
|||
* </p>
|
||||
* @return resource|false A query result resource on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_query_params($connection = null, $query = '', array $params = null) {}
|
||||
function pg_query_params($connection, $query, array $params = null) {}
|
||||
|
||||
/**
|
||||
* Submits a request to create a prepared statement with the
|
||||
|
@ -742,7 +742,7 @@ function pg_query_params($connection = null, $query = '', array $params = null)
|
|||
* </p>
|
||||
* @return resource|false A query result resource on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_prepare($connection = null, string $statement_name = '', string $query = null) {}
|
||||
function pg_prepare($connection, string $statement_name, string $query = null) {}
|
||||
|
||||
/**
|
||||
* Sends a request to execute a prepared statement with given parameters, and waits for the result.
|
||||
|
@ -770,7 +770,7 @@ function pg_prepare($connection = null, string $statement_name = '', string $que
|
|||
* </p>
|
||||
* @return resource|false A query result resource on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_execute($connection = null, string $statement_name = '', array $params = null) {}
|
||||
function pg_execute($connection, $statement_name, array $params = null) {}
|
||||
|
||||
/**
|
||||
* Sends asynchronous query
|
||||
|
@ -899,7 +899,7 @@ function pg_cancel_query($connection): bool {}
|
|||
* <b>FALSE</b> is returned if <i>row</i> exceeds the number
|
||||
* of rows in the set, or on any other error.
|
||||
*/
|
||||
function pg_fetch_result($result, $row = 0, string|int $field = null): string|false|null {}
|
||||
function pg_fetch_result($result, $row, string|int $field = null): string|false|null {}
|
||||
|
||||
/**
|
||||
* Get a row as an enumerated array
|
||||
|
@ -1008,7 +1008,7 @@ function pg_fetch_array($result, ?int $row = null, int $mode = PGSQL_BOTH): arra
|
|||
* <b>FALSE</b> is returned if <i>row</i> exceeds the number
|
||||
* of rows in the set, there are no more rows, or on any other error.
|
||||
*/
|
||||
function pg_fetch_object($result, ?int $row = null, string $class = 'stdClass', $l = null, array $constructor_args = []): object|false {}
|
||||
function pg_fetch_object($result, ?int $row = null, string $class = 'stdClass', array $constructor_args = []): object|false {}
|
||||
|
||||
/**
|
||||
* Fetches all rows from a result as an array
|
||||
|
@ -1259,7 +1259,7 @@ function pg_field_type_oid($result, int $field): string|int {}
|
|||
* @param mixed $field
|
||||
* @return int|false The field printed length, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function pg_field_prtlen($result, $row = 0, string|int $field = null): int|false {}
|
||||
function pg_field_prtlen($result, $row, string|int $field = null): int|false {}
|
||||
|
||||
/**
|
||||
* Test if a field is SQL NULL
|
||||
|
@ -1280,7 +1280,7 @@ function pg_field_prtlen($result, $row = 0, string|int $field = null): int|false
|
|||
* @return int|false 1 if the field in the given row is SQL NULL, 0
|
||||
* if not. <b>FALSE</b> is returned if the row is out of range, or upon any other error.
|
||||
*/
|
||||
function pg_field_is_null($result, $row = 0, string|int $field = null): int|false {}
|
||||
function pg_field_is_null($result, $row, string|int $field = null): int|false {}
|
||||
|
||||
/**
|
||||
* Returns the name or oid of the tables field
|
||||
|
@ -1324,7 +1324,7 @@ function pg_field_table($result, int $field, bool $oid_only = false): string|int
|
|||
* Otherwise if no NOTIFY is waiting, then <b>FALSE</b> is returned.
|
||||
*/
|
||||
#[ArrayShape(["message" => "string", "pid" => "int", "payload" => "string"])]
|
||||
function pg_get_notify($connection = null, int $mode = 1): array|false {}
|
||||
function pg_get_notify($connection, int $mode = 1): array|false {}
|
||||
|
||||
/**
|
||||
* Gets the backend's process ID
|
||||
|
@ -1334,7 +1334,7 @@ function pg_get_notify($connection = null, int $mode = 1): array|false {}
|
|||
* </p>
|
||||
* @return int The backend database process ID.
|
||||
*/
|
||||
function pg_get_pid($connection = null): int {}
|
||||
function pg_get_pid($connection): int {}
|
||||
|
||||
/**
|
||||
* Get error message associated with result
|
||||
|
@ -1420,7 +1420,7 @@ function pg_last_notice($connection, int $mode = PGSQL_NOTICE_LAST): array|strin
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_put_line($connection = null, string $query = null): bool {}
|
||||
function pg_put_line($connection, string $query = null): bool {}
|
||||
|
||||
/**
|
||||
* Sync with PostgreSQL backend
|
||||
|
@ -1551,7 +1551,7 @@ function pg_lo_create($connection = null, $oid = null): string|int|false {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_lo_unlink($connection = null, $oid = null): bool {}
|
||||
function pg_lo_unlink($connection, $oid = null): bool {}
|
||||
|
||||
/**
|
||||
* Open a large object
|
||||
|
@ -1571,7 +1571,7 @@ function pg_lo_unlink($connection = null, $oid = null): bool {}
|
|||
* </p>
|
||||
* @return resource|false A large object resource or <b>FALSE</b> on error.
|
||||
*/
|
||||
function pg_lo_open($connection = null, $oid = null, string $mode = null) {}
|
||||
function pg_lo_open($connection, $oid = null, string $mode = null) {}
|
||||
|
||||
/**
|
||||
* Close a large object
|
||||
|
@ -1648,7 +1648,7 @@ function pg_lo_read_all($lob): int {}
|
|||
* @return string|int|false The OID of the newly created large object, or
|
||||
* <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_lo_import($connection = null, $pathname, $object_id = null): string|int|false {}
|
||||
function pg_lo_import($connection, $pathname, $object_id = null): string|int|false {}
|
||||
|
||||
/**
|
||||
* Export a large object to file
|
||||
|
@ -1668,7 +1668,7 @@ function pg_lo_import($connection = null, $pathname, $object_id = null): string|
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function pg_lo_export($connection = null, $oid, $pathname): bool {}
|
||||
function pg_lo_export($connection, $oid, $pathname): bool {}
|
||||
|
||||
/**
|
||||
* Seeks position within a large object
|
||||
|
@ -1708,7 +1708,7 @@ function pg_lo_tell($lob): int {}
|
|||
* @param int $size The number of bytes to truncate.
|
||||
* @return bool Returns true on success or false on failure.
|
||||
*/
|
||||
function pg_lo_truncate($lob, int $size = 0): bool {}
|
||||
function pg_lo_truncate($lob, int $size): bool {}
|
||||
|
||||
/**
|
||||
* Escape a string for query
|
||||
|
@ -1724,7 +1724,7 @@ function pg_lo_truncate($lob, int $size = 0): bool {}
|
|||
* </p>
|
||||
* @return string A string containing the escaped data.
|
||||
*/
|
||||
function pg_escape_string($connection = null, string $string = null): string {}
|
||||
function pg_escape_string($connection, string $string = null): string {}
|
||||
|
||||
/**
|
||||
* Escape a string for insertion into a bytea field
|
||||
|
@ -1741,7 +1741,7 @@ function pg_escape_string($connection = null, string $string = null): string {}
|
|||
* </p>
|
||||
* @return string A string containing the escaped data.
|
||||
*/
|
||||
function pg_escape_bytea($connection = null, string $string = null): string {}
|
||||
function pg_escape_bytea($connection, string $string = null): string {}
|
||||
|
||||
/**
|
||||
* Escape a identifier for insertion into a text field
|
||||
|
@ -1758,7 +1758,7 @@ function pg_escape_bytea($connection = null, string $string = null): string {}
|
|||
* @return string|false A string containing the escaped data.
|
||||
* @since 5.4.4
|
||||
*/
|
||||
function pg_escape_identifier($connection = null, string $string = null): string|false {}
|
||||
function pg_escape_identifier($connection, string $string = null): string|false {}
|
||||
|
||||
/**
|
||||
* Escape a literal for insertion into a text field
|
||||
|
@ -1775,7 +1775,7 @@ function pg_escape_identifier($connection = null, string $string = null): string
|
|||
* @return string|false A string containing the escaped data.
|
||||
* @since 5.4.4
|
||||
*/
|
||||
function pg_escape_literal($connection = null, string $string = null): string|false {}
|
||||
function pg_escape_literal($connection, string $string = null): string|false {}
|
||||
|
||||
/**
|
||||
* Unescape binary for bytea type
|
||||
|
@ -1807,7 +1807,7 @@ function pg_unescape_bytea(string $string): string {}
|
|||
* <b>PGSQL_ERRORS_DEFAULT</b>
|
||||
* or <b>PGSQL_ERRORS_VERBOSE</b>.
|
||||
*/
|
||||
function pg_set_error_verbosity($connection = null, int $verbosity = null): int|false {}
|
||||
function pg_set_error_verbosity($connection, int $verbosity = null): int|false {}
|
||||
|
||||
/**
|
||||
* Gets the client encoding
|
||||
|
@ -1844,7 +1844,7 @@ function pg_client_encoding($connection = null): string {}
|
|||
* </p>
|
||||
* @return int 0 on success or -1 on error.
|
||||
*/
|
||||
function pg_set_client_encoding($connection = null, string $encoding = null): int {}
|
||||
function pg_set_client_encoding($connection, string $encoding = null): int {}
|
||||
|
||||
/**
|
||||
* Get meta data for table
|
||||
|
@ -1857,7 +1857,7 @@ function pg_set_client_encoding($connection = null, string $encoding = null): in
|
|||
* </p>
|
||||
* @return array|false An array of the table definition, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function pg_meta_data($connection, string $table_name): array|false {}
|
||||
function pg_meta_data($connection, string $table_name, bool $extended = false): array|false {}
|
||||
|
||||
/**
|
||||
* Convert associative array values into suitable for SQL statement
|
||||
|
@ -2004,7 +2004,7 @@ function pg_select($connection, string $table_name, array $conditions, int $flag
|
|||
* @param $query
|
||||
* @return mixed
|
||||
*/
|
||||
function pg_exec($connection = null, string $query = null) {}
|
||||
function pg_exec($connection, string $query = null) {}
|
||||
|
||||
/**
|
||||
* @param $result
|
||||
|
@ -2080,7 +2080,7 @@ function pg_fieldnum($result, string $field): int {}
|
|||
* @return int|false
|
||||
* @deprecated
|
||||
*/
|
||||
function pg_fieldprtlen($result, $row = 0, string|int $field): int|false {}
|
||||
function pg_fieldprtlen($result, $row, string|int $field): int|false {}
|
||||
|
||||
/**
|
||||
* @param $result
|
||||
|
@ -2089,7 +2089,7 @@ function pg_fieldprtlen($result, $row = 0, string|int $field): int|false {}
|
|||
* @return int|false
|
||||
* @deprecated
|
||||
*/
|
||||
function pg_fieldisnull($result, $row = 0, string|int $field): int|false {}
|
||||
function pg_fieldisnull($result, $row, string|int $field): int|false {}
|
||||
|
||||
/**
|
||||
* @param $result
|
||||
|
@ -2099,12 +2099,12 @@ function pg_fieldisnull($result, $row = 0, string|int $field): int|false {}
|
|||
function pg_freeresult($result): bool {}
|
||||
|
||||
/**
|
||||
* @param PgSql\Result|resource $result
|
||||
* @param resource $result
|
||||
* @param $row
|
||||
* @param $field
|
||||
* @deprecated
|
||||
*/
|
||||
function pg_result($connection): string|null|false {}
|
||||
function pg_result($result, $row, string|int $field = null): string|null|false {}
|
||||
|
||||
/**
|
||||
* @param $lob
|
||||
|
@ -2126,7 +2126,7 @@ function pg_locreate($connection, $oid): string|int|false {}
|
|||
* @return bool
|
||||
* @deprecated
|
||||
*/
|
||||
function pg_lounlink($connection = null, $oid): bool {}
|
||||
function pg_lounlink($connection, $oid): bool {}
|
||||
|
||||
/**
|
||||
* @param $connection
|
||||
|
@ -2135,7 +2135,7 @@ function pg_lounlink($connection = null, $oid): bool {}
|
|||
* @return resource
|
||||
* @deprecated
|
||||
*/
|
||||
function pg_loopen($connection = null, $oid, string $mode) {}
|
||||
function pg_loopen($connection, $oid, string $mode) {}
|
||||
|
||||
/**
|
||||
* @param $lob
|
||||
|
@ -2168,7 +2168,7 @@ function pg_lowrite($lob, string $data, ?int $length): int|false {}
|
|||
* @return string|int|false
|
||||
* @deprecated
|
||||
*/
|
||||
function pg_loimport($connection = null, $filename, $oid): string|int|false {}
|
||||
function pg_loimport($connection, $filename, $oid): string|int|false {}
|
||||
|
||||
/**
|
||||
* @param $connection
|
||||
|
@ -2177,7 +2177,7 @@ function pg_loimport($connection = null, $filename, $oid): string|int|false {}
|
|||
* @return bool
|
||||
* @deprecated
|
||||
*/
|
||||
function pg_loexport($connection = null, $oid, $filename): bool {}
|
||||
function pg_loexport($connection, $oid, $filename): bool {}
|
||||
|
||||
/**
|
||||
* @param $connection [optional]
|
||||
|
@ -2192,12 +2192,12 @@ function pg_clientencoding($connection): string {}
|
|||
* @return int
|
||||
* @deprecated
|
||||
*/
|
||||
function pg_setclientencoding($connection = null, string $encoding): int {}
|
||||
function pg_setclientencoding($connection, string $encoding): int {}
|
||||
|
||||
/**
|
||||
* Reads input on the connection
|
||||
* @link https://www.php.net/manual/en/function.pg-consume-input.php
|
||||
* @param PgSql\Connection|resource $connection
|
||||
* @param resource $connection
|
||||
* @return bool true if no error occurred, or false if there was an error.
|
||||
* Note that true does not necessarily indicate that input was waiting to be read.
|
||||
*/
|
||||
|
@ -2206,7 +2206,7 @@ function pg_consume_input($connection): bool {}
|
|||
/**
|
||||
* Flush outbound query data on the connection
|
||||
* @link https://www.php.net/manual/en/function.pg-flush.php
|
||||
* @param PgSql\Connection|resource $connection
|
||||
* @param resource $connection
|
||||
* @return int|bool Returns true if the flush was successful or no data was waiting to be flushed, 0 if part of the pending
|
||||
* data was flushed but more remains or false on failure.
|
||||
*/
|
||||
|
|
|
@ -1,10 +1,12 @@
|
|||
<phpunit bootstrap="vendor/autoload.php"
|
||||
failOnWarning="true">
|
||||
<testsuites>
|
||||
<testsuite name="PHP_7.4">
|
||||
<testsuite name="PHP_8.0">
|
||||
<file>tests/BaseClassesTest.php</file>
|
||||
<file>tests/BaseConstantsTest.php</file>
|
||||
<file>tests/BaseFunctionsTest.php</file>
|
||||
<file>tests/StubsParameterNamesTest.php</file>
|
||||
<file>tests/StubsTypeHintsTest.php</file>
|
||||
<file>tests/StubsForbiddenTypeHintsTest.php</file>
|
||||
</testsuite>
|
||||
<testsuite name="PhpDoc">
|
||||
|
|
|
@ -36,7 +36,7 @@ interface SessionHandlerInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function destroy($id): bool;
|
||||
public function destroy(string $id): bool;
|
||||
|
||||
/**
|
||||
* Cleanup old sessions
|
||||
|
@ -52,7 +52,7 @@ interface SessionHandlerInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function gc($max_lifetime): int|false;
|
||||
public function gc(int $max_lifetime): int|false;
|
||||
|
||||
/**
|
||||
* Initialize session
|
||||
|
@ -66,7 +66,7 @@ interface SessionHandlerInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function open($path, $name): bool;
|
||||
public function open(string $path, string $name): bool;
|
||||
|
||||
/**
|
||||
* Read session data
|
||||
|
@ -80,7 +80,7 @@ interface SessionHandlerInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function read($id): string|false;
|
||||
public function read(string $id): string|false;
|
||||
|
||||
/**
|
||||
* Write session data
|
||||
|
@ -100,7 +100,7 @@ interface SessionHandlerInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function write($id, $data): bool;
|
||||
public function write(string $id, string $data): bool;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -207,7 +207,7 @@ class SessionHandler implements SessionHandlerInterface, SessionIdInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function destroy($id): bool {}
|
||||
public function destroy(string $id): bool {}
|
||||
|
||||
/**
|
||||
* Cleanup old sessions
|
||||
|
@ -223,7 +223,7 @@ class SessionHandler implements SessionHandlerInterface, SessionIdInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function gc($max_lifetime): int|false {}
|
||||
public function gc(int $max_lifetime): int|false {}
|
||||
|
||||
/**
|
||||
* Initialize session
|
||||
|
@ -237,7 +237,7 @@ class SessionHandler implements SessionHandlerInterface, SessionIdInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function open($path, $name): bool {}
|
||||
public function open(string $path, string $name): bool {}
|
||||
|
||||
/**
|
||||
* Read session data
|
||||
|
@ -251,7 +251,7 @@ class SessionHandler implements SessionHandlerInterface, SessionIdInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function read($id): string|false {}
|
||||
public function read(string $id): string|false {}
|
||||
|
||||
/**
|
||||
* Write session data
|
||||
|
@ -271,7 +271,7 @@ class SessionHandler implements SessionHandlerInterface, SessionIdInterface
|
|||
* @since 5.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function write($id, $data): bool {}
|
||||
public function write(string $id, string $data): bool {}
|
||||
|
||||
/**
|
||||
* Validate session id
|
||||
|
|
|
@ -23,7 +23,7 @@ use JetBrains\PhpStorm\Deprecated;
|
|||
* </p>
|
||||
* @return string|false the name of the current session.
|
||||
*/
|
||||
function session_name(string $name): string {}
|
||||
function session_name(null|string $name): string|false {}
|
||||
|
||||
/**
|
||||
* Get and/or set the current session module.<br/>
|
||||
|
@ -35,7 +35,7 @@ function session_name(string $name): string {}
|
|||
* </p>
|
||||
* @return string|false the name of the current session module.
|
||||
*/
|
||||
function session_module_name(string $module): string {}
|
||||
function session_module_name(null|string $module): string|false {}
|
||||
|
||||
/**
|
||||
* Get and/or set the current session save path
|
||||
|
@ -54,7 +54,7 @@ function session_module_name(string $module): string {}
|
|||
* </p>
|
||||
* @return string|false the path of the current directory used for data storage.
|
||||
*/
|
||||
function session_save_path(string $path): string {}
|
||||
function session_save_path(null|string $path): string|false {}
|
||||
|
||||
/**
|
||||
* Get and/or set the current session id
|
||||
|
@ -75,7 +75,7 @@ function session_save_path(string $path): string {}
|
|||
* session or the empty string ("") if there is no current
|
||||
* session (no current session id exists).
|
||||
*/
|
||||
function session_id(string $id): string {}
|
||||
function session_id(null|string $id): string|false {}
|
||||
|
||||
/**
|
||||
* Update the current session id with a newly generated one
|
||||
|
@ -150,7 +150,7 @@ function session_is_registered(string $name): bool {}
|
|||
* @link https://php.net/manual/en/function.session-encode.php
|
||||
* @return string|false the contents of the current session encoded.
|
||||
*/
|
||||
function session_encode(): string {}
|
||||
function session_encode(): string|false {}
|
||||
|
||||
/**
|
||||
* Initialize session data
|
||||
|
@ -172,14 +172,14 @@ function session_start(array $options = []): bool {}
|
|||
* If it is used without active session, it omits collision check.
|
||||
* @since 7.1
|
||||
*/
|
||||
function session_create_id(string $prefix = ''): string {}
|
||||
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(): int {}
|
||||
function session_gc(): int|false {}
|
||||
|
||||
/**
|
||||
* Destroys all data registered to a session
|
||||
|
@ -313,7 +313,7 @@ function session_set_save_handler(SessionHandlerInterface $sessionhandler, bool
|
|||
* </table>
|
||||
* @return string|false the name of the current cache limiter.
|
||||
*/
|
||||
function session_cache_limiter(string $value): string {}
|
||||
function session_cache_limiter(null|string $value): string|false {}
|
||||
|
||||
/**
|
||||
* Return current cache expire
|
||||
|
@ -330,7 +330,7 @@ function session_cache_limiter(string $value): string {}
|
|||
* @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): int {}
|
||||
function session_cache_expire(null|int $value): int|false {}
|
||||
|
||||
/**
|
||||
* Set the session cookie parameters
|
||||
|
@ -408,7 +408,7 @@ function session_write_close(): bool {}
|
|||
/**
|
||||
* Alias of <b>session_write_close</b>
|
||||
* @link https://php.net/manual/en/function.session-commit.php
|
||||
* @return bool since 7.2.0 returns true on success or false on failure.
|
||||
* @return void|bool since 7.2.0 returns true on success or false on failure.
|
||||
*/
|
||||
function session_commit(): bool {}
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@ use JetBrains\PhpStorm\Deprecated;
|
|||
* use to access the shared memory segment you've created. <b>FALSE</b> is
|
||||
* returned on failure.
|
||||
*/
|
||||
function shmop_open(int $key, string $mode, int $permissions, int $size) {}
|
||||
function shmop_open(int $key, string $mode, int $permissions, int $size): Shmop|false {}
|
||||
|
||||
/**
|
||||
* Read data from shared memory block
|
||||
|
@ -43,7 +43,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($shmop, int $offset, int $size): string|false {}
|
||||
function shmop_read(Shmop $shmop, int $offset, int $size): string {}
|
||||
|
||||
/**
|
||||
* Close shared memory block
|
||||
|
@ -55,7 +55,7 @@ function shmop_read($shmop, int $offset, int $size): string|false {}
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[Deprecated(since: "8.0")]
|
||||
function shmop_close($shmop): void {}
|
||||
function shmop_close(Shmop $shmop): void {}
|
||||
|
||||
/**
|
||||
* Get size of shared memory block
|
||||
|
@ -67,7 +67,7 @@ function shmop_close($shmop): void {}
|
|||
* @return int an int, which represents the number of bytes the shared memory
|
||||
* block occupies.
|
||||
*/
|
||||
function shmop_size($shmop): int {}
|
||||
function shmop_size(Shmop $shmop): int {}
|
||||
|
||||
/**
|
||||
* Write data into shared memory block
|
||||
|
@ -86,7 +86,7 @@ function shmop_size($shmop): int {}
|
|||
* @return int|false The size of the written <i>data</i>, or <b>FALSE</b> on
|
||||
* failure.
|
||||
*/
|
||||
function shmop_write($shmop, string $data, int $offset): int|false {}
|
||||
function shmop_write(Shmop $shmop, string $data, int $offset): int {}
|
||||
|
||||
/**
|
||||
* Delete shared memory block
|
||||
|
@ -97,4 +97,9 @@ function shmop_write($shmop, string $data, int $offset): int|false {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function shmop_delete($shmop): bool {}
|
||||
function shmop_delete(Shmop $shmop): bool {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class Shmop {}
|
||||
|
|
|
@ -333,7 +333,7 @@ class SoapClient
|
|||
* @throws SoapFault A SoapFault exception will be thrown if the wsdl URI cannot be loaded.
|
||||
* @since 5.0.1
|
||||
*/
|
||||
public function __construct($wsdl, array $options = null) {}
|
||||
public function __construct(string|null $wsdl, array $options = null) {}
|
||||
|
||||
/**
|
||||
* SoapClient constructor
|
||||
|
@ -471,7 +471,7 @@ class SoapClient
|
|||
*/
|
||||
#[Deprecated]
|
||||
#[TentativeType]
|
||||
public function __call($name, array $args): mixed {}
|
||||
public function __call(string $name, array $args): mixed {}
|
||||
|
||||
/**
|
||||
* Calls a SOAP function
|
||||
|
@ -515,7 +515,7 @@ class SoapClient
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function __soapCall($name, array $args, $options = null, $inputHeaders = null, &$outputHeaders = null): mixed {}
|
||||
public function __soapCall(string $name, array $args, array|null $options = null, $inputHeaders = null, &$outputHeaders = null): mixed {}
|
||||
|
||||
/**
|
||||
* Returns last SOAP request
|
||||
|
@ -604,7 +604,7 @@ class SoapClient
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function __doRequest($request, $location, $action, $version, int $oneWay = 0): ?string {}
|
||||
public function __doRequest(string $request, string $location, string $action, int $version, bool $oneWay = false): ?string {}
|
||||
|
||||
/**
|
||||
* The __setCookie purpose
|
||||
|
@ -619,7 +619,7 @@ class SoapClient
|
|||
* @since 5.0.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function __setCookie($name, string $value): void {}
|
||||
public function __setCookie(string $name, string|null $value): void {}
|
||||
|
||||
/**
|
||||
* Sets the location of the Web service to use
|
||||
|
@ -631,7 +631,7 @@ class SoapClient
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function __setLocation($location = ''): ?string {}
|
||||
public function __setLocation(string|null $location = ''): ?string {}
|
||||
|
||||
/**
|
||||
* Sets SOAP headers for subsequent calls
|
||||
|
@ -713,7 +713,7 @@ class SoapVar
|
|||
* </p>
|
||||
* @since 5.0.1
|
||||
*/
|
||||
public function __construct($data, ?int $encoding, string $typeName, $typeNamespace = '', $nodeName = '', $nodeNamespace = '') {}
|
||||
public function __construct(mixed $data, int|null $encoding, string|null $typeName, string|null $typeNamespace = '', string|null $nodeName = '', string|null $nodeNamespace = '') {}
|
||||
|
||||
/**
|
||||
* SoapVar constructor
|
||||
|
@ -788,7 +788,7 @@ class SoapServer
|
|||
* </p>
|
||||
* @since 5.0.1
|
||||
*/
|
||||
public function __construct($wsdl, array $options = null) {}
|
||||
public function __construct(string|null $wsdl, array $options = null) {}
|
||||
|
||||
/**
|
||||
* SoapServer constructor
|
||||
|
@ -854,7 +854,7 @@ class SoapServer
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setPersistence($mode): void {}
|
||||
public function setPersistence(int $mode): void {}
|
||||
|
||||
/**
|
||||
* Sets the class which handles SOAP requests
|
||||
|
@ -867,7 +867,7 @@ class SoapServer
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setClass($class, ...$args): void {}
|
||||
public function setClass(string $class, mixed ...$args): void {}
|
||||
|
||||
/**
|
||||
* Sets the object which will be used to handle SOAP requests
|
||||
|
@ -925,7 +925,7 @@ class SoapServer
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function handle($request = null): void {}
|
||||
public function handle(string|null $request = null): void {}
|
||||
|
||||
/**
|
||||
* Issue SoapServer fault indicating an error
|
||||
|
@ -949,7 +949,7 @@ class SoapServer
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fault($code, $string, $actor = null, $details = null, $name = null): void {}
|
||||
public function fault(string $code, string $string, string $actor = null, mixed $details = null, string $name = null): void {}
|
||||
|
||||
/**
|
||||
* Add a SOAP header to the response
|
||||
|
@ -1037,7 +1037,7 @@ class SoapFault extends Exception
|
|||
* @since 5.0.1
|
||||
*/
|
||||
#[Pure]
|
||||
public function __construct($code, $string, $actor = null, $details = null, $name = null, $headerFault = null) {}
|
||||
public function __construct(array|string|null $code, string $string, string|null $actor = null, mixed $details = null, string|null $name = null, mixed $headerFault = null) {}
|
||||
|
||||
/**
|
||||
* SoapFault constructor
|
||||
|
@ -1072,7 +1072,7 @@ class SoapFault extends Exception
|
|||
* @return string A string describing the SoapFault.
|
||||
* @since 5.0.1
|
||||
*/
|
||||
public function __toString() {}
|
||||
public function __toString(): string {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1106,7 +1106,7 @@ class SoapParam
|
|||
* </p>
|
||||
* @since 5.0.1
|
||||
*/
|
||||
public function __construct($data, $name) {}
|
||||
public function __construct(mixed $data, string $name) {}
|
||||
|
||||
/**
|
||||
* SoapParam constructor
|
||||
|
@ -1181,7 +1181,7 @@ class SoapHeader
|
|||
* </p>
|
||||
* @since 5.0.1
|
||||
*/
|
||||
public function __construct($namespace, $name, $data = null, $mustUnderstand = false, $actor = null) {}
|
||||
public function __construct(string $namespace, string $name, mixed $data = null, bool $mustUnderstand = false, string|int|null $actor = null) {}
|
||||
|
||||
/**
|
||||
* SoapHeader constructor
|
||||
|
|
|
@ -896,32 +896,32 @@ function socket_addrinfo_lookup(string $host, ?string $service, array $hints = [
|
|||
* Create a Socket resource, and connect it to the provided AddrInfo resource.<br/>
|
||||
* The return value of this function may be used with the rest of the socket functions.
|
||||
* @link https://www.php.net/manual/en/function.socket-addrinfo-connect.php
|
||||
* @param resource|AddressInfo $address <p>
|
||||
* @param AddressInfo $address <p>
|
||||
* Resource created from {@see socket_addrinfo_lookup()}
|
||||
* </p>
|
||||
* @return resource|null|false Socket resource on success or NULL on failure.
|
||||
* @return Socket|false Socket resource on success or false on failure.
|
||||
* @since 7.2
|
||||
*/
|
||||
function socket_addrinfo_connect(AddressInfo $address) {}
|
||||
function socket_addrinfo_connect(AddressInfo $address): Socket|false {}
|
||||
|
||||
/**
|
||||
* (PHP 7 >= 7.2.0)<br/>
|
||||
* Create a Socket resource, and bind it to the provided AddrInfo resource.<br/>
|
||||
* The return value of this function may be used with {@see socket_listen()}.
|
||||
* @link https://www.php.net/manual/en/function.socket-addrinfo-bind.php
|
||||
* @param resource|AddressInfo $address <p>
|
||||
* @param AddressInfo $address <p>
|
||||
* Resource created from {@see socket_addrinfo_lookup()}
|
||||
* </p>
|
||||
* @return resource|null|false Socket resource on success or NULL on failure.
|
||||
* @return Socket|false Socket resource on success or false on failure.
|
||||
* @since 7.2
|
||||
*/
|
||||
function socket_addrinfo_bind(AddressInfo $address) {}
|
||||
function socket_addrinfo_bind(AddressInfo $address): Socket|false {}
|
||||
|
||||
/**
|
||||
* (PHP 7 >= 7.2.0)<br/>
|
||||
* Get information about addrinfo
|
||||
* @link https://www.php.net/manual/en/function.socket-addrinfo-explain.php
|
||||
* @param resource|AddressInfo $address <p>
|
||||
* @param AddressInfo $address <p>
|
||||
* Resource created from {@see socket_addrinfo_lookup()}
|
||||
* </p>
|
||||
* @return array containing the fields in the addrinfo structure.
|
||||
|
@ -1110,19 +1110,19 @@ function socket_select(?array &$read, ?array &$write, ?array &$except, ?int $sec
|
|||
* </td>
|
||||
* </tr>
|
||||
* </table>
|
||||
* @return resource|false <b>socket_create</b> returns a socket resource on success,
|
||||
* @return Socket|false <b>socket_create</b> returns a socket resource on success,
|
||||
* or <b>FALSE</b> on error. The actual error code can be retrieved by calling
|
||||
* <b>socket_last_error</b>. This error code may be passed to
|
||||
* <b>socket_strerror</b> to get a textual explanation of the
|
||||
* error.
|
||||
*/
|
||||
function socket_create(int $domain, int $type, int $protocol) {}
|
||||
function socket_create(int $domain, int $type, int $protocol): Socket|false {}
|
||||
|
||||
/**
|
||||
* @param resource $socket
|
||||
* @return resource|false
|
||||
* @param Socket $socket
|
||||
* @return Socket|false
|
||||
*/
|
||||
function socket_export_stream($socket) {}
|
||||
function socket_export_stream(Socket $socket): Socket|false {}
|
||||
|
||||
/**
|
||||
* Opens a socket on port to accept connections
|
||||
|
@ -1137,13 +1137,13 @@ function socket_export_stream($socket) {}
|
|||
* <i>backlog</i> parameter, see
|
||||
* <b>socket_listen</b> for more information.
|
||||
* </p>
|
||||
* @return resource|false <b>socket_create_listen</b> returns a new socket resource
|
||||
* @return Socket|false <b>socket_create_listen</b> returns a new socket resource
|
||||
* on success or <b>FALSE</b> on error. The error code can be retrieved with
|
||||
* <b>socket_last_error</b>. This code may be passed to
|
||||
* <b>socket_strerror</b> to get a textual explanation of the
|
||||
* error.
|
||||
*/
|
||||
function socket_create_listen(int $port, int $backlog = 128) {}
|
||||
function socket_create_listen(int $port, int $backlog = 128): Socket|false {}
|
||||
|
||||
/**
|
||||
* Creates a pair of indistinguishable sockets and stores them in an array
|
||||
|
@ -1181,43 +1181,43 @@ function socket_create_pair(int $domain, int $type, int $protocol, &$pair): bool
|
|||
/**
|
||||
* Accepts a connection on a socket
|
||||
* @link https://php.net/manual/en/function.socket-accept.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>.
|
||||
* </p>
|
||||
* @return resource|false a new socket resource on success, or <b>FALSE</b> on error. The actual
|
||||
* @return Socket|false a new socket resource on success, or <b>FALSE</b> on error. The actual
|
||||
* error code can be retrieved by calling
|
||||
* <b>socket_last_error</b>. This error code may be passed to
|
||||
* <b>socket_strerror</b> to get a textual explanation of the
|
||||
* error.
|
||||
*/
|
||||
function socket_accept($socket) {}
|
||||
function socket_accept(Socket $socket): Socket|false {}
|
||||
|
||||
/**
|
||||
* Sets nonblocking mode for file descriptor fd
|
||||
* @link https://php.net/manual/en/function.socket-set-nonblock.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>
|
||||
* or <b>socket_accept</b>.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function socket_set_nonblock($socket): bool {}
|
||||
function socket_set_nonblock(Socket $socket): bool {}
|
||||
|
||||
/**
|
||||
* Sets blocking mode on a socket resource
|
||||
* @link https://php.net/manual/en/function.socket-set-block.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>
|
||||
* or <b>socket_accept</b>.
|
||||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function socket_set_block($socket): bool {}
|
||||
function socket_set_block(Socket $socket): bool {}
|
||||
|
||||
/**
|
||||
* Listens for a connection on a socket
|
||||
* @link https://php.net/manual/en/function.socket-listen.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>.
|
||||
* </p>
|
||||
* @param int $backlog [optional] <p>
|
||||
|
@ -1241,23 +1241,23 @@ function socket_set_block($socket): bool {}
|
|||
* <b>socket_strerror</b> to get a textual explanation of the
|
||||
* error.
|
||||
*/
|
||||
function socket_listen($socket, int $backlog = 0): bool {}
|
||||
function socket_listen(Socket $socket, int $backlog = 0): bool {}
|
||||
|
||||
/**
|
||||
* Closes a socket resource
|
||||
* @link https://php.net/manual/en/function.socket-close.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>
|
||||
* or <b>socket_accept</b>.
|
||||
* </p>
|
||||
* @return void No value is returned.
|
||||
*/
|
||||
function socket_close($socket): void {}
|
||||
function socket_close(Socket $socket): void {}
|
||||
|
||||
/**
|
||||
* Write to a socket
|
||||
* @link https://php.net/manual/en/function.socket-write.php
|
||||
* @param resource $socket
|
||||
* @param Socket $socket
|
||||
* @param string $data <p>
|
||||
* The buffer to be written.
|
||||
* </p>
|
||||
|
@ -1279,12 +1279,12 @@ function socket_close($socket): void {}
|
|||
* === operator to check for <b>FALSE</b> in case of an
|
||||
* error.
|
||||
*/
|
||||
function socket_write($socket, string $data, ?int $length = null): int|false {}
|
||||
function socket_write(Socket $socket, string $data, ?int $length = null): int|false {}
|
||||
|
||||
/**
|
||||
* Reads a maximum of length bytes from a socket
|
||||
* @link https://php.net/manual/en/function.socket-read.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>
|
||||
* or <b>socket_accept</b>.
|
||||
* </p>
|
||||
|
@ -1310,12 +1310,12 @@ function socket_write($socket, string $data, ?int $length = null): int|false {}
|
|||
* <b>socket_read</b> returns a zero length string ("")
|
||||
* when there is no more data to read.</p>
|
||||
*/
|
||||
function socket_read($socket, int $length, int $mode = PHP_BINARY_READ): string|false {}
|
||||
function socket_read(Socket $socket, int $length, int $mode = PHP_BINARY_READ): string|false {}
|
||||
|
||||
/**
|
||||
* Queries the local side of the given socket which may either result in host/port or in a Unix filesystem path, dependent on its type
|
||||
* @link https://php.net/manual/en/function.socket-getsockname.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>
|
||||
* or <b>socket_accept</b>.
|
||||
* </p>
|
||||
|
@ -1341,12 +1341,12 @@ function socket_read($socket, int $length, int $mode = PHP_BINARY_READ): string|
|
|||
* <b>AF_INET6</b>, or <b>AF_UNIX</b>, in which
|
||||
* case the last socket error code is not updated.
|
||||
*/
|
||||
function socket_getsockname($socket, &$address, &$port = null): bool {}
|
||||
function socket_getsockname(Socket $socket, &$address, &$port = null): bool {}
|
||||
|
||||
/**
|
||||
* Queries the remote side of the given socket which may either result in host/port or in a Unix filesystem path, dependent on its type
|
||||
* @link https://php.net/manual/en/function.socket-getpeername.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>
|
||||
* or <b>socket_accept</b>.
|
||||
* </p>
|
||||
|
@ -1374,12 +1374,12 @@ function socket_getsockname($socket, &$address, &$port = null): bool {}
|
|||
* <b>AF_INET6</b>, or <b>AF_UNIX</b>, in which
|
||||
* case the last socket error code is not updated.
|
||||
*/
|
||||
function socket_getpeername($socket, &$address, &$port = null): bool {}
|
||||
function socket_getpeername(Socket $socket, &$address, &$port = null): bool {}
|
||||
|
||||
/**
|
||||
* Initiates a connection on a socket
|
||||
* @link https://php.net/manual/en/function.socket-connect.php
|
||||
* @param resource $socket
|
||||
* @param Socket $socket
|
||||
* @param string $address <p>
|
||||
* The <i>address</i> parameter is either an IPv4 address
|
||||
* in dotted-quad notation (e.g. 127.0.0.1) if
|
||||
|
@ -1404,7 +1404,7 @@ function socket_getpeername($socket, &$address, &$port = null): bool {}
|
|||
* If the socket is non-blocking then this function returns <b>FALSE</b> with an
|
||||
* error Operation now in progress.
|
||||
*/
|
||||
function socket_connect($socket, string $address, ?int $port = null): bool {}
|
||||
function socket_connect(Socket $socket, string $address, ?int $port = null): bool {}
|
||||
|
||||
/**
|
||||
* Return a string describing a socket error
|
||||
|
@ -1421,7 +1421,7 @@ function socket_strerror(int $error_code): string {}
|
|||
/**
|
||||
* Binds a name to a socket
|
||||
* @link https://php.net/manual/en/function.socket-bind.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>.
|
||||
* </p>
|
||||
* @param string $address <p>
|
||||
|
@ -1446,12 +1446,12 @@ function socket_strerror(int $error_code): string {}
|
|||
* textual explanation of the error.
|
||||
* </p>
|
||||
*/
|
||||
function socket_bind($socket, string $address, int $port = 0): bool {}
|
||||
function socket_bind(Socket $socket, string $address, int $port = 0): bool {}
|
||||
|
||||
/**
|
||||
* Receives data from a connected socket
|
||||
* @link https://php.net/manual/en/function.socket-recv.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* The <i>socket</i> must be a socket resource previously
|
||||
* created by socket_create().
|
||||
* </p>
|
||||
|
@ -1510,12 +1510,12 @@ function socket_bind($socket, string $address, int $port = 0): bool {}
|
|||
* passed to <b>socket_strerror</b> to get a textual explanation
|
||||
* of the error.
|
||||
*/
|
||||
function socket_recv($socket, &$data, int $length, int $flags): int|false {}
|
||||
function socket_recv(Socket $socket, &$data, int $length, int $flags): int|false {}
|
||||
|
||||
/**
|
||||
* Sends data to a connected socket
|
||||
* @link https://php.net/manual/en/function.socket-send.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>
|
||||
* or <b>socket_accept</b>.
|
||||
* </p>
|
||||
|
@ -1562,24 +1562,24 @@ function socket_recv($socket, &$data, int $length, int $flags): int|false {}
|
|||
* </p>
|
||||
* @return int|false <b>socket_send</b> returns the number of bytes sent, or <b>FALSE</b> on error.
|
||||
*/
|
||||
function socket_send($socket, string $data, int $length, int $flags): int|false {}
|
||||
function socket_send(Socket $socket, string $data, int $length, int $flags): int|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >=5.5.0)<br/>
|
||||
* Send a message
|
||||
* @link https://secure.php.net/manual/en/function.socket-sendmsg.php
|
||||
* @param resource $socket
|
||||
* @param Socket $socket
|
||||
* @param array $message
|
||||
* @param int $flags
|
||||
* @return int|false
|
||||
* @since 5.5
|
||||
*/
|
||||
function socket_sendmsg($socket, array $message, int $flags): int|false {}
|
||||
function socket_sendmsg(Socket $socket, array $message, int $flags = 0): int|false {}
|
||||
|
||||
/**
|
||||
* Receives data from a socket whether or not it is connection-oriented
|
||||
* @link https://php.net/manual/en/function.socket-recvfrom.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* The <i>socket</i> must be a socket resource previously
|
||||
* created by socket_create().
|
||||
* </p>
|
||||
|
@ -1648,23 +1648,23 @@ function socket_sendmsg($socket, array $message, int $flags): int|false {}
|
|||
* passed to <b>socket_strerror</b> to get a textual explanation
|
||||
* of the error.
|
||||
*/
|
||||
function socket_recvfrom($socket, &$data, int $length, int $flags, &$address, &$port = null): int|false {}
|
||||
function socket_recvfrom(Socket $socket, &$data, int $length, int $flags, &$address, &$port = null): int|false {}
|
||||
|
||||
/**
|
||||
* Read a message
|
||||
* @link https://secure.php.net/manual/en/function.socket-recvmsg.php
|
||||
* @param resource $socket
|
||||
* @param Socket $socket
|
||||
* @param array &$message
|
||||
* @param int $flags
|
||||
* @return int|false
|
||||
* @since 5.5
|
||||
*/
|
||||
function socket_recvmsg($socket, array &$message, int $flags): int|false {}
|
||||
function socket_recvmsg(Socket $socket, array &$message, int $flags = 0): int|false {}
|
||||
|
||||
/**
|
||||
* Sends a message to a socket, whether it is connected or not
|
||||
* @link https://php.net/manual/en/function.socket-sendto.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created using <b>socket_create</b>.
|
||||
* </p>
|
||||
* @param string $data <p>
|
||||
|
@ -1718,12 +1718,12 @@ function socket_recvmsg($socket, array &$message, int $flags): int|false {}
|
|||
* @return int|false <b>socket_sendto</b> returns the number of bytes sent to the
|
||||
* remote host, or <b>FALSE</b> if an error occurred.
|
||||
*/
|
||||
function socket_sendto($socket, string $data, int $length, int $flags, string $address, ?int $port = null): int|false {}
|
||||
function socket_sendto(Socket $socket, string $data, int $length, int $flags, string $address, ?int $port = null): int|false {}
|
||||
|
||||
/**
|
||||
* Gets socket options for the socket
|
||||
* @link https://php.net/manual/en/function.socket-get-option.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>
|
||||
* or <b>socket_accept</b>.
|
||||
* </p>
|
||||
|
@ -2084,12 +2084,12 @@ function socket_sendto($socket, string $data, int $length, int $flags, string $a
|
|||
* </table>
|
||||
* @return array|int|false the value of the given option, or <b>FALSE</b> on errors.
|
||||
*/
|
||||
function socket_get_option($socket, int $level, int $option): array|int|false {}
|
||||
function socket_get_option(Socket $socket, int $level, int $option): array|int|false {}
|
||||
|
||||
/**
|
||||
* Sets socket options for the socket
|
||||
* @link https://php.net/manual/en/function.socket-set-option.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>
|
||||
* or <b>socket_accept</b>.
|
||||
* </p>
|
||||
|
@ -2111,12 +2111,12 @@ function socket_get_option($socket, int $level, int $option): array|int|false {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function socket_set_option($socket, int $level, int $option, $value): bool {}
|
||||
function socket_set_option(Socket $socket, int $level, int $option, $value): bool {}
|
||||
|
||||
/**
|
||||
* Shuts down a socket for receiving, sending, or both
|
||||
* @link https://php.net/manual/en/function.socket-shutdown.php
|
||||
* @param resource $socket <p>
|
||||
* @param Socket $socket <p>
|
||||
* A valid socket resource created with <b>socket_create</b>.
|
||||
* </p>
|
||||
* @param int $mode [optional] <p>
|
||||
|
@ -2145,38 +2145,38 @@ function socket_set_option($socket, int $level, int $option, $value): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function socket_shutdown($socket, int $mode = 2): bool {}
|
||||
function socket_shutdown(Socket $socket, int $mode = 2): bool {}
|
||||
|
||||
/**
|
||||
* Returns the last error on the socket
|
||||
* @link https://php.net/manual/en/function.socket-last-error.php
|
||||
* @param resource $socket [optional] <p>
|
||||
* @param Socket $socket [optional] <p>
|
||||
* A valid socket resource created with <b>socket_create</b>.
|
||||
* </p>
|
||||
* @return int This function returns a socket error code.
|
||||
*/
|
||||
function socket_last_error($socket = null): int {}
|
||||
function socket_last_error(?Socket $socket = null): int {}
|
||||
|
||||
/**
|
||||
* Clears the error on the socket or the last error code
|
||||
* @link https://php.net/manual/en/function.socket-clear-error.php
|
||||
* @param resource|null $socket [optional] <p>
|
||||
* @param Socket|null $socket [optional] <p>
|
||||
* A valid socket resource created with <b>socket_create</b>.
|
||||
* </p>
|
||||
* @return void No value is returned.
|
||||
*/
|
||||
function socket_clear_error($socket = null): void {}
|
||||
function socket_clear_error(?Socket $socket = null): void {}
|
||||
|
||||
/**
|
||||
* Import a stream
|
||||
* @link https://php.net/manual/en/function.socket-import-stream.php
|
||||
* @param resource $stream <p>
|
||||
* @param Socket $stream <p>
|
||||
* The stream resource to import.
|
||||
* </p>
|
||||
* @return resource|false|null <b>FALSE</b> or <b>NULL</b> on failure.
|
||||
* @return Socket|false|null <b>FALSE</b> or <b>NULL</b> on failure.
|
||||
* @since 5.4
|
||||
*/
|
||||
function socket_import_stream($stream) {}
|
||||
function socket_import_stream($stream): Socket|false {}
|
||||
|
||||
/**
|
||||
* Calculate message buffer size
|
||||
|
@ -2187,32 +2187,32 @@ function socket_import_stream($stream) {}
|
|||
* @return int|null
|
||||
* @since 5.5
|
||||
*/
|
||||
function socket_cmsg_space(int $level, int $type): ?int {}
|
||||
function socket_cmsg_space(int $level, int $type, int $num = 0): ?int {}
|
||||
|
||||
/**
|
||||
* Alias of {@see socket_get_option}
|
||||
* @param $socket
|
||||
* @param Socket $socket
|
||||
* @param int $level
|
||||
* @param int $option
|
||||
*/
|
||||
function socket_getopt($socket, int $level, int $option): array|int|false {}
|
||||
function socket_getopt(Socket $socket, int $level, int $option): array|int|false {}
|
||||
|
||||
/**
|
||||
* Alias of {@see socket_set_option}
|
||||
* @param $socket
|
||||
* @param Socket $socket
|
||||
* @param int $level
|
||||
* @param int $option
|
||||
* @param $value
|
||||
* @return bool
|
||||
*/
|
||||
function socket_setopt($socket, int $level, int $option, $value): bool {}
|
||||
function socket_setopt(Socket $socket, int $level, int $option, $value): bool {}
|
||||
|
||||
/**
|
||||
* Exports the WSAPROTOCOL_INFO Structure
|
||||
*
|
||||
* @link https://www.php.net/manual/en/function.socket-wsaprotocol-info-export.php
|
||||
*
|
||||
* @param resource $socket
|
||||
* @param Socket $socket
|
||||
* @param int $target_pid
|
||||
* @return string|false
|
||||
*
|
||||
|
@ -2226,7 +2226,7 @@ function socket_wsaprotocol_info_export($socket, $target_pid) {}
|
|||
* @link https://www.php.net/manual/en/function.socket-wsaprotocol-info-import.php
|
||||
*
|
||||
* @param string $info_id
|
||||
* @return resource|false
|
||||
* @return Socket|false
|
||||
*
|
||||
* @since 7.3
|
||||
*/
|
||||
|
@ -2243,3 +2243,27 @@ function socket_wsaprotocol_info_import($info_id) {}
|
|||
* @since 7.3
|
||||
*/
|
||||
function socket_wsaprotocol_info_release($info_id) {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class Socket
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct Socket, use socket_create() instead
|
||||
* @see socket_create()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class AddressInfo
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct AddressInfo, use socket_addrinfo_lookup() instead
|
||||
* @see socket_addrinfo_lookup()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
|
|
@ -665,7 +665,7 @@ function sodium_crypto_pwhash_str_verify(string $hash, string $password): bool {
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_crypto_pwhash_scryptsalsa208sha256(int $length, string $password, string $salt, int $opslimit, int $memlimit, $alg = null): string {}
|
||||
function sodium_crypto_pwhash_scryptsalsa208sha256(int $length, string $password, string $salt, int $opslimit, int $memlimit): string {}
|
||||
|
||||
/**
|
||||
* Get a formatted password hash (for storage)
|
||||
|
@ -1025,7 +1025,7 @@ function sodium_version_string(): string {}
|
|||
* @throws SodiumException
|
||||
* @since 7.2
|
||||
*/
|
||||
function sodium_crypto_scalarmult_base(string $secret_key, $string_2): string {}
|
||||
function sodium_crypto_scalarmult_base(string $secret_key): string {}
|
||||
|
||||
/**
|
||||
* Creates a random key
|
||||
|
|
|
@ -147,7 +147,7 @@ class SQLite3
|
|||
* SQLite database.
|
||||
* </p>
|
||||
*/
|
||||
public function __construct($filename, $flags = SQLITE3_OPEN_READWRITE|SQLITE3_OPEN_CREATE, $encryptionKey = null) {}
|
||||
public function __construct(string $filename, int $flags = SQLITE3_OPEN_READWRITE|SQLITE3_OPEN_CREATE, string $encryptionKey = null) {}
|
||||
|
||||
/**
|
||||
* Returns the SQLite3 library version as a string constant and as a number
|
||||
|
@ -169,7 +169,7 @@ class SQLite3
|
|||
* statement.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public static function escapeString($string): string {}
|
||||
public static function escapeString(string $string): string {}
|
||||
|
||||
/**
|
||||
* Opens an SQLite database
|
||||
|
@ -192,7 +192,7 @@ class SQLite3
|
|||
* @return void No value is returned.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function open($filename, $flags = SQLITE3_OPEN_READWRITE|SQLITE3_OPEN_CREATE, $encryptionKey = null): void {}
|
||||
public function open(string $filename, int $flags = SQLITE3_OPEN_READWRITE|SQLITE3_OPEN_CREATE, string $encryptionKey = null): void {}
|
||||
|
||||
/**
|
||||
* Closes the database connection
|
||||
|
@ -211,7 +211,7 @@ class SQLite3
|
|||
* @return bool <b>TRUE</b> if the query succeeded, <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function exec($query): bool {}
|
||||
public function exec(string $query): bool {}
|
||||
|
||||
/**
|
||||
* Returns the row ID of the most recent INSERT into the database
|
||||
|
@ -249,7 +249,7 @@ class SQLite3
|
|||
* @since 5.3.3
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function busyTimeout($milliseconds): bool {}
|
||||
public function busyTimeout(int $milliseconds): bool {}
|
||||
|
||||
/**
|
||||
* Attempts to load an SQLite extension library
|
||||
|
@ -261,7 +261,7 @@ class SQLite3
|
|||
* @return bool <b>TRUE</b> if the extension is successfully loaded, <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function loadExtension($name): bool {}
|
||||
public function loadExtension(string $name): bool {}
|
||||
|
||||
/**
|
||||
* Returns the number of database rows that were changed (or inserted or
|
||||
|
@ -283,7 +283,7 @@ class SQLite3
|
|||
* @return SQLite3Stmt|false an <b>SQLite3Stmt</b> object on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function prepare($query): SQLite3Stmt|false {}
|
||||
public function prepare(string $query): SQLite3Stmt|false {}
|
||||
|
||||
/**
|
||||
* Executes an SQL query
|
||||
|
@ -294,7 +294,7 @@ class SQLite3
|
|||
* @return SQLite3Result|false an <b>SQLite3Result</b> object, or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function query($query): SQLite3Result|false {}
|
||||
public function query(string $query): SQLite3Result|false {}
|
||||
|
||||
/**
|
||||
* Executes a query and returns a single result
|
||||
|
@ -320,7 +320,7 @@ class SQLite3
|
|||
* Invalid or failing queries will return <b>FALSE</b>.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function querySingle($query, $entireRow = false): mixed {}
|
||||
public function querySingle(string $query, bool $entireRow = false): mixed {}
|
||||
|
||||
/**
|
||||
* Registers a PHP function for use as an SQL scalar function
|
||||
|
@ -344,7 +344,7 @@ class SQLite3
|
|||
* @return bool <b>TRUE</b> upon successful creation of the function, <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function createFunction($name, $callback, $argCount = -1, int $flags = 0): bool {}
|
||||
public function createFunction(string $name, callable $callback, int $argCount = -1, int $flags = 0): bool {}
|
||||
|
||||
/**
|
||||
* Registers a PHP function for use as an SQL aggregate function
|
||||
|
@ -369,7 +369,7 @@ class SQLite3
|
|||
* failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function createAggregate($name, $stepCallback, $finalCallback, $argCount = -1): bool {}
|
||||
public function createAggregate(string $name, callable $stepCallback, callable $finalCallback, int $argCount = -1): bool {}
|
||||
|
||||
/**
|
||||
* Registers a PHP function for use as an SQL collating function
|
||||
|
@ -388,7 +388,7 @@ class SQLite3
|
|||
* @since 5.3.11
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function createCollation($name, callable $callback): bool {}
|
||||
public function createCollation(string $name, callable $callback): bool {}
|
||||
|
||||
/**
|
||||
* Opens a stream resource to read a BLOB
|
||||
|
@ -401,7 +401,7 @@ class SQLite3
|
|||
* <p>Either <b>SQLITE3_OPEN_READONLY</b> or <b>SQLITE3_OPEN_READWRITE</b> to open the stream for reading only, or for reading and writing, respectively.</p>
|
||||
* @return resource|false Returns a stream resource, or FALSE on failure.
|
||||
*/
|
||||
public function openBlob($table, $column, $rowid, $database = 'main', int $flags = SQLITE3_OPEN_READONLY) {}
|
||||
public function openBlob(string $table, string $column, int $rowid, string $database = 'main', int $flags = SQLITE3_OPEN_READONLY) {}
|
||||
|
||||
/**
|
||||
* Enable throwing exceptions
|
||||
|
@ -410,7 +410,7 @@ class SQLite3
|
|||
* @return bool Returns the old value; true if exceptions were enabled, false otherwise.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function enableExceptions($enable = false): bool {}
|
||||
public function enableExceptions(bool $enable = false): bool {}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
|
@ -424,7 +424,7 @@ class SQLite3
|
|||
* @since 7.4
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function enableExtendedResultCodes(bool $enable): bool {}
|
||||
public function enableExtendedResultCodes(bool $enable = true): bool {}
|
||||
|
||||
/**
|
||||
* @param SQLite3 $destination
|
||||
|
@ -435,6 +435,14 @@ class SQLite3
|
|||
*/
|
||||
#[TentativeType]
|
||||
public function backup(SQLite3 $destination, string $sourceDatabase = 'main', string $destinationDatabase = 'main'): bool {}
|
||||
|
||||
/**
|
||||
* @param null|callable $callback
|
||||
* @return bool
|
||||
* @since 8.0
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setAuthorizer(?callable $callback): bool {}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -447,7 +455,7 @@ class SQLite3Stmt
|
|||
* @param SQLite3 $sqlite3
|
||||
* @param string $query
|
||||
*/
|
||||
private function __construct($sqlite3) {}
|
||||
private function __construct(SQLite3 $sqlite3, string $query) {}
|
||||
|
||||
/**
|
||||
* Returns the number of parameters within the prepared statement
|
||||
|
@ -513,7 +521,7 @@ class SQLite3Stmt
|
|||
* on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function bindParam($param, &$var, $type = SQLITE3_TEXT): bool {}
|
||||
public function bindParam(string|int $param, mixed &$var, int $type = SQLITE3_TEXT): bool {}
|
||||
|
||||
/**
|
||||
* Binds the value of a parameter to a statement variable
|
||||
|
@ -537,7 +545,7 @@ class SQLite3Stmt
|
|||
* on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function bindValue($param, $value, $type = SQLITE3_TEXT): bool {}
|
||||
public function bindValue(string|int $param, mixed $value, int $type = SQLITE3_TEXT): bool {}
|
||||
|
||||
#[TentativeType]
|
||||
public function readOnly(): bool {}
|
||||
|
@ -579,7 +587,7 @@ class SQLite3Result
|
|||
* <i>column_number</i>.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function columnName($column): string|false {}
|
||||
public function columnName(int $column): string|false {}
|
||||
|
||||
/**
|
||||
* Returns the type of the nth column
|
||||
|
@ -594,7 +602,7 @@ class SQLite3Result
|
|||
* <b>SQLITE3_NULL</b>).
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function columnType($column): int|false {}
|
||||
public function columnType(int $column): int|false {}
|
||||
|
||||
/**
|
||||
* Fetches a result row as an associative or numerically indexed array or both
|
||||
|
@ -612,7 +620,7 @@ class SQLite3Result
|
|||
* both. Alternately will return <b>FALSE</b> if there are no more rows.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function fetchArray($mode = SQLITE3_BOTH): array|false {}
|
||||
public function fetchArray(int $mode = SQLITE3_BOTH): array|false {}
|
||||
|
||||
/**
|
||||
* Resets the result set back to the first row
|
||||
|
|
|
@ -182,7 +182,7 @@ namespace {
|
|||
* Returns the yielded key or, if none was specified, an auto-incrementing key or null if the generator is already closed.
|
||||
* @return TKey
|
||||
*/
|
||||
public function key(): string|float|int|bool|null {}
|
||||
public function key(): mixed {}
|
||||
|
||||
/**
|
||||
* Resumes the generator (unless the generator is already closed).
|
||||
|
|
|
@ -105,7 +105,7 @@ define('PASSWORD_ARGON2_PROVIDER', "standard");
|
|||
* Returns information about the given hash
|
||||
* @link https://secure.php.net/manual/en/function.password-get-info.php
|
||||
* @param string $hash A hash created by password_hash().
|
||||
* @return array|null Returns an associative array with three elements:
|
||||
* @return array Returns an associative array with three elements:
|
||||
* <ul>
|
||||
* <li>
|
||||
* <em>algo</em>, which will match a
|
||||
|
@ -122,7 +122,7 @@ define('PASSWORD_ARGON2_PROVIDER', "standard");
|
|||
* @since 5.5
|
||||
*/
|
||||
#[ArrayShape(["algo" => "int", "algoName" => "string", "options" => "array"])]
|
||||
function password_get_info(string $hash): ?array {}
|
||||
function password_get_info(string $hash): array {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.5.0, PHP 5)<br/>
|
||||
|
@ -138,10 +138,10 @@ function password_get_info(string $hash): ?array {}
|
|||
* The salt option has been deprecated as of PHP 7.0.0. It is now
|
||||
* preferred to simply use the salt that is generated by default.
|
||||
* </p>
|
||||
* @return string|false|null Returns the hashed password, or FALSE on failure, or null if the algorithm is invalid
|
||||
* @return string Returns the hashed password
|
||||
* @since 5.5
|
||||
*/
|
||||
function password_hash(string $password, string|int|null $algo, array $options = []): string|false|null {}
|
||||
function password_hash(string $password, string|int|null $algo, array $options = []): string {}
|
||||
|
||||
/**
|
||||
* Checks if the given hash matches the given options.
|
||||
|
|
|
@ -35,11 +35,11 @@ function bin2hex(string $string): string {}
|
|||
* @param int $seconds <p>
|
||||
* Halt time in seconds.
|
||||
* </p>
|
||||
* @return int|false zero on success, or false on errors. If the call was interrupted
|
||||
* @return int zero on success. If the call was interrupted
|
||||
* by a signal, sleep returns the number of seconds left
|
||||
* to sleep.
|
||||
*/
|
||||
function sleep(int $seconds): int|false {}
|
||||
function sleep(int $seconds): int {}
|
||||
|
||||
/**
|
||||
* Delay execution in microseconds
|
||||
|
@ -1326,7 +1326,7 @@ class php_user_filter
|
|||
* </tr>
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function filter($in, $out, &$consumed, $closing): int {}
|
||||
public function filter($in, $out, &$consumed, bool $closing): int {}
|
||||
|
||||
/**
|
||||
* @link https://php.net/manual/en/php-user-filter.oncreate.php
|
||||
|
@ -1360,28 +1360,25 @@ class Directory
|
|||
/**
|
||||
* Close directory handle.
|
||||
* Same as closedir(), only dir_handle defaults to $this.
|
||||
* @param resource $dir_handle [optional]
|
||||
* @link https://secure.php.net/manual/en/directory.close.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function close($dir_handle = null): void {}
|
||||
public function close(): void {}
|
||||
|
||||
/**
|
||||
* Rewind directory handle.
|
||||
* Same as rewinddir(), only dir_handle defaults to $this.
|
||||
* @param resource $dir_handle [optional]
|
||||
* @link https://secure.php.net/manual/en/directory.rewind.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function rewind($dir_handle = null): void {}
|
||||
public function rewind(): void {}
|
||||
|
||||
/**
|
||||
* Read entry from directory handle.
|
||||
* Same as readdir(), only dir_handle defaults to $this.
|
||||
* @param resource $dir_handle [optional]
|
||||
* @return string|false
|
||||
* @link https://secure.php.net/manual/en/directory.read.php
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function read($dir_handle = null): string|false {}
|
||||
public function read(): string|false {}
|
||||
}
|
||||
|
|
|
@ -389,20 +389,14 @@ function str_word_count(string $string, int $format = 0, ?string $characters): a
|
|||
* @param int $length [optional] <p>
|
||||
* Maximum length of the chunk.
|
||||
* </p>
|
||||
* @return string[]|false <p>If the optional split_length parameter is
|
||||
* @return string[] <p>If the optional split_length parameter is
|
||||
* specified, the returned array will be broken down into chunks with each
|
||||
* being split_length in length, otherwise each chunk
|
||||
* will be one character in length.
|
||||
* </p>
|
||||
* <p>
|
||||
* <b>FALSE</b> is returned if split_length is less than 1.
|
||||
* If the split_length length exceeds the length of
|
||||
* string, the entire string is returned as the first
|
||||
* (and only) array element.
|
||||
* </p>
|
||||
*/
|
||||
#[Pure]
|
||||
function str_split(string $string, int $length = 1): array|false {}
|
||||
function str_split(string $string, int $length = 1): array {}
|
||||
|
||||
/**
|
||||
* Search a string for any of a set of characters
|
||||
|
@ -547,10 +541,10 @@ function money_format(string $format, float $number): ?string {}
|
|||
* $rest = substr("abcdef", -3, -1); // returns "de"
|
||||
* ?>
|
||||
* </pre>
|
||||
* @return string|false the extracted part of string or false on failure.
|
||||
* @return string the extracted part of string.
|
||||
*/
|
||||
#[Pure]
|
||||
function substr(string $string, int $offset, ?int $length): string|false {}
|
||||
function substr(string $string, int $offset, ?int $length): string {}
|
||||
|
||||
/**
|
||||
* Replace text within a portion of a string
|
||||
|
@ -974,8 +968,7 @@ function similar_text(string $string1, string $string2, &$percent): int {}
|
|||
* <p>
|
||||
* If the limit parameter is zero, then this is treated as 1.
|
||||
* </p>
|
||||
* @return string[]|false If delimiter is an empty string (""),
|
||||
* explode will return false.
|
||||
* @return string[]
|
||||
* If delimiter contains a value that is not
|
||||
* contained in string and a negative
|
||||
* limit is used, then an empty array will be
|
||||
|
@ -983,7 +976,7 @@ function similar_text(string $string1, string $string2, &$percent): int {}
|
|||
* string will be returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function explode(string $separator, string $string, int $limit): array|false {}
|
||||
function explode(string $separator, string $string, int $limit): array {}
|
||||
|
||||
/**
|
||||
* Join array elements with a string
|
||||
|
@ -1089,7 +1082,7 @@ function join(array|string $separator = '', ?array $array): string {}
|
|||
* on the system that PHP is running. It returns exactly
|
||||
* what the system setlocale function returns.</p>
|
||||
*/
|
||||
function setlocale(#[ExpectedValues([LC_ALL, LC_COLLATE, LC_CTYPE, LC_MONETARY, LC_NUMERIC, LC_TIME, LC_MESSAGES])] int $category, $rest, ...$rest): string|false {}
|
||||
function setlocale(#[ExpectedValues([LC_ALL, LC_COLLATE, LC_CTYPE, LC_MONETARY, LC_NUMERIC, LC_TIME, LC_MESSAGES])] int $category, $locales, ...$rest): string|false {}
|
||||
|
||||
/**
|
||||
* Get numeric formatting information
|
||||
|
|
|
@ -228,7 +228,7 @@ function ord(string $character): int {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function parse_str(string $string, &$result = []): void {}
|
||||
function parse_str(string $string, &$result): void {}
|
||||
|
||||
/**
|
||||
* Parse a CSV string into an array
|
||||
|
@ -834,8 +834,8 @@ function proc_terminate($process, int $signal = 15): bool {}
|
|||
* The proc_open resource that will
|
||||
* be evaluated.
|
||||
* </p>
|
||||
* @return array|false An array of collected information on success, and false
|
||||
* on failure. The returned array contains the following elements:
|
||||
* @return array An array of collected information on success.
|
||||
* The returned array contains the following elements:
|
||||
* </p>
|
||||
* <p>
|
||||
* <tr valign="top"><td>element</td><td>type</td><td>description</td></tr>
|
||||
|
@ -903,7 +903,7 @@ function proc_terminate($process, int $signal = 15): bool {}
|
|||
* </tr>
|
||||
*/
|
||||
#[ArrayShape(["command" => "string", "pid" => "int", "running" => "bool", "signaled" => "bool", "stopped" => "bool", "exitcode" => "int", "termsig" => "int", "stopsig" => "int"])]
|
||||
function proc_get_status($process): array|false {}
|
||||
function proc_get_status($process): array {}
|
||||
|
||||
/**
|
||||
* Change the priority of the current process. <br/>
|
||||
|
|
|
@ -85,14 +85,14 @@ function abs(int|float $num): int|float {}
|
|||
* @param int|float $num <p>
|
||||
* The value to round
|
||||
* </p>
|
||||
* @return float|false value rounded up to the next highest
|
||||
* @return float value rounded up to the next highest
|
||||
* integer.
|
||||
* The return value of ceil is still of type
|
||||
* float as the value range of float is
|
||||
* usually bigger than that of integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function ceil(int|float $num): float|false {}
|
||||
function ceil(int|float $num): float {}
|
||||
|
||||
/**
|
||||
* Round fractions down
|
||||
|
@ -100,13 +100,13 @@ function ceil(int|float $num): float|false {}
|
|||
* @param int|float $num <p>
|
||||
* The numeric value to round
|
||||
* </p>
|
||||
* @return float|false value rounded to the next lowest integer.
|
||||
* @return float value rounded to the next lowest integer.
|
||||
* The return value of floor is still of type
|
||||
* float because the value range of float is
|
||||
* usually bigger than that of integer.
|
||||
*/
|
||||
#[Pure]
|
||||
function floor(int|float $num): float|false {}
|
||||
function floor(int|float $num): float {}
|
||||
|
||||
/**
|
||||
* Returns the rounded value of val to specified precision (number of digits after the decimal point).
|
||||
|
@ -685,6 +685,18 @@ function number_format(float $num, int $decimals = 0, ?string $decimal_separator
|
|||
#[Pure]
|
||||
function fmod(float $num1, float $num2): float {}
|
||||
|
||||
/**
|
||||
* Performs a floating-point division under
|
||||
* IEEE 754 semantics. Division by zero is considered well-defined and
|
||||
* will return one of Inf, -Inf or NaN.
|
||||
* @param float $num1
|
||||
* @param float $num2
|
||||
* @return float
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
function fdiv(float $num1, float $num2): float {}
|
||||
|
||||
/**
|
||||
* Converts a packed internet address to a human readable representation
|
||||
* @link https://php.net/manual/en/function.inet-ntop.php
|
||||
|
|
|
@ -179,12 +179,13 @@ function unserialize(string $data, array $options = []): mixed {}
|
|||
/**
|
||||
* Dumps information about a variable
|
||||
* @link https://php.net/manual/en/function.var-dump.php
|
||||
* @param mixed ...$vars <p>
|
||||
* @param mixed $value <p>
|
||||
* The variable you want to export.
|
||||
* </p>
|
||||
* @param mixed ...$values [optional]
|
||||
* @return void
|
||||
*/
|
||||
function var_dump(...$vars): void {}
|
||||
function var_dump(mixed $value, mixed ...$values): void {}
|
||||
|
||||
/**
|
||||
* Outputs or returns a parsable string representation of a variable
|
||||
|
@ -211,7 +212,7 @@ function var_export(mixed $value, bool $return = false): ?string {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function debug_zval_dump(mixed ...$values): void {}
|
||||
function debug_zval_dump(mixed $value, mixed ...$values): void {}
|
||||
|
||||
/**
|
||||
* Prints human-readable information about a variable
|
||||
|
@ -358,7 +359,7 @@ function highlight_string(string $string, bool $return = false): string|bool {}
|
|||
* Otherwise the nanoseconds are returned as integer (64bit platforms) or float (32bit platforms).
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function hrtime(bool $as_number): array|int|float|false {}
|
||||
function hrtime(bool $as_number = false): array|int|float|false {}
|
||||
|
||||
/**
|
||||
* Return source with stripped comments and whitespace
|
||||
|
|
|
@ -707,12 +707,11 @@ function fopen(string $filename, string $mode, bool $use_include_path = false, $
|
|||
* Output all remaining data on a file pointer
|
||||
* @link https://php.net/manual/en/function.fpassthru.php
|
||||
* @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 int|false If an error occurs, fpassthru returns
|
||||
* false. Otherwise, fpassthru returns
|
||||
* @return int returns
|
||||
* the number of characters read from handle
|
||||
* and passed through to the output.
|
||||
*/
|
||||
function fpassthru($stream): int|false {}
|
||||
function fpassthru($stream): int {}
|
||||
|
||||
/**
|
||||
* Truncates a file to a given length
|
||||
|
|
|
@ -605,19 +605,14 @@ function stream_supports_lock($stream): bool {}
|
|||
* @param string $escape [optional] <p>
|
||||
* Set the escape character (one character only). Defaults as a backslash.
|
||||
* </p>
|
||||
* @return array|false|null an indexed array containing the fields read.
|
||||
* @return array|false an indexed array containing the fields read.
|
||||
* <p>
|
||||
* A blank line in a CSV file will be returned as an array
|
||||
* comprising a single null field, and will not be treated
|
||||
* as an error.
|
||||
* </p>
|
||||
* <p>
|
||||
* fgetcsv returns null if an invalid
|
||||
* handle is supplied or false on other errors,
|
||||
* including end of file.
|
||||
* </p>
|
||||
*/
|
||||
function fgetcsv($stream, ?int $length = null, string $separator = ',', string $enclosure = '"', string $escape = "\\"): array|false|null {}
|
||||
function fgetcsv($stream, ?int $length = null, string $separator = ',', string $enclosure = '"', string $escape = "\\"): array|false {}
|
||||
|
||||
/**
|
||||
* Format line as CSV and write to file pointer
|
||||
|
@ -1010,7 +1005,7 @@ function stream_is_local($stream): bool {}
|
|||
* failure.
|
||||
*/
|
||||
#[Pure(true)]
|
||||
function get_headers(string $url, int $associative = false, $context = null): array|false {}
|
||||
function get_headers(string $url, bool $associative = false, $context = null): array|false {}
|
||||
|
||||
/**
|
||||
* Set timeout period on a stream
|
||||
|
|
|
@ -163,10 +163,10 @@ function pfsockopen(string $hostname, int $port = -1, &$error_code, &$error_mess
|
|||
* </p>
|
||||
* @param mixed ...$values <p>
|
||||
* </p>
|
||||
* @return string|false a binary string containing data or false if the format string contains errors
|
||||
* @return string a binary string containing data
|
||||
*/
|
||||
#[Pure]
|
||||
function pack(string $format, mixed ...$values): string|false {}
|
||||
function pack(string $format, mixed ...$values): string {}
|
||||
|
||||
/**
|
||||
* Unpack data from binary string
|
||||
|
@ -230,10 +230,10 @@ function get_browser(?string $user_agent, bool $return_array = false): object|ar
|
|||
* is generated once. If you are calling this function repeatedly, this
|
||||
* may impact both appearance and security.
|
||||
* </p>
|
||||
* @return string|null the encrypted string or <b>NULL</b> if an error occurs
|
||||
* @return string the encrypted string or <b>NULL</b> if an error occurs
|
||||
*/
|
||||
#[Pure]
|
||||
function crypt($string, $salt): ?string {}
|
||||
function crypt(string $string, string $salt): string {}
|
||||
|
||||
/**
|
||||
* Open directory handle
|
||||
|
@ -350,6 +350,16 @@ function readdir($dir_handle): string|false {}
|
|||
*/
|
||||
function dir(string $directory, $context): Directory|false {}
|
||||
|
||||
/**
|
||||
* Alias of dir()
|
||||
* @param string $directory
|
||||
* @param resource $context
|
||||
* @return Directory|false
|
||||
* @since 8.0
|
||||
* @see dir()
|
||||
*/
|
||||
function getdir(string $directory, $context = null): Directory|false {}
|
||||
|
||||
/**
|
||||
* List files and directories inside the specified path
|
||||
* @link https://php.net/manual/en/function.scandir.php
|
||||
|
|
|
@ -105,12 +105,11 @@ function getimagesizefromstring(string $string, &$image_info): array|false {}
|
|||
* Set the stream chunk size.
|
||||
* @param resource $stream The target stream.
|
||||
* @param int $size The desired new chunk size.
|
||||
* @return int|false Returns the previous chunk size on success.<br>
|
||||
* Will return <b>FALSE</b> if chunk_size is less than 1 or greater than <b>PHP_INT_MAX</b>.
|
||||
* @return int Returns the previous chunk size on success.
|
||||
* @link https://secure.php.net/manual/en/function.stream-set-chunk-size.php
|
||||
* @since 5.4
|
||||
*/
|
||||
function stream_set_chunk_size($stream, int $size): int|false {}
|
||||
function stream_set_chunk_size($stream, int $size): int {}
|
||||
|
||||
/**
|
||||
* Initializes all syslog related variables
|
||||
|
@ -131,10 +130,10 @@ function define_syslog_variables() {}
|
|||
* This parameter restricts the returned metaphone key to phonemes characters in length.
|
||||
* The default value of 0 means no restriction.
|
||||
* </p>
|
||||
* @return string|false the metaphone key as a string, or FALSE on failure
|
||||
* @return string the metaphone key as a string
|
||||
*/
|
||||
#[Pure]
|
||||
function metaphone(string $string, int $max_phonemes = 0): string|false {}
|
||||
function metaphone(string $string, int $max_phonemes = 0): string {}
|
||||
|
||||
/**
|
||||
* Turn on output buffering
|
||||
|
@ -356,7 +355,7 @@ function ob_get_contents(): string|false {}
|
|||
* </p>
|
||||
* @return void
|
||||
*/
|
||||
function ob_implicit_flush(int $enable = true): void {}
|
||||
function ob_implicit_flush(bool $enable = true): void {}
|
||||
|
||||
/**
|
||||
* List all output handlers in use
|
||||
|
@ -725,7 +724,7 @@ function key(object|array $array): string|int|null {}
|
|||
* parameter values.
|
||||
*/
|
||||
#[Pure]
|
||||
function min(mixed ...$values): mixed {}
|
||||
function min(mixed $value, mixed ...$values): mixed {}
|
||||
|
||||
/**
|
||||
* Find highest value
|
||||
|
@ -736,7 +735,7 @@ function min(mixed ...$values): mixed {}
|
|||
* parameter values, either within a arg array or two arguments.
|
||||
*/
|
||||
#[Pure]
|
||||
function max(mixed ...$values): mixed {}
|
||||
function max(mixed $value, mixed ...$values): mixed {}
|
||||
|
||||
/**
|
||||
* Checks if a value exists in an array
|
||||
|
@ -836,7 +835,7 @@ function extract(array &$array, #[ExpectedValues([EXTR_OVERWRITE, EXTR_SKIP, EXT
|
|||
* @return array the output array with all the variables added to it.
|
||||
*/
|
||||
#[Pure]
|
||||
function compact(...$var_names): array {}
|
||||
function compact($var_name, ...$var_names): array {}
|
||||
|
||||
/**
|
||||
* Fill an array with values
|
||||
|
@ -905,7 +904,7 @@ function range($start, $end, int|float $step = 1): array {}
|
|||
* </p>
|
||||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
function array_multisort(&$array, $sort_order = SORT_ASC, $sort_flags = SORT_REGULAR, &...$rest): bool {}
|
||||
function array_multisort(&$array, &...$rest): bool {}
|
||||
|
||||
/**
|
||||
* Push elements onto the end of array
|
||||
|
|
|
@ -299,7 +299,7 @@ function array_intersect_key(array $array, array ...$arrays): array {}
|
|||
* in all the arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_intersect_ukey(array $array, array $array2, callable $key_compare_func): array {}
|
||||
function array_intersect_ukey(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays, compares data by a callback function
|
||||
|
@ -324,7 +324,7 @@ function array_intersect_ukey(array $array, array $array2, callable $key_compare
|
|||
* that are present in all the arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_uintersect(array $array, array $array2, callable $data_compare_func): array {}
|
||||
function array_uintersect(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays with additional index check
|
||||
|
@ -361,7 +361,7 @@ function array_intersect_assoc(array $array, array ...$arrays): array {}
|
|||
* array1 that are present in all the arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_uintersect_assoc(array $array, array $array2, callable $data_compare_func): array {}
|
||||
function array_uintersect_assoc(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays with additional index check, compares indexes by a callback function
|
||||
|
@ -380,7 +380,7 @@ function array_uintersect_assoc(array $array, array $array2, callable $data_comp
|
|||
* in all of the arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_intersect_uassoc(array $array, array $array2, callable $key_compare_func): array {}
|
||||
function array_intersect_uassoc(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Computes the intersection of arrays with additional index check, compares data and indexes by separate callback functions
|
||||
|
@ -407,7 +407,7 @@ function array_intersect_uassoc(array $array, array $array2, callable $key_compa
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_uintersect_uassoc(array $array, array $array2, callable $data_compare_func, callable $key_compare_func): array {}
|
||||
function array_uintersect_uassoc(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays
|
||||
|
@ -460,7 +460,7 @@ function array_diff_key(array $array, array ...$arrays): array {}
|
|||
* array1 that are not present in any of the other arrays.
|
||||
* @meta
|
||||
*/
|
||||
function array_diff_ukey(array $array, array $array2, callable $key_compare_func): array {}
|
||||
function array_diff_ukey(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays by using a callback function for data comparison
|
||||
|
@ -485,7 +485,7 @@ function array_diff_ukey(array $array, array $array2, callable $key_compare_func
|
|||
* that are not present in any of the other arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_udiff(array $array, array $array2, callable $data_compare_func): array {}
|
||||
function array_udiff(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays with additional index check
|
||||
|
@ -533,7 +533,7 @@ function array_diff_assoc(array $array, array ...$arrays): array {}
|
|||
* comparison.
|
||||
* @meta
|
||||
*/
|
||||
function array_udiff_assoc(array $array, array $array2, callable $data_compare_func): array {}
|
||||
function array_udiff_assoc(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays with additional index check which is performed by a user supplied callback function
|
||||
|
@ -555,7 +555,7 @@ function array_udiff_assoc(array $array, array $array2, callable $data_compare_f
|
|||
* array1 that are not present in any of the other arrays.
|
||||
* @meta
|
||||
*/
|
||||
function array_diff_uassoc(array $array, array $array2, callable $key_compare_func): array {}
|
||||
function array_diff_uassoc(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Computes the difference of arrays with additional index check, compares data and indexes by a callback function
|
||||
|
@ -594,7 +594,7 @@ function array_diff_uassoc(array $array, array $array2, callable $key_compare_fu
|
|||
* arguments.
|
||||
* @meta
|
||||
*/
|
||||
function array_udiff_uassoc(array $array, array $array2, callable $data_compare_func, callable $key_compare_func): array {}
|
||||
function array_udiff_uassoc(array $array, ...$rest): array {}
|
||||
|
||||
/**
|
||||
* Calculate the sum of values in an array
|
||||
|
@ -668,7 +668,7 @@ function array_filter(array $array, ?callable $callback, int $mode = 0): array {
|
|||
* after applying the callback function to each one.
|
||||
* @meta
|
||||
*/
|
||||
function array_map(?callable $callback, array ...$arrays): array {}
|
||||
function array_map(?callable $callback, array $array, array ...$arrays): array {}
|
||||
|
||||
/**
|
||||
* Split an array into chunks
|
||||
|
@ -704,7 +704,7 @@ function array_chunk(array $array, int $length, bool $preserve_keys = false): ar
|
|||
* @meta
|
||||
*/
|
||||
#[Pure]
|
||||
function array_combine(array $keys, array $values): array|false {}
|
||||
function array_combine(array $keys, array $values): array {}
|
||||
|
||||
/**
|
||||
* Checks if the given key or index exists in the array
|
||||
|
@ -718,7 +718,7 @@ function array_combine(array $keys, array $values): array|false {}
|
|||
* @return bool true on success or false on failure.
|
||||
*/
|
||||
#[Pure]
|
||||
function array_key_exists($key, array|ArrayObject $array): bool {}
|
||||
function array_key_exists($key, array $array): bool {}
|
||||
|
||||
/**
|
||||
* Gets the first key of an array
|
||||
|
@ -1158,6 +1158,36 @@ function realpath_cache_size(): int {}
|
|||
*/
|
||||
function get_mangled_object_vars(object $object): array {}
|
||||
|
||||
/**
|
||||
* Get the type or object name of a variable
|
||||
*
|
||||
* @param mixed $value The variable being type checked.
|
||||
* @return string Possibles values for the returned string are:
|
||||
* - "int"
|
||||
* - "float"
|
||||
* - "bool"
|
||||
* - "string"
|
||||
* - "array"
|
||||
* - "null"
|
||||
* - A class name for named classes
|
||||
* - "class@anonymous" for an anonymous classes
|
||||
* - "resource (xxx)" for any resources where "xxx" is a name of resource
|
||||
* - "resource (closed)" for closed resources
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
function get_debug_type(mixed $value): string {}
|
||||
|
||||
/**
|
||||
* A more obvious and type-safe form of "(int) $resource"
|
||||
*
|
||||
* @param resource $resource
|
||||
* @return int
|
||||
* @since 8.0
|
||||
*/
|
||||
#[Pure]
|
||||
function get_resource_id($resource): int {}
|
||||
|
||||
/**
|
||||
* AssertionError is thrown when an assertion made via {@see assert()} fails.
|
||||
* @link https://php.net/manual/en/class.assertionerror.php
|
||||
|
|
|
@ -22,14 +22,14 @@ define('MSG_EXCEPT', 4);
|
|||
* Queue permissions. Default to 0666. If the message queue already
|
||||
* exists, the <i>perms</i> will be ignored.
|
||||
* </p>
|
||||
* @return resource|SysvMessageQueue|false a resource handle that can be used to access the System V message queue.
|
||||
* @return SysvMessageQueue|false a resource handle that can be used to access the System V message queue.
|
||||
*/
|
||||
function msg_get_queue(int $key, int $permissions = 438) {}
|
||||
function msg_get_queue(int $key, int $permissions = 438): SysvMessageQueue|false {}
|
||||
|
||||
/**
|
||||
* Send a message to a message queue
|
||||
* @link https://php.net/manual/en/function.msg-send.php
|
||||
* @param SysvMessageQueue|resource $queue
|
||||
* @param SysvMessageQueue $queue
|
||||
* @param int $message_type
|
||||
* @param mixed $message
|
||||
* @param bool $serialize [optional] <p>
|
||||
|
@ -62,7 +62,7 @@ function msg_get_queue(int $key, int $permissions = 438) {}
|
|||
* <i>msg_stime</i> is set to the current time.
|
||||
* </p>
|
||||
*/
|
||||
function msg_send($queue, int $message_type, $message, bool $serialize = true, bool $blocking = true, &$error_code): bool {}
|
||||
function msg_send(SysvMessageQueue $queue, int $message_type, $message, bool $serialize = true, bool $blocking = true, &$error_code): bool {}
|
||||
|
||||
/**
|
||||
* Receive a message from a message queue
|
||||
|
@ -149,7 +149,7 @@ function msg_send($queue, int $message_type, $message, bool $serialize = true, b
|
|||
* msg_rtime is set to the current time.
|
||||
* </p>
|
||||
*/
|
||||
function msg_receive($queue, int $desired_message_type, &$received_message_type, int $max_message_size, mixed &$message, bool $unserialize = true, int $flags = 0, &$error_code): bool {}
|
||||
function msg_receive(SysvMessageQueue $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
|
||||
|
@ -159,7 +159,7 @@ function msg_receive($queue, int $desired_message_type, &$received_message_type,
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function msg_remove_queue($queue): bool {}
|
||||
function msg_remove_queue(SysvMessageQueue $queue): bool {}
|
||||
|
||||
/**
|
||||
* Returns information from the message queue data structure
|
||||
|
@ -236,7 +236,7 @@ function msg_remove_queue($queue): bool {}
|
|||
* </table>
|
||||
*/
|
||||
#[ArrayShape(["msg_perm.uid" => "int", "msg_perm.gid" => "int", "msg_perm.mode" => "int", "msg_stime" => "int", "msg_rtime" => "int", "msg_ctime" => "int", "msg_qnum" => "int", "msg_qbytes" => "int", "msg_lspid" => "int", "msg_lrpid" => "int"])]
|
||||
function msg_stat_queue($queue): array|false {}
|
||||
function msg_stat_queue(SysvMessageQueue $queue): array|false {}
|
||||
|
||||
/**
|
||||
* Set information in the message queue data structure
|
||||
|
@ -250,7 +250,7 @@ function msg_stat_queue($queue): array|false {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function msg_set_queue($queue, array $data): bool {}
|
||||
function msg_set_queue(SysvMessageQueue $queue, array $data): bool {}
|
||||
|
||||
/**
|
||||
* Check whether a message queue exists
|
||||
|
@ -261,3 +261,15 @@ function msg_set_queue($queue, array $data): bool {}
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function msg_queue_exists(int $key): bool {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class SysvMessageQueue
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct SysvMessageQueue, use msg_get_queue() instead
|
||||
* @see msg_get_queue()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
* @return resource|false|SysvSemaphore a positive semaphore identifier on success, or <b>FALSE</b> on
|
||||
* error.
|
||||
*/
|
||||
function sem_get(int $key, int $max_acquire = 1, int $permissions = 438, bool $auto_release = true) {}
|
||||
function sem_get(int $key, int $max_acquire = 1, int $permissions = 438, bool $auto_release = true): SysvSemaphore|false {}
|
||||
|
||||
/**
|
||||
* Acquire a semaphore
|
||||
|
@ -36,7 +36,7 @@ function sem_get(int $key, int $max_acquire = 1, int $permissions = 438, bool $a
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function sem_acquire($semaphore, bool $non_blocking = false): bool {}
|
||||
function sem_acquire(SysvSemaphore $semaphore, bool $non_blocking = false): bool {}
|
||||
|
||||
/**
|
||||
* Release a semaphore
|
||||
|
@ -47,7 +47,7 @@ function sem_acquire($semaphore, bool $non_blocking = false): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function sem_release($semaphore): bool {}
|
||||
function sem_release(SysvSemaphore $semaphore): bool {}
|
||||
|
||||
/**
|
||||
* Remove a semaphore
|
||||
|
@ -58,4 +58,16 @@ function sem_release($semaphore): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function sem_remove($semaphore): bool {}
|
||||
function sem_remove(SysvSemaphore $semaphore): bool {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class SysvSemaphore
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct SysvSemaphore, use sem_get() instead
|
||||
* @see sem_get()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
|
|
@ -14,9 +14,9 @@
|
|||
* @param int $permissions [optional] <p>
|
||||
* The optional permission bits. Default to 0666.
|
||||
* </p>
|
||||
* @return resource|SysvSharedMemory|false a shared memory segment identifier.
|
||||
* @return SysvSharedMemory|false a shared memory segment identifier.
|
||||
*/
|
||||
function shm_attach(int $key, ?int $size, int $permissions = 438) {}
|
||||
function shm_attach(int $key, ?int $size, int $permissions = 438): SysvSharedMemory|false {}
|
||||
|
||||
/**
|
||||
* Removes shared memory from Unix systems
|
||||
|
@ -27,7 +27,7 @@ function shm_attach(int $key, ?int $size, int $permissions = 438) {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function shm_remove($shm): bool {}
|
||||
function shm_remove(SysvSharedMemory $shm): bool {}
|
||||
|
||||
/**
|
||||
* Disconnects from shared memory segment
|
||||
|
@ -38,7 +38,7 @@ function shm_remove($shm): bool {}
|
|||
* </p>
|
||||
* @return bool <b>shm_detach</b> always returns <b>TRUE</b>.
|
||||
*/
|
||||
function shm_detach($shm): bool {}
|
||||
function shm_detach(SysvSharedMemory $shm): bool {}
|
||||
|
||||
/**
|
||||
* Inserts or updates a variable in shared memory
|
||||
|
@ -58,7 +58,7 @@ function shm_detach($shm): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function shm_put_var($shm, int $key, mixed $value): bool {}
|
||||
function shm_put_var(SysvSharedMemory $shm, int $key, mixed $value): bool {}
|
||||
|
||||
/**
|
||||
* Check whether a specific entry exists
|
||||
|
@ -71,7 +71,7 @@ function shm_put_var($shm, int $key, mixed $value): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> if the entry exists, otherwise <b>FALSE</b>
|
||||
*/
|
||||
function shm_has_var($shm, int $key): bool {}
|
||||
function shm_has_var(SysvSharedMemory $shm, int $key): bool {}
|
||||
|
||||
/**
|
||||
* Returns a variable from shared memory
|
||||
|
@ -84,7 +84,7 @@ function shm_has_var($shm, int $key): bool {}
|
|||
* </p>
|
||||
* @return mixed the variable with the given key.
|
||||
*/
|
||||
function shm_get_var($shm, int $key): mixed {}
|
||||
function shm_get_var(SysvSharedMemory $shm, int $key): mixed {}
|
||||
|
||||
/**
|
||||
* Removes a variable from shared memory
|
||||
|
@ -98,4 +98,16 @@ function shm_get_var($shm, int $key): mixed {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function shm_remove_var($shm, int $key): bool {}
|
||||
function shm_remove_var(SysvSharedMemory $shm, int $key): bool {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class SysvSharedMemory
|
||||
{
|
||||
/**
|
||||
* Cannot directly construct SysvSharedMemory, use shm_attach() instead
|
||||
* @see shm_attach()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,76 @@
|
|||
<?php
|
||||
/**
|
||||
* A class for working with PHP tokens, which is an alternative to
|
||||
* the {@see token_get_all()} function.
|
||||
*
|
||||
* @since 8.0
|
||||
*/
|
||||
class PhpToken implements Stringable
|
||||
{
|
||||
/**
|
||||
* One of the T_* constants, or an integer < 256 representing a
|
||||
* single-char token.
|
||||
*/
|
||||
public int $id;
|
||||
|
||||
/**
|
||||
* The textual content of the token.
|
||||
*/
|
||||
public string $text;
|
||||
|
||||
/**
|
||||
* The starting line number (1-based) of the token.
|
||||
*/
|
||||
public int $line;
|
||||
|
||||
/**
|
||||
* The starting position (0-based) in the tokenized string.
|
||||
*/
|
||||
public int $pos;
|
||||
|
||||
/**
|
||||
* @param int $id An integer identifier
|
||||
* @param string $text Textual content
|
||||
* @param int $line Strating line
|
||||
* @param int $pos Straring position (line offset)
|
||||
*/
|
||||
final public function __construct(int $id, string $text, int $line = -1, int $pos = -1) {}
|
||||
|
||||
/**
|
||||
* Same as {@see token_get_all()}, but returning array of {@see PhpToken}
|
||||
* or an instance of a child class.
|
||||
*
|
||||
* @param string $code An a PHP source code
|
||||
* @param int $flags
|
||||
* @return static[]
|
||||
*/
|
||||
public static function tokenize(string $code, int $flags = 0): array {}
|
||||
|
||||
/**
|
||||
* Get the name of the token.
|
||||
*
|
||||
* @return string|null
|
||||
*/
|
||||
public function getTokenName(): ?string {}
|
||||
|
||||
/**
|
||||
* Whether the token has the given ID, the given text, or has an ID/text
|
||||
* part of the given array.
|
||||
*
|
||||
* @param int|string|array $kind
|
||||
* @return bool
|
||||
*/
|
||||
public function is($kind): bool {}
|
||||
|
||||
/**
|
||||
* Whether this token would be ignored by the PHP parser.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function isIgnorable(): bool {}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function __toString(): string {}
|
||||
}
|
|
@ -289,6 +289,31 @@ define('T_FN', 311);
|
|||
*/
|
||||
define('T_BAD_CHARACTER', 405);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('T_NAME_FULLY_QUALIFIED', 263);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('T_NAME_RELATIVE', 264);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('T_NAME_QUALIFIED', 265);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('T_ATTRIBUTE', 351);
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
define('T_NULLSAFE_OBJECT_OPERATOR', 385);
|
||||
|
||||
/**
|
||||
* @removed 7.0
|
||||
*/
|
||||
|
|
51
xml/xml.php
51
xml/xml.php
|
@ -77,10 +77,10 @@ define('XML_SAX_IMPL', "libxml");
|
|||
* encodings are ISO-8859-1, UTF-8 and
|
||||
* US-ASCII.
|
||||
* </p>
|
||||
* @return resource|false|XMLParser a resource handle for the new XML parser.
|
||||
* @return XMLParser a resource handle for the new XML parser.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_parser_create(?string $encoding) {}
|
||||
function xml_parser_create(?string $encoding): XMLParser {}
|
||||
|
||||
/**
|
||||
* Create an XML parser with namespace support
|
||||
|
@ -101,10 +101,10 @@ function xml_parser_create(?string $encoding) {}
|
|||
* handler functions will consist of namespace and tag name separated by
|
||||
* the string specified in <i>separator</i>.
|
||||
* </p>
|
||||
* @return resource|false|XMLParser a resource handle for the new XML parser.
|
||||
* @return XMLParser a resource handle for the new XML parser.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_parser_create_ns(?string $encoding, string $separator = ':') {}
|
||||
function xml_parser_create_ns(?string $encoding, string $separator = ':'): XMLParser {}
|
||||
|
||||
/**
|
||||
* Use XML Parser within an object
|
||||
|
@ -117,7 +117,7 @@ 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($parser, object $object): bool {}
|
||||
function xml_set_object(XMLParser $parser, object $object): bool {}
|
||||
|
||||
/**
|
||||
* Set up start and end element handlers
|
||||
|
@ -146,7 +146,7 @@ function xml_set_object($parser, object $object): bool {}
|
|||
* reference to the XML parser calling the handler.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_element_handler($parser, $start_handler, $end_handler): bool {}
|
||||
function xml_set_element_handler(XMLParser $parser, $start_handler, $end_handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up character data handler
|
||||
|
@ -170,7 +170,7 @@ function xml_set_element_handler($parser, $start_handler, $end_handler): bool {}
|
|||
* reference to the XML parser calling the handler.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_character_data_handler($parser, $handler): bool {}
|
||||
function xml_set_character_data_handler(XMLParser $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up processing instruction (PI) handler
|
||||
|
@ -195,7 +195,7 @@ function xml_set_character_data_handler($parser, $handler): bool {}
|
|||
* reference to the XML parser calling the handler.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_processing_instruction_handler($parser, $handler): bool {}
|
||||
function xml_set_processing_instruction_handler(XMLParser $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up default handler
|
||||
|
@ -219,7 +219,7 @@ function xml_set_processing_instruction_handler($parser, $handler): bool {}
|
|||
* reference to the XML parser calling the handler.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_default_handler($parser, $handler): bool {}
|
||||
function xml_set_default_handler(XMLParser $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up unparsed entity declaration handler
|
||||
|
@ -248,7 +248,7 @@ function xml_set_default_handler($parser, $handler): bool {}
|
|||
* handler.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_unparsed_entity_decl_handler($parser, $handler): bool {}
|
||||
function xml_set_unparsed_entity_decl_handler(XMLParser $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up notation declaration handler
|
||||
|
@ -275,7 +275,7 @@ function xml_set_unparsed_entity_decl_handler($parser, $handler): bool {}
|
|||
* reference to the XML parser calling the handler.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_notation_decl_handler($parser, $handler): bool {}
|
||||
function xml_set_notation_decl_handler(XMLParser $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up external entity reference handler
|
||||
|
@ -306,7 +306,7 @@ function xml_set_notation_decl_handler($parser, $handler): bool {}
|
|||
* reference to the XML parser calling the handler.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_external_entity_ref_handler($parser, $handler): bool {}
|
||||
function xml_set_external_entity_ref_handler(XMLParser $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up start namespace declaration handler
|
||||
|
@ -335,7 +335,7 @@ function xml_set_external_entity_ref_handler($parser, $handler): bool {}
|
|||
* reference to the XML parser calling the handler.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_start_namespace_decl_handler($parser, $handler): bool {}
|
||||
function xml_set_start_namespace_decl_handler(XMLParser $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Set up end namespace declaration handler
|
||||
|
@ -363,7 +363,7 @@ function xml_set_start_namespace_decl_handler($parser, $handler): bool {}
|
|||
* reference to the XML parser calling the handler.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xml_set_end_namespace_decl_handler($parser, $handler): bool {}
|
||||
function xml_set_end_namespace_decl_handler(XMLParser $parser, $handler): bool {}
|
||||
|
||||
/**
|
||||
* Start parsing an XML document
|
||||
|
@ -395,7 +395,7 @@ function xml_set_end_namespace_decl_handler($parser, $handler): bool {}
|
|||
* <i>is_final</i> is set and <b>TRUE</b>.
|
||||
* </p>
|
||||
*/
|
||||
function xml_parse($parser, string $data, bool $is_final = false): int {}
|
||||
function xml_parse(XMLParser $parser, string $data, bool $is_final = false): int {}
|
||||
|
||||
/**
|
||||
* Parse XML data into an array structure
|
||||
|
@ -416,7 +416,7 @@ function xml_parse($parser, string $data, bool $is_final = false): int {}
|
|||
* 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($parser, string $data, &$values, &$index): int {}
|
||||
function xml_parse_into_struct(XMLParser $parser, string $data, &$values, &$index): int {}
|
||||
|
||||
/**
|
||||
* Get XML parser error code
|
||||
|
@ -428,7 +428,7 @@ function xml_parse_into_struct($parser, string $data, &$values, &$index): int {}
|
|||
* section.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_get_error_code($parser): int|false {}
|
||||
function xml_get_error_code(XMLParser $parser): int {}
|
||||
|
||||
/**
|
||||
* Get XML parser error string
|
||||
|
@ -453,7 +453,7 @@ function xml_error_string(int $error_code): ?string {}
|
|||
* parser is currently at in its data buffer.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_get_current_line_number($parser): int|false {}
|
||||
function xml_get_current_line_number(XMLParser $parser): int {}
|
||||
|
||||
/**
|
||||
* Get current column number for an XML parser
|
||||
|
@ -468,7 +468,7 @@ function xml_get_current_line_number($parser): int|false {}
|
|||
* currently at.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_get_current_column_number($parser): int|false {}
|
||||
function xml_get_current_column_number(XMLParser $parser): int {}
|
||||
|
||||
/**
|
||||
* Get current byte index for an XML parser
|
||||
|
@ -481,7 +481,7 @@ function xml_get_current_column_number($parser): int|false {}
|
|||
* the parser is currently at in its data buffer (starting at 0).
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_get_current_byte_index($parser): int|false {}
|
||||
function xml_get_current_byte_index(XMLParser $parser): int {}
|
||||
|
||||
/**
|
||||
* Free an XML parser
|
||||
|
@ -490,7 +490,7 @@ function xml_get_current_byte_index($parser): int|false {}
|
|||
* @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($parser): bool {}
|
||||
function xml_parser_free(XMLParser $parser): bool {}
|
||||
|
||||
/**
|
||||
* Set options in an XML parser
|
||||
|
@ -553,7 +553,7 @@ function xml_parser_free($parser): bool {}
|
|||
* 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($parser, int $option, $value): bool {}
|
||||
function xml_parser_set_option(XMLParser $parser, int $option, $value): bool {}
|
||||
|
||||
/**
|
||||
* Get options from an XML parser
|
||||
|
@ -568,4 +568,9 @@ function xml_parser_set_option($parser, int $option, $value): bool {}
|
|||
* Else the option's value is returned.
|
||||
*/
|
||||
#[Pure]
|
||||
function xml_parser_get_option($parser, int $option): string|int {}
|
||||
function xml_parser_get_option(XMLParser $parser, int $option): string|int {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class XMLParser {}
|
||||
|
|
|
@ -152,7 +152,7 @@ class XMLReader
|
|||
* <b>XMLReader</b> or <b>FALSE</b> on failure.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
public static function open($uri, $encoding = null, $flags = 0) {}
|
||||
public static function open(string $uri, string|null $encoding = null, int $flags = 0) {}
|
||||
|
||||
/**
|
||||
* Set the data containing the XML to parse
|
||||
|
@ -171,7 +171,7 @@ class XMLReader
|
|||
* <b>XMLReader</b> or <b>FALSE</b> on failure.
|
||||
* @since 5.1.2
|
||||
*/
|
||||
public static function XML($source, $encoding = null, $flags = 0) {}
|
||||
public static function XML(string $source, string|null $encoding = null, int $flags = 0) {}
|
||||
|
||||
/**
|
||||
* Close the XMLReader input
|
||||
|
@ -192,7 +192,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getAttribute($name): ?string {}
|
||||
public function getAttribute(string $name): ?string {}
|
||||
|
||||
/**
|
||||
* Get the value of an attribute by index
|
||||
|
@ -205,7 +205,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getAttributeNo($index): ?string {}
|
||||
public function getAttributeNo(int $index): ?string {}
|
||||
|
||||
/**
|
||||
* Get the value of an attribute by localname and URI
|
||||
|
@ -222,7 +222,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getAttributeNs($name, $namespace): ?string {}
|
||||
public function getAttributeNs(string $name, string $namespace): ?string {}
|
||||
|
||||
/**
|
||||
* Indicates if specified property has been set
|
||||
|
@ -235,7 +235,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function getParserProperty($property): bool {}
|
||||
public function getParserProperty(int $property): bool {}
|
||||
|
||||
/**
|
||||
* Indicates if the parsed document is valid
|
||||
|
@ -256,7 +256,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function lookupNamespace($prefix): ?string {}
|
||||
public function lookupNamespace(string $prefix): ?string {}
|
||||
|
||||
/**
|
||||
* Move cursor to an attribute by index
|
||||
|
@ -268,7 +268,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function moveToAttributeNo($index): bool {}
|
||||
public function moveToAttributeNo(int $index): bool {}
|
||||
|
||||
/**
|
||||
* Move cursor to a named attribute
|
||||
|
@ -280,7 +280,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function moveToAttribute($name): bool {}
|
||||
public function moveToAttribute(string $name): bool {}
|
||||
|
||||
/**
|
||||
* Move cursor to a named attribute
|
||||
|
@ -295,7 +295,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function moveToAttributeNs($name, $namespace): bool {}
|
||||
public function moveToAttributeNs(string $name, string $namespace): bool {}
|
||||
|
||||
/**
|
||||
* Position cursor on the parent Element of current Attribute
|
||||
|
@ -344,7 +344,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function next($name = null): bool {}
|
||||
public function next(string|null $name = null): bool {}
|
||||
|
||||
/**
|
||||
* Retrieve XML from current node
|
||||
|
@ -380,7 +380,7 @@ class XMLReader
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setSchema($filename): bool {}
|
||||
public function setSchema(string|null $filename): bool {}
|
||||
|
||||
/**
|
||||
* Set parser options
|
||||
|
@ -397,7 +397,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setParserProperty($property, $value): bool {}
|
||||
public function setParserProperty(int $property, bool $value): bool {}
|
||||
|
||||
/**
|
||||
* Set the filename or URI for a RelaxNG Schema
|
||||
|
@ -408,7 +408,7 @@ class XMLReader
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setRelaxNGSchema($filename): bool {}
|
||||
public function setRelaxNGSchema(string|null $filename): bool {}
|
||||
|
||||
/**
|
||||
* Set the data containing a RelaxNG Schema
|
||||
|
@ -420,7 +420,7 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setRelaxNGSchemaSource($source): bool {}
|
||||
public function setRelaxNGSchemaSource(string|null $source): bool {}
|
||||
|
||||
/**
|
||||
* Returns a copy of the current node as a DOM object
|
||||
|
@ -430,5 +430,5 @@ class XMLReader
|
|||
* @since 5.1.2
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function expand($baseNode = null): DOMNode|false {}
|
||||
public function expand(DOMNode|null $baseNode = null): DOMNode|false {}
|
||||
}
|
||||
|
|
|
@ -9,25 +9,25 @@ use JetBrains\PhpStorm\Internal\TentativeType;
|
|||
* @param string $uri <p>
|
||||
* The URI of the resource for the output.
|
||||
* </p>
|
||||
* @return false|resource|XMLWriter Object oriented style: Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @return false|XMLWriter Object oriented style: Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* <p>
|
||||
* Procedural style: Returns a new xmlwriter resource for later use with the
|
||||
* xmlwriter functions on success, <b>FALSE</b> on error.
|
||||
* </p>
|
||||
*/
|
||||
function xmlwriter_open_uri(string $uri) {}
|
||||
function xmlwriter_open_uri(string $uri): XMLWriter|false {}
|
||||
|
||||
/**
|
||||
* (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-openmemory.php
|
||||
* @return XMLWriter|false|resource Object oriented style: Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* @return XMLWriter|false Object oriented style: Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
* <p>
|
||||
* Procedural style: Returns a new xmlwriter resource for later use with the
|
||||
* xmlwriter functions on success, <b>FALSE</b> on error.
|
||||
* </p>
|
||||
*/
|
||||
function xmlwriter_open_memory() {}
|
||||
function xmlwriter_open_memory(): XMLWriter|false {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -43,7 +43,7 @@ function xmlwriter_open_memory() {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_set_indent($writer, bool $enable): bool {}
|
||||
function xmlwriter_set_indent(XMLWriter $writer, bool $enable): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -59,7 +59,7 @@ function xmlwriter_set_indent($writer, bool $enable): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_set_indent_string($writer, string $indentation): bool {}
|
||||
function xmlwriter_set_indent_string(XMLWriter $writer, string $indentation): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 1.0.0)<br/>
|
||||
|
@ -72,7 +72,7 @@ function xmlwriter_set_indent_string($writer, string $indentation): bool {}
|
|||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_comment($writer): bool {}
|
||||
function xmlwriter_start_comment(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 1.0.0)<br/>
|
||||
|
@ -85,7 +85,7 @@ function xmlwriter_start_comment($writer): bool {}
|
|||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_comment($writer): bool {}
|
||||
function xmlwriter_end_comment(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -101,7 +101,7 @@ function xmlwriter_end_comment($writer): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_attribute($writer, string $name): bool {}
|
||||
function xmlwriter_start_attribute(XMLWriter $writer, string $name): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -113,7 +113,7 @@ function xmlwriter_start_attribute($writer, string $name): bool {}
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-openuri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_attribute($writer): bool {}
|
||||
function xmlwriter_end_attribute(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -132,7 +132,7 @@ function xmlwriter_end_attribute($writer): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_attribute($writer, string $name, string $value): bool {}
|
||||
function xmlwriter_write_attribute(XMLWriter $writer, string $name, string $value): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -154,7 +154,7 @@ function xmlwriter_write_attribute($writer, string $name, string $value): bool {
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_attribute_ns($writer, ?string $prefix, string $name, ?string $namespace): bool {}
|
||||
function xmlwriter_start_attribute_ns(XMLWriter $writer, ?string $prefix, string $name, ?string $namespace): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -179,7 +179,7 @@ function xmlwriter_start_attribute_ns($writer, ?string $prefix, string $name, ?s
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_attribute_ns($writer, ?string $prefix, string $name, ?string $namespace, string $value): bool {}
|
||||
function xmlwriter_write_attribute_ns(XMLWriter $writer, ?string $prefix, string $name, ?string $namespace, string $value): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -195,7 +195,7 @@ function xmlwriter_write_attribute_ns($writer, ?string $prefix, string $name, ?s
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_element($writer, string $name): bool {}
|
||||
function xmlwriter_start_element(XMLWriter $writer, string $name): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -207,7 +207,7 @@ function xmlwriter_start_element($writer, string $name): bool {}
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-openuri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_element($writer): bool {}
|
||||
function xmlwriter_end_element(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL xmlwriter >= 2.0.4)<br/>
|
||||
|
@ -219,7 +219,7 @@ function xmlwriter_end_element($writer): bool {}
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-openuri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_full_end_element($writer): bool {}
|
||||
function xmlwriter_full_end_element(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -241,7 +241,7 @@ function xmlwriter_full_end_element($writer): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_element_ns($writer, ?string $prefix, string $name, ?string $namespace): bool {}
|
||||
function xmlwriter_start_element_ns(XMLWriter $writer, ?string $prefix, string $name, ?string $namespace): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -260,7 +260,7 @@ function xmlwriter_start_element_ns($writer, ?string $prefix, string $name, ?str
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_element($writer, string $name, ?string $content): bool {}
|
||||
function xmlwriter_write_element(XMLWriter $writer, string $name, ?string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -285,7 +285,7 @@ function xmlwriter_write_element($writer, string $name, ?string $content): bool
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_element_ns($writer, ?string $prefix, string $name, ?string $namespace, ?string $content): bool {}
|
||||
function xmlwriter_write_element_ns(XMLWriter $writer, ?string $prefix, string $name, ?string $namespace, ?string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -301,7 +301,7 @@ function xmlwriter_write_element_ns($writer, ?string $prefix, string $name, ?str
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_pi($writer, string $target): bool {}
|
||||
function xmlwriter_start_pi(XMLWriter $writer, string $target): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -313,7 +313,7 @@ function xmlwriter_start_pi($writer, string $target): bool {}
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-openuri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_pi($writer): bool {}
|
||||
function xmlwriter_end_pi(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -333,7 +333,7 @@ function xmlwriter_end_pi($writer): bool {}
|
|||
*
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_pi($writer, string $target, string $content): bool {}
|
||||
function xmlwriter_write_pi(XMLWriter $writer, string $target, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -346,7 +346,7 @@ function xmlwriter_write_pi($writer, string $target, string $content): bool {}
|
|||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_cdata($writer): bool {}
|
||||
function xmlwriter_start_cdata(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -359,7 +359,7 @@ function xmlwriter_start_cdata($writer): bool {}
|
|||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_cdata($writer): bool {}
|
||||
function xmlwriter_end_cdata(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -375,7 +375,7 @@ function xmlwriter_end_cdata($writer): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_cdata($writer, string $content): bool {}
|
||||
function xmlwriter_write_cdata(XMLWriter $writer, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -391,7 +391,7 @@ function xmlwriter_write_cdata($writer, string $content): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_text($writer, string $content): bool {}
|
||||
function xmlwriter_text(XMLWriter $writer, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL xmlwriter >= 2.0.4)<br/>
|
||||
|
@ -407,7 +407,7 @@ function xmlwriter_text($writer, string $content): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_raw($writer, string $content): bool {}
|
||||
function xmlwriter_write_raw(XMLWriter $writer, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -429,7 +429,7 @@ function xmlwriter_write_raw($writer, string $content): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_document($writer, ?string $version = '1.0', ?string $encoding, ?string $standalone): bool {}
|
||||
function xmlwriter_start_document(XMLWriter $writer, ?string $version = '1.0', ?string $encoding, ?string $standalone): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -442,7 +442,7 @@ function xmlwriter_start_document($writer, ?string $version = '1.0', ?string $en
|
|||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_document($writer): bool {}
|
||||
function xmlwriter_end_document(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -458,7 +458,7 @@ function xmlwriter_end_document($writer): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_comment($writer, string $content): bool {}
|
||||
function xmlwriter_write_comment(XMLWriter $writer, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -480,7 +480,7 @@ function xmlwriter_write_comment($writer, string $content): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_dtd($writer, string $qualifiedName, ?string $publicId, ?string $systemId): bool {}
|
||||
function xmlwriter_start_dtd(XMLWriter $writer, string $qualifiedName, ?string $publicId, ?string $systemId): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -492,7 +492,7 @@ function xmlwriter_start_dtd($writer, string $qualifiedName, ?string $publicId,
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-openuri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_dtd($writer): bool {}
|
||||
function xmlwriter_end_dtd(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -517,7 +517,7 @@ function xmlwriter_end_dtd($writer): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_dtd($writer, string $name, ?string $publicId, ?string $systemId, ?string $content): bool {}
|
||||
function xmlwriter_write_dtd(XMLWriter $writer, string $name, ?string $publicId, ?string $systemId, ?string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -533,7 +533,7 @@ function xmlwriter_write_dtd($writer, string $name, ?string $publicId, ?string $
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_dtd_element($writer, string $qualifiedName): bool {}
|
||||
function xmlwriter_start_dtd_element(XMLWriter $writer, string $qualifiedName): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -542,7 +542,7 @@ function xmlwriter_start_dtd_element($writer, string $qualifiedName): bool {}
|
|||
* @param $writer
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_dtd_element($writer): bool {}
|
||||
function xmlwriter_end_dtd_element(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -561,7 +561,7 @@ function xmlwriter_end_dtd_element($writer): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_dtd_element($writer, string $name, string $content): bool {}
|
||||
function xmlwriter_write_dtd_element(XMLWriter $writer, string $name, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -577,7 +577,7 @@ function xmlwriter_write_dtd_element($writer, string $name, string $content): bo
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_dtd_attlist($writer, string $name): bool {}
|
||||
function xmlwriter_start_dtd_attlist(XMLWriter $writer, string $name): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -589,7 +589,7 @@ function xmlwriter_start_dtd_attlist($writer, string $name): bool {}
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-openuri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_dtd_attlist($writer): bool {}
|
||||
function xmlwriter_end_dtd_attlist(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -608,7 +608,7 @@ function xmlwriter_end_dtd_attlist($writer): bool {}
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_dtd_attlist($writer, string $name, string $content): bool {}
|
||||
function xmlwriter_write_dtd_attlist(XMLWriter $writer, string $name, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -625,7 +625,7 @@ function xmlwriter_write_dtd_attlist($writer, string $name, string $content): bo
|
|||
* @param bool $isParam
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_start_dtd_entity($writer, string $name, bool $isParam): bool {}
|
||||
function xmlwriter_start_dtd_entity(XMLWriter $writer, string $name, bool $isParam): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -637,7 +637,7 @@ function xmlwriter_start_dtd_entity($writer, string $name, bool $isParam): bool
|
|||
* This resource comes from a call to {@link https://php.net/manual/en/function.xmlwriter-openuri.php" xmlwriter_open_uri()}
|
||||
* or {@link https://php.net/manual/en/function.xmlwriter-openmemory.php" xmlwriter_open_memory()}.</p> * @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_end_dtd_entity($writer): bool {}
|
||||
function xmlwriter_end_dtd_entity(XMLWriter $writer): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -660,7 +660,7 @@ function xmlwriter_end_dtd_entity($writer): bool {}
|
|||
* @param string $notationData
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
function xmlwriter_write_dtd_entity($writer, string $name, string $content): bool {}
|
||||
function xmlwriter_write_dtd_entity(XMLWriter $writer, string $name, string $content, bool $isParam = false, ?string $publicId = null, ?string $systemId = null, ?string $notationData = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -676,7 +676,7 @@ function xmlwriter_write_dtd_entity($writer, string $name, string $content): boo
|
|||
* </p>
|
||||
* @return string the current buffer as a string.
|
||||
*/
|
||||
function xmlwriter_output_memory($writer, bool $flush = true): string {}
|
||||
function xmlwriter_output_memory(XMLWriter $writer, bool $flush = true): string {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 1.0.0)<br/>
|
||||
|
@ -694,7 +694,7 @@ function xmlwriter_output_memory($writer, bool $flush = true): string {}
|
|||
* Else, if using URI, this function will write the buffer and return the number of
|
||||
* written bytes.
|
||||
*/
|
||||
function xmlwriter_flush($writer, bool $empty = true): string|int {}
|
||||
function xmlwriter_flush(XMLWriter $writer, bool $empty = true): string|int {}
|
||||
|
||||
class XMLWriter
|
||||
{
|
||||
|
@ -712,7 +712,7 @@ class XMLWriter
|
|||
* xmlwriter functions on success, <b>FALSE</b> on error.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function openUri($uri): bool {}
|
||||
public function openUri(string $uri): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -737,7 +737,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setIndent($enable): bool {}
|
||||
public function setIndent(bool $enable): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -749,7 +749,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function setIndentString($indentation): bool {}
|
||||
public function setIndentString(string $indentation): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 1.0.0)<br/>
|
||||
|
@ -779,7 +779,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startAttribute($name): bool {}
|
||||
public function startAttribute(string $name): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -803,7 +803,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeAttribute($name, $value): bool {}
|
||||
public function writeAttribute(string $name, string $value): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -821,7 +821,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startAttributeNs($prefix, $name, $namespace): bool {}
|
||||
public function startAttributeNs(string|null $prefix, string $name, string|null $namespace): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -842,7 +842,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeAttributeNs($prefix, $name, $namespace, $value): bool {}
|
||||
public function writeAttributeNs(string|null $prefix, string $name, string|null $namespace, string $value): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -854,7 +854,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startElement($name): bool {}
|
||||
public function startElement(string $name): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -890,7 +890,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startElementNs($prefix, $name, $namespace): bool {}
|
||||
public function startElementNs(string|null $prefix, string $name, string|null $namespace): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -905,7 +905,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeElement($name, $content = null): bool {}
|
||||
public function writeElement(string $name, string|null $content = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -926,7 +926,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeElementNs($prefix, $name, $namespace, $content = null): bool {}
|
||||
public function writeElementNs(string|null $prefix, string $name, string|null $namespace, string|null $content = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -938,7 +938,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startPi($target): bool {}
|
||||
public function startPi(string $target): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -962,7 +962,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writePi($target, $content): bool {}
|
||||
public function writePi(string $target, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -992,7 +992,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeCdata($content): bool {}
|
||||
public function writeCdata(string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1004,7 +1004,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function text($content): bool {}
|
||||
public function text(string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL xmlwriter >= 2.0.4)<br/>
|
||||
|
@ -1016,7 +1016,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeRaw($content): bool {}
|
||||
public function writeRaw(string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1034,7 +1034,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startDocument($version = '1.0', $encoding = null, $standalone = null): bool {}
|
||||
public function startDocument(string|null $version = '1.0', string|null $encoding = null, string|null $standalone = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1055,7 +1055,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeComment($content): bool {}
|
||||
public function writeComment(string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1073,7 +1073,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startDtd($qualifiedName, $publicId = null, $systemId = null): bool {}
|
||||
public function startDtd(string $qualifiedName, string|null $publicId = null, string|null $systemId = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1103,7 +1103,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeDtd($name, $publicId = null, $systemId = null, $content = null): bool {}
|
||||
public function writeDtd(string $name, string|null $publicId = null, string|null $systemId = null, string|null $content = null): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1115,7 +1115,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startDtdElement($qualifiedName): bool {}
|
||||
public function startDtdElement(string $qualifiedName): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1139,7 +1139,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeDtdElement($name, $content): bool {}
|
||||
public function writeDtdElement(string $name, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1151,7 +1151,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startDtdAttlist($name): bool {}
|
||||
public function startDtdAttlist(string $name): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1175,7 +1175,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function writeDtdAttlist($name, $content): bool {}
|
||||
public function writeDtdAttlist(string $name, string $content): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1188,7 +1188,7 @@ class XMLWriter
|
|||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function startDtdEntity($name, $isParam): bool {}
|
||||
public function startDtdEntity(string $name, bool $isParam): bool {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1215,7 +1215,7 @@ class XMLWriter
|
|||
* @param string $ndataid
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function writeDtdEntity($name, $content, $pe, $pubid, $sysid, $ndataid) {}
|
||||
public function writeDtdEntity(string $name, string $content, $pe, $pubid, $sysid, $ndataid) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 0.1.0)<br/>
|
||||
|
@ -1227,7 +1227,7 @@ class XMLWriter
|
|||
* @return string the current buffer as a string.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function outputMemory($flush = true): string {}
|
||||
public function outputMemory(bool $flush = true): string {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.1.2, PECL xmlwriter >= 1.0.0)<br/>
|
||||
|
@ -1241,5 +1241,5 @@ class XMLWriter
|
|||
* written bytes.
|
||||
*/
|
||||
#[TentativeType]
|
||||
public function flush($empty = true): string|int {}
|
||||
public function flush(bool $empty = true): string|int {}
|
||||
}
|
||||
|
|
76
zip/zip.php
76
zip/zip.php
|
@ -756,9 +756,9 @@ class ZipArchive implements Countable
|
|||
*/
|
||||
public $lastId;
|
||||
|
||||
public static function isEncryptionMethodSupported($method, $enc = true) {}
|
||||
public static function isEncryptionMethodSupported(int $method, bool $enc = true) {}
|
||||
|
||||
public static function isCompressionMethodSupported($method, $enc = true) {}
|
||||
public static function isCompressionMethodSupported(int $method, bool $enc = true) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -835,7 +835,7 @@ class ZipArchive implements Countable
|
|||
* Seek error.
|
||||
* </p>
|
||||
*/
|
||||
public function open($filename, $flags = null) {}
|
||||
public function open(string $filename, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -872,7 +872,7 @@ class ZipArchive implements Countable
|
|||
* @param int $flags [optional] Set how to manage name encoding (ZipArchive::FL_ENC_*) and entry replacement (ZipArchive::FL_OVERWRITE)
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function addEmptyDir($dirname, $flags) {}
|
||||
public function addEmptyDir(string $dirname, int $flags) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -888,7 +888,7 @@ class ZipArchive implements Countable
|
|||
* @param int $flags [optional] Set how to manage name encoding (ZipArchive::FL_ENC_*) and entry replacement (ZipArchive::FL_OVERWRITE)
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function addFromString($name, $content, $flags = 8192) {}
|
||||
public function addFromString(string $name, string $content, int $flags = 8192) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -909,7 +909,7 @@ class ZipArchive implements Countable
|
|||
* @param int $flags [optional] Set how to manage name encoding (ZipArchive::FL_ENC_*) and entry replacement (ZipArchive::FL_OVERWRITE)
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function addFile($filepath, $entryname = null, $start = 0, $length = 0, $flags = 8192) {}
|
||||
public function addFile(string $filepath, string $entryname = null, int $start = 0, int $length = 0, int $flags = 8192) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.3.0, PECL zip >= 1.9.0)<br/>
|
||||
|
@ -935,7 +935,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function addGlob($pattern, $flags = 0, array $options = []) {}
|
||||
public function addGlob(string $pattern, int $flags = 0, array $options = []) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.3.0, PECL zip >= 1.9.0)<br/>
|
||||
|
@ -952,7 +952,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function addPattern($pattern, $path = '.', array $options = []) {}
|
||||
public function addPattern(string $pattern, string $path = '.', array $options = []) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.5.0)<br/>
|
||||
|
@ -966,7 +966,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function renameIndex($index, $new_name) {}
|
||||
public function renameIndex(int $index, string $new_name) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.5.0)<br/>
|
||||
|
@ -980,7 +980,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function renameName($name, $new_name) {}
|
||||
public function renameName(string $name, string $new_name) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.4.0)<br/>
|
||||
|
@ -991,7 +991,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function setArchiveComment($comment) {}
|
||||
public function setArchiveComment(string $comment) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -1003,7 +1003,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return string|false the Zip archive comment or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function getArchiveComment($flags = null) {}
|
||||
public function getArchiveComment(int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.4.0)<br/>
|
||||
|
@ -1017,7 +1017,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function setCommentIndex($index, $comment) {}
|
||||
public function setCommentIndex(int $index, string $comment) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.4.0)<br/>
|
||||
|
@ -1031,7 +1031,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function setCommentName($name, $comment) {}
|
||||
public function setCommentName(string $name, string $comment) {}
|
||||
|
||||
/**
|
||||
* Set the compression method of an entry defined by its index
|
||||
|
@ -1083,7 +1083,7 @@ class ZipArchive implements Countable
|
|||
* @return bool
|
||||
* @since 5.6
|
||||
*/
|
||||
public function setPassword($password) {}
|
||||
public function setPassword(string $password) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.4.0)<br/>
|
||||
|
@ -1098,7 +1098,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return string|false the comment on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function getCommentIndex($index, $flags = null) {}
|
||||
public function getCommentIndex(int $index, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.4.0)<br/>
|
||||
|
@ -1113,7 +1113,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return string|false the comment on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function getCommentName($name, $flags = null) {}
|
||||
public function getCommentName(string $name, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.5.0)<br/>
|
||||
|
@ -1124,7 +1124,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function deleteIndex($index) {}
|
||||
public function deleteIndex(int $index) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.5.0)<br/>
|
||||
|
@ -1135,7 +1135,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function deleteName($name) {}
|
||||
public function deleteName(string $name) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.5.0)<br/>
|
||||
|
@ -1153,7 +1153,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return array|false an array containing the entry details or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function statName($name, $flags = null) {}
|
||||
public function statName(string $name, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -1169,7 +1169,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return array|false an array containing the entry details or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function statIndex($index, $flags = null) {}
|
||||
public function statIndex(int $index, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.5.0)<br/>
|
||||
|
@ -1185,7 +1185,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return int|false the index of the entry on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function locateName($name, $flags = null) {}
|
||||
public function locateName(string $name, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.5.0)<br/>
|
||||
|
@ -1200,7 +1200,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return string|false the name on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function getNameIndex($index, $flags = null) {}
|
||||
public function getNameIndex(int $index, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -1227,7 +1227,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function unchangeIndex($index) {}
|
||||
public function unchangeIndex(int $index) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.5.0)<br/>
|
||||
|
@ -1238,7 +1238,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function unchangeName($name) {}
|
||||
public function unchangeName(string $name) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -1253,7 +1253,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return bool <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function extractTo($pathto, $files = null) {}
|
||||
public function extractTo(string $pathto, array|string|null $files = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -1273,7 +1273,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return string|false the contents of the entry on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function getFromName($name, $len = 0, $flags = null) {}
|
||||
public function getFromName(string $name, int $len = 0, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.3.0)<br/>
|
||||
|
@ -1295,7 +1295,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return string|false the contents of the entry on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function getFromIndex($index, $len = 0, $flags = null) {}
|
||||
public function getFromIndex(int $index, int $len = 0, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* (PHP 5 >= 5.2.0, PECL zip >= 1.1.0)<br/>
|
||||
|
@ -1306,7 +1306,7 @@ class ZipArchive implements Countable
|
|||
* </p>
|
||||
* @return resource|false a file pointer (resource) on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function getStream($name) {}
|
||||
public function getStream(string $name) {}
|
||||
|
||||
/**
|
||||
* Set the external attributes of an entry defined by its name
|
||||
|
@ -1317,7 +1317,7 @@ class ZipArchive implements Countable
|
|||
* @param int $flags [optional] Optional flags. Currently unused.
|
||||
* @return bool Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function setExternalAttributesName($name, $opsys, $attr, $flags = null) {}
|
||||
public function setExternalAttributesName(string $name, int $opsys, int $attr, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* Retrieve the external attributes of an entry defined by its name
|
||||
|
@ -1328,7 +1328,7 @@ class ZipArchive implements Countable
|
|||
* @param int $flags [optional] If flags is set to ZipArchive::FL_UNCHANGED, the original unchanged attributes are returned.
|
||||
* @return bool Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function getExternalAttributesName($name, &$opsys, &$attr, $flags = null) {}
|
||||
public function getExternalAttributesName(string $name, int &$opsys, int &$attr, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* Set the external attributes of an entry defined by its index
|
||||
|
@ -1339,7 +1339,7 @@ class ZipArchive implements Countable
|
|||
* @param int $flags [optional] Optional flags. Currently unused.
|
||||
* @return bool Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function setExternalAttributesIndex($index, $opsys, $attr, $flags = null) {}
|
||||
public function setExternalAttributesIndex(int $index, int $opsys, int $attr, int $flags = null) {}
|
||||
|
||||
/**
|
||||
* Retrieve the external attributes of an entry defined by its index
|
||||
|
@ -1350,15 +1350,15 @@ class ZipArchive implements Countable
|
|||
* @param int $flags [optional] If flags is set to ZipArchive::FL_UNCHANGED, the original unchanged attributes are returned.
|
||||
* @return bool Returns <b>TRUE</b> on success or <b>FALSE</b> on failure.
|
||||
*/
|
||||
public function getExternalAttributesIndex($index, &$opsys, &$attr, $flags = null) {}
|
||||
public function getExternalAttributesIndex(int $index, int &$opsys, int &$attr, int $flags = null) {}
|
||||
|
||||
public function registerCancelCallback($callback) {}
|
||||
public function registerCancelCallback(callable $callback) {}
|
||||
|
||||
public function registerProgressCallback($rate, $callback) {}
|
||||
public function registerProgressCallback(float $rate, callable $callback) {}
|
||||
|
||||
public function setMtimeName($name, $timestamp, $flags = null) {}
|
||||
public function setMtimeName(string $name, int $timestamp, int $flags = null) {}
|
||||
|
||||
public function setMtimeIndex($index, $timestamp, $flags = null) {}
|
||||
public function setMtimeIndex(int $index, int $timestamp, int $flags = null) {}
|
||||
|
||||
public function replaceFile($filepath, $index, $start = null, $length = null, $flags = null) {}
|
||||
public function replaceFile(string $filepath, string $index, int $start = null, int $length = null, int $flags = null) {}
|
||||
}
|
||||
|
|
|
@ -486,7 +486,7 @@ function ob_gzhandler(string $data, int $flags): string|false {}
|
|||
* @since 7.0
|
||||
*/
|
||||
#[Pure]
|
||||
function deflate_init(int $encoding, array $options = []) {}
|
||||
function deflate_init(int $encoding, array $options = []): DeflateContext|false {}
|
||||
|
||||
/**
|
||||
* Incrementally deflate data
|
||||
|
@ -509,7 +509,7 @@ function deflate_init(int $encoding, array $options = []) {}
|
|||
* </p>
|
||||
* @since 7.0
|
||||
*/
|
||||
function deflate_add($context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH): string|false {}
|
||||
function deflate_add(DeflateContext $context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH): string|false {}
|
||||
|
||||
/**
|
||||
* Initialize an incremental inflate context
|
||||
|
@ -533,7 +533,7 @@ function deflate_add($context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH):
|
|||
* @since 7.0
|
||||
*/
|
||||
#[Pure]
|
||||
function inflate_init(int $encoding, array $options = []) {}
|
||||
function inflate_init(int $encoding, array $options = []): InflateContext|false {}
|
||||
|
||||
/**
|
||||
* Incrementally inflate encoded data
|
||||
|
@ -556,7 +556,7 @@ function inflate_init(int $encoding, array $options = []) {}
|
|||
* </p>
|
||||
* @since 7.0
|
||||
*/
|
||||
function inflate_add($context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH): string|false {}
|
||||
function inflate_add(InflateContext $context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH): string|false {}
|
||||
|
||||
/**
|
||||
* Get number of bytes read so far
|
||||
|
@ -565,7 +565,7 @@ function inflate_add($context, string $data, int $flush_mode = ZLIB_SYNC_FLUSH):
|
|||
* @since 7.2
|
||||
*/
|
||||
#[Pure]
|
||||
function inflate_get_read_len($context): int {}
|
||||
function inflate_get_read_len(InflateContext $context): int {}
|
||||
|
||||
/**
|
||||
* Get decompression status
|
||||
|
@ -574,4 +574,28 @@ function inflate_get_read_len($context): int {}
|
|||
* @since 7.2
|
||||
*/
|
||||
#[Pure]
|
||||
function inflate_get_status($context): int {}
|
||||
function inflate_get_status(InflateContext $context): int {}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class InflateContext
|
||||
{
|
||||
/**
|
||||
* Use inflate_init() instead
|
||||
* @see inflate_init()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 8.0
|
||||
*/
|
||||
final class DeflateContext
|
||||
{
|
||||
/**
|
||||
* Use deflate_init() instead
|
||||
* @see deflate_init()
|
||||
*/
|
||||
private function __construct() {}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue