dolibarr/dev/tools/phan/stubs/mysqli.phan_php

398 lines
18 KiB
Plaintext
Raw Normal View History

2024-09-06 20:28:06 +08:00
<?php
// These stubs were generated by the phan stub generator.
// @phan-stub-for-extension mysqli@8.2.9
namespace {
class mysqli {
// properties
public $affected_rows;
public $client_info;
public $client_version;
public $connect_errno;
public $connect_error;
public $errno;
public $error;
public $error_list;
public $field_count;
public $host_info;
public $info;
public $insert_id;
public $protocol_version;
public $server_info;
public $server_version;
public $sqlstate;
public $stat;
public $thread_id;
public $warning_count;
// methods
public function __construct(?string $hostname = null, ?string $username = null, ?string $password = null, ?string $database = null, ?int $port = null, ?string $socket = null) {}
public function autocommit(bool $enable) : bool {}
public function begin_transaction(int $flags = 0, ?string $name = null) : bool {}
public function change_user(string $username, string $password, ?string $database) : bool {}
public function character_set_name() : string {}
public function close() {}
public function commit(int $flags = 0, ?string $name = null) : bool {}
public function connect(?string $hostname = null, ?string $username = null, ?string $password = null, ?string $database = null, ?int $port = null, ?string $socket = null) : bool {}
public function dump_debug_info() : bool {}
public function debug(string $options) {}
public function get_charset() : ?object {}
public function execute_query(string $query, ?array $params = null) : \mysqli_result|bool {}
public function get_client_info() : string {}
public function get_connection_stats() : array {}
public function get_server_info() : string {}
public function get_warnings() : \mysqli_warning|false {}
public function init() {}
public function kill(int $process_id) : bool {}
public function multi_query(string $query) : bool {}
public function more_results() : bool {}
public function next_result() : bool {}
public function ping() : bool {}
public static function poll(?array &$read, ?array &$error, array &$reject, int $seconds, int $microseconds = 0) : false|int {}
public function prepare(string $query) : \mysqli_stmt|false {}
public function query(string $query, int $result_mode = \MYSQLI_STORE_RESULT) : \mysqli_result|bool {}
public function real_connect(?string $hostname = null, ?string $username = null, ?string $password = null, ?string $database = null, ?int $port = null, ?string $socket = null, int $flags = 0) : bool {}
public function real_escape_string(string $string) : string {}
public function reap_async_query() : \mysqli_result|bool {}
public function escape_string(string $string) : string {}
public function real_query(string $query) : bool {}
public function release_savepoint(string $name) : bool {}
public function rollback(int $flags = 0, ?string $name = null) : bool {}
public function savepoint(string $name) : bool {}
public function select_db(string $database) : bool {}
public function set_charset(string $charset) : bool {}
public function options(int $option, $value) : bool {}
public function set_opt(int $option, $value) : bool {}
public function ssl_set(?string $key, ?string $certificate, ?string $ca_certificate, ?string $ca_path, ?string $cipher_algos) {}
public function stat() : false|string {}
public function stmt_init() : \mysqli_stmt|false {}
public function store_result(int $mode = 0) : \mysqli_result|false {}
public function thread_safe() : bool {}
public function use_result() : \mysqli_result|false {}
public function refresh(int $flags) : bool {}
}
final class mysqli_driver {
// properties
public $client_info;
public $client_version;
public $driver_version;
public $embedded;
public $reconnect;
public $report_mode;
}
class mysqli_result implements \IteratorAggregate, \Traversable {
// properties
public $current_field;
public $field_count;
public $lengths;
public $num_rows;
public $type;
// methods
public function __construct(\mysqli $mysql, int $result_mode = \MYSQLI_STORE_RESULT) {}
public function close() : void {}
public function free() : void {}
public function data_seek(int $offset) : bool {}
public function fetch_field() : false|object {}
public function fetch_fields() : array {}
public function fetch_field_direct(int $index) : false|object {}
public function fetch_all(int $mode = \MYSQLI_NUM) : array {}
public function fetch_array(int $mode = \MYSQLI_BOTH) : array|false|null {}
public function fetch_assoc() : array|false|null {}
public function fetch_object(string $class = 'stdClass', array $constructor_args = []) : false|null|object {}
public function fetch_row() : array|false|null {}
public function fetch_column(int $column = 0) : false|float|int|null|string {}
public function field_seek(int $index) : bool {}
public function free_result() : void {}
public function getIterator() : \Iterator {}
}
final class mysqli_sql_exception extends \RuntimeException {
// properties
protected $sqlstate;
protected $message;
protected $code;
protected $file;
protected $line;
// methods
public function getSqlState() : string {}
}
class mysqli_stmt {
// properties
public $affected_rows;
public $errno;
public $error;
public $error_list;
public $field_count;
public $id;
public $insert_id;
public $num_rows;
public $param_count;
public $sqlstate;
// methods
public function __construct(\mysqli $mysql, ?string $query = null) {}
public function attr_get(int $attribute) : int {}
public function attr_set(int $attribute, int $value) : bool {}
public function bind_param(string $types, mixed &...$vars) : bool {}
public function bind_result(mixed &...$vars) : bool {}
public function close() {}
public function data_seek(int $offset) : void {}
public function execute(?array $params = null) : bool {}
public function fetch() : ?bool {}
public function get_warnings() : \mysqli_warning|false {}
public function result_metadata() : \mysqli_result|false {}
public function more_results() : bool {}
public function next_result() : bool {}
public function num_rows() : int|string {}
public function send_long_data(int $param_num, string $data) : bool {}
public function free_result() : void {}
public function reset() : bool {}
public function prepare(string $query) : bool {}
public function store_result() : bool {}
public function get_result() : \mysqli_result|false {}
}
final class mysqli_warning {
// properties
public $errno;
public $message;
public $sqlstate;
// methods
private function __construct() {}
public function next() : bool {}
}
function mysqli_affected_rows(\mysqli $mysql) : int|string {}
function mysqli_autocommit(\mysqli $mysql, bool $enable) : bool {}
function mysqli_begin_transaction(\mysqli $mysql, int $flags = 0, ?string $name = null) : bool {}
function mysqli_change_user(\mysqli $mysql, string $username, string $password, ?string $database) : bool {}
function mysqli_character_set_name(\mysqli $mysql) : string {}
function mysqli_close(\mysqli $mysql) : true {}
function mysqli_commit(\mysqli $mysql, int $flags = 0, ?string $name = null) : bool {}
function mysqli_connect(?string $hostname = null, ?string $username = null, ?string $password = null, ?string $database = null, ?int $port = null, ?string $socket = null) : \mysqli|false {}
function mysqli_connect_errno() : int {}
function mysqli_connect_error() : ?string {}
function mysqli_data_seek(\mysqli_result $result, int $offset) : bool {}
function mysqli_debug(string $options) : true {}
function mysqli_dump_debug_info(\mysqli $mysql) : bool {}
function mysqli_errno(\mysqli $mysql) : int {}
function mysqli_error(\mysqli $mysql) : string {}
function mysqli_error_list(\mysqli $mysql) : array {}
function mysqli_escape_string(\mysqli $mysql, string $string) : string {}
function mysqli_execute(\mysqli_stmt $statement, ?array $params = null) : bool {}
function mysqli_execute_query(\mysqli $mysql, string $query, ?array $params = null) : \mysqli_result|bool {}
function mysqli_fetch_all(\mysqli_result $result, int $mode = \MYSQLI_NUM) : array {}
function mysqli_fetch_array(\mysqli_result $result, int $mode = \MYSQLI_BOTH) : array|false|null {}
function mysqli_fetch_assoc(\mysqli_result $result) : array|false|null {}
function mysqli_fetch_column(\mysqli_result $result, int $column = 0) : false|float|int|null|string {}
function mysqli_fetch_field(\mysqli_result $result) : false|object {}
function mysqli_fetch_field_direct(\mysqli_result $result, int $index) : false|object {}
function mysqli_fetch_fields(\mysqli_result $result) : array {}
function mysqli_fetch_lengths(\mysqli_result $result) : array|false {}
function mysqli_fetch_object(\mysqli_result $result, string $class = 'stdClass', array $constructor_args = []) : false|null|object {}
function mysqli_fetch_row(\mysqli_result $result) : array|false|null {}
function mysqli_field_count(\mysqli $mysql) : int {}
function mysqli_field_seek(\mysqli_result $result, int $index) : bool {}
function mysqli_field_tell(\mysqli_result $result) : int {}
function mysqli_free_result(\mysqli_result $result) : void {}
function mysqli_get_charset(\mysqli $mysql) : ?object {}
function mysqli_get_client_info(?\mysqli $mysql = null) : string {}
function mysqli_get_client_stats() : array {}
function mysqli_get_client_version() : int {}
function mysqli_get_connection_stats(\mysqli $mysql) : array {}
function mysqli_get_host_info(\mysqli $mysql) : string {}
function mysqli_get_links_stats() : array {}
function mysqli_get_proto_info(\mysqli $mysql) : int {}
function mysqli_get_server_info(\mysqli $mysql) : string {}
function mysqli_get_server_version(\mysqli $mysql) : int {}
function mysqli_get_warnings(\mysqli $mysql) : \mysqli_warning|false {}
function mysqli_info(\mysqli $mysql) : ?string {}
function mysqli_init() : \mysqli|false {}
function mysqli_insert_id(\mysqli $mysql) : int|string {}
function mysqli_kill(\mysqli $mysql, int $process_id) : bool {}
function mysqli_more_results(\mysqli $mysql) : bool {}
function mysqli_multi_query(\mysqli $mysql, string $query) : bool {}
function mysqli_next_result(\mysqli $mysql) : bool {}
function mysqli_num_fields(\mysqli_result $result) : int {}
function mysqli_num_rows(\mysqli_result $result) : int|string {}
function mysqli_options(\mysqli $mysql, int $option, $value) : bool {}
function mysqli_ping(\mysqli $mysql) : bool {}
function mysqli_poll(?array &$read, ?array &$error, array &$reject, int $seconds, int $microseconds = 0) : false|int {}
function mysqli_prepare(\mysqli $mysql, string $query) : \mysqli_stmt|false {}
function mysqli_query(\mysqli $mysql, string $query, int $result_mode = \MYSQLI_STORE_RESULT) : \mysqli_result|bool {}
function mysqli_real_connect(\mysqli $mysql, ?string $hostname = null, ?string $username = null, ?string $password = null, ?string $database = null, ?int $port = null, ?string $socket = null, int $flags = 0) : bool {}
function mysqli_real_escape_string(\mysqli $mysql, string $string) : string {}
function mysqli_real_query(\mysqli $mysql, string $query) : bool {}
function mysqli_reap_async_query(\mysqli $mysql) : \mysqli_result|bool {}
function mysqli_refresh(\mysqli $mysql, int $flags) : bool {}
function mysqli_release_savepoint(\mysqli $mysql, string $name) : bool {}
function mysqli_report(int $flags) : bool {}
function mysqli_rollback(\mysqli $mysql, int $flags = 0, ?string $name = null) : bool {}
function mysqli_savepoint(\mysqli $mysql, string $name) : bool {}
function mysqli_select_db(\mysqli $mysql, string $database) : bool {}
function mysqli_set_charset(\mysqli $mysql, string $charset) : bool {}
function mysqli_set_opt(\mysqli $mysql, int $option, $value) : bool {}
function mysqli_sqlstate(\mysqli $mysql) : string {}
function mysqli_ssl_set(\mysqli $mysql, ?string $key, ?string $certificate, ?string $ca_certificate, ?string $ca_path, ?string $cipher_algos) : true {}
function mysqli_stat(\mysqli $mysql) : false|string {}
function mysqli_stmt_affected_rows(\mysqli_stmt $statement) : int|string {}
function mysqli_stmt_attr_get(\mysqli_stmt $statement, int $attribute) : int {}
function mysqli_stmt_attr_set(\mysqli_stmt $statement, int $attribute, int $value) : bool {}
function mysqli_stmt_bind_param(\mysqli_stmt $statement, string $types, mixed &...$vars) : bool {}
function mysqli_stmt_bind_result(\mysqli_stmt $statement, mixed &...$vars) : bool {}
function mysqli_stmt_close(\mysqli_stmt $statement) : true {}
function mysqli_stmt_data_seek(\mysqli_stmt $statement, int $offset) : void {}
function mysqli_stmt_errno(\mysqli_stmt $statement) : int {}
function mysqli_stmt_error(\mysqli_stmt $statement) : string {}
function mysqli_stmt_error_list(\mysqli_stmt $statement) : array {}
function mysqli_stmt_execute(\mysqli_stmt $statement, ?array $params = null) : bool {}
function mysqli_stmt_fetch(\mysqli_stmt $statement) : ?bool {}
function mysqli_stmt_field_count(\mysqli_stmt $statement) : int {}
function mysqli_stmt_free_result(\mysqli_stmt $statement) : void {}
function mysqli_stmt_get_result(\mysqli_stmt $statement) : \mysqli_result|false {}
function mysqli_stmt_get_warnings(\mysqli_stmt $statement) : \mysqli_warning|false {}
function mysqli_stmt_init(\mysqli $mysql) : \mysqli_stmt|false {}
function mysqli_stmt_insert_id(\mysqli_stmt $statement) : int|string {}
function mysqli_stmt_more_results(\mysqli_stmt $statement) : bool {}
function mysqli_stmt_next_result(\mysqli_stmt $statement) : bool {}
function mysqli_stmt_num_rows(\mysqli_stmt $statement) : int|string {}
function mysqli_stmt_param_count(\mysqli_stmt $statement) : int {}
function mysqli_stmt_prepare(\mysqli_stmt $statement, string $query) : bool {}
function mysqli_stmt_reset(\mysqli_stmt $statement) : bool {}
function mysqli_stmt_result_metadata(\mysqli_stmt $statement) : \mysqli_result|false {}
function mysqli_stmt_send_long_data(\mysqli_stmt $statement, int $param_num, string $data) : bool {}
function mysqli_stmt_sqlstate(\mysqli_stmt $statement) : string {}
function mysqli_stmt_store_result(\mysqli_stmt $statement) : bool {}
function mysqli_store_result(\mysqli $mysql, int $mode = 0) : \mysqli_result|false {}
function mysqli_thread_id(\mysqli $mysql) : int {}
function mysqli_thread_safe() : bool {}
function mysqli_use_result(\mysqli $mysql) : \mysqli_result|false {}
function mysqli_warning_count(\mysqli $mysql) : int {}
const MYSQLI_ASSOC = 1;
const MYSQLI_ASYNC = 8;
const MYSQLI_AUTO_INCREMENT_FLAG = 512;
const MYSQLI_BINARY_FLAG = 128;
const MYSQLI_BLOB_FLAG = 16;
const MYSQLI_BOTH = 3;
const MYSQLI_CLIENT_CAN_HANDLE_EXPIRED_PASSWORDS = 4194304;
const MYSQLI_CLIENT_COMPRESS = 32;
const MYSQLI_CLIENT_FOUND_ROWS = 2;
const MYSQLI_CLIENT_IGNORE_SPACE = 256;
const MYSQLI_CLIENT_INTERACTIVE = 1024;
const MYSQLI_CLIENT_NO_SCHEMA = 16;
const MYSQLI_CLIENT_SSL = 2048;
const MYSQLI_CLIENT_SSL_DONT_VERIFY_SERVER_CERT = 64;
const MYSQLI_CLIENT_SSL_VERIFY_SERVER_CERT = 1073741824;
const MYSQLI_CURSOR_TYPE_FOR_UPDATE = 2;
const MYSQLI_CURSOR_TYPE_NO_CURSOR = 0;
const MYSQLI_CURSOR_TYPE_READ_ONLY = 1;
const MYSQLI_CURSOR_TYPE_SCROLLABLE = 4;
const MYSQLI_DATA_TRUNCATED = 101;
const MYSQLI_DEBUG_TRACE_ENABLED = 0;
const MYSQLI_ENUM_FLAG = 256;
const MYSQLI_GROUP_FLAG = 32768;
const MYSQLI_INIT_COMMAND = 3;
const MYSQLI_IS_MARIADB = false;
const MYSQLI_MULTIPLE_KEY_FLAG = 8;
const MYSQLI_NOT_NULL_FLAG = 1;
const MYSQLI_NO_DATA = 100;
const MYSQLI_NO_DEFAULT_VALUE_FLAG = 4096;
const MYSQLI_NUM = 2;
const MYSQLI_NUM_FLAG = 32768;
const MYSQLI_ON_UPDATE_NOW_FLAG = 8192;
const MYSQLI_OPT_CAN_HANDLE_EXPIRED_PASSWORDS = 37;
const MYSQLI_OPT_CONNECT_TIMEOUT = 0;
const MYSQLI_OPT_INT_AND_FLOAT_NATIVE = 201;
const MYSQLI_OPT_LOAD_DATA_LOCAL_DIR = 43;
const MYSQLI_OPT_LOCAL_INFILE = 8;
const MYSQLI_OPT_NET_CMD_BUFFER_SIZE = 202;
const MYSQLI_OPT_NET_READ_BUFFER_SIZE = 203;
const MYSQLI_OPT_READ_TIMEOUT = 11;
const MYSQLI_OPT_SSL_VERIFY_SERVER_CERT = 21;
const MYSQLI_PART_KEY_FLAG = 16384;
const MYSQLI_PRI_KEY_FLAG = 2;
const MYSQLI_READ_DEFAULT_FILE = 4;
const MYSQLI_READ_DEFAULT_GROUP = 5;
const MYSQLI_REFRESH_BACKUP_LOG = 2097152;
const MYSQLI_REFRESH_GRANT = 1;
const MYSQLI_REFRESH_HOSTS = 8;
const MYSQLI_REFRESH_LOG = 2;
const MYSQLI_REFRESH_MASTER = 128;
const MYSQLI_REFRESH_REPLICA = 64;
const MYSQLI_REFRESH_SLAVE = 64;
const MYSQLI_REFRESH_STATUS = 16;
const MYSQLI_REFRESH_TABLES = 4;
const MYSQLI_REFRESH_THREADS = 32;
const MYSQLI_REPORT_ALL = 255;
const MYSQLI_REPORT_ERROR = 1;
const MYSQLI_REPORT_INDEX = 4;
const MYSQLI_REPORT_OFF = 0;
const MYSQLI_REPORT_STRICT = 2;
const MYSQLI_SERVER_PS_OUT_PARAMS = 4096;
const MYSQLI_SERVER_PUBLIC_KEY = 35;
const MYSQLI_SERVER_QUERY_NO_GOOD_INDEX_USED = 16;
const MYSQLI_SERVER_QUERY_NO_INDEX_USED = 32;
const MYSQLI_SERVER_QUERY_WAS_SLOW = 2048;
const MYSQLI_SET_CHARSET_DIR = 6;
const MYSQLI_SET_CHARSET_NAME = 7;
const MYSQLI_SET_FLAG = 2048;
const MYSQLI_STMT_ATTR_CURSOR_TYPE = 1;
const MYSQLI_STMT_ATTR_PREFETCH_ROWS = 2;
const MYSQLI_STMT_ATTR_UPDATE_MAX_LENGTH = 0;
const MYSQLI_STORE_RESULT = 0;
const MYSQLI_STORE_RESULT_COPY_DATA = 16;
const MYSQLI_TIMESTAMP_FLAG = 1024;
const MYSQLI_TRANS_COR_AND_CHAIN = 1;
const MYSQLI_TRANS_COR_AND_NO_CHAIN = 2;
const MYSQLI_TRANS_COR_NO_RELEASE = 8;
const MYSQLI_TRANS_COR_RELEASE = 4;
const MYSQLI_TRANS_START_READ_ONLY = 4;
const MYSQLI_TRANS_START_READ_WRITE = 2;
const MYSQLI_TRANS_START_WITH_CONSISTENT_SNAPSHOT = 1;
const MYSQLI_TYPE_BIT = 16;
const MYSQLI_TYPE_BLOB = 252;
const MYSQLI_TYPE_CHAR = 1;
const MYSQLI_TYPE_DATE = 10;
const MYSQLI_TYPE_DATETIME = 12;
const MYSQLI_TYPE_DECIMAL = 0;
const MYSQLI_TYPE_DOUBLE = 5;
const MYSQLI_TYPE_ENUM = 247;
const MYSQLI_TYPE_FLOAT = 4;
const MYSQLI_TYPE_GEOMETRY = 255;
const MYSQLI_TYPE_INT24 = 9;
const MYSQLI_TYPE_INTERVAL = 247;
const MYSQLI_TYPE_JSON = 245;
const MYSQLI_TYPE_LONG = 3;
const MYSQLI_TYPE_LONGLONG = 8;
const MYSQLI_TYPE_LONG_BLOB = 251;
const MYSQLI_TYPE_MEDIUM_BLOB = 250;
const MYSQLI_TYPE_NEWDATE = 14;
const MYSQLI_TYPE_NEWDECIMAL = 246;
const MYSQLI_TYPE_NULL = 6;
const MYSQLI_TYPE_SET = 248;
const MYSQLI_TYPE_SHORT = 2;
const MYSQLI_TYPE_STRING = 254;
const MYSQLI_TYPE_TIME = 11;
const MYSQLI_TYPE_TIMESTAMP = 7;
const MYSQLI_TYPE_TINY = 1;
const MYSQLI_TYPE_TINY_BLOB = 249;
const MYSQLI_TYPE_VAR_STRING = 253;
const MYSQLI_TYPE_YEAR = 13;
const MYSQLI_UNIQUE_KEY_FLAG = 4;
const MYSQLI_UNSIGNED_FLAG = 32;
const MYSQLI_USE_RESULT = 1;
const MYSQLI_ZEROFILL_FLAG = 64;
}