Skip to content

Commit 9ad915b

Browse files
committed
Update more parameters.
1 parent 19dd7af commit 9ad915b

7 files changed

+84
-84
lines changed

ext/mysqli/mysqli.stub.php

Lines changed: 37 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ class mysqli
1010
{
1111
public function __construct(
1212
?string $host = null,
13-
?string $user = null,
13+
?string $username = null,
1414
?string $password = null,
1515
?string $database = null,
1616
?int $port = null,
@@ -21,7 +21,7 @@ public function __construct(
2121
* @return bool
2222
* @alias mysqli_autocommit
2323
*/
24-
public function autocommit(bool $autocommit) {}
24+
public function autocommit(bool $enable) {}
2525

2626
/**
2727
* @return bool
@@ -33,7 +33,7 @@ public function begin_transaction(int $flags = 0, ?string $name = null) {}
3333
* @return bool
3434
* @alias mysqli_change_user
3535
*/
36-
public function change_user(string $user, string $password, ?string $database) {}
36+
public function change_user(string $username, string $password, ?string $database) {}
3737

3838
/**
3939
* @return string|null
@@ -59,7 +59,7 @@ public function commit(int $flags = -1, ?string $name = null) {}
5959
*/
6060
public function connect(
6161
?string $host = null,
62-
?string $user = null,
62+
?string $username = null,
6363
?string $password = null,
6464
?string $database = null,
6565
?int $port = null,
@@ -172,7 +172,7 @@ public function query(string $query, int $result_mode = MYSQLI_STORE_RESULT) {}
172172
*/
173173
public function real_connect(
174174
?string $host = null,
175-
?string $user = null,
175+
?string $username = null,
176176
?string $password = null,
177177
?string $database = null,
178178
?int $port = null,
@@ -184,7 +184,7 @@ public function real_connect(
184184
* @return string
185185
* @alias mysqli_real_escape_string
186186
*/
187-
public function real_escape_string(string $string_to_escape) {}
187+
public function real_escape_string(string $string) {}
188188

189189
#if defined(MYSQLI_USE_MYSQLND)
190190
/**
@@ -198,7 +198,7 @@ public function reap_async_query() {}
198198
* @return string
199199
* @alias mysqli_real_escape_string
200200
*/
201-
public function escape_string(string $string_to_escape) {}
201+
public function escape_string(string $string) {}
202202

203203
/**
204204
* @return bool
@@ -256,10 +256,10 @@ public function set_opt(int $option, $value) {}
256256
*/
257257
public function ssl_set(
258258
string $key,
259-
string $cert,
259+
string $certificate,
260260
string $certificate_authority,
261261
string $certificate_authority_path,
262-
string $cipher
262+
string $cipher_algorithms
263263
) {}
264264

265265
/**
@@ -337,7 +337,7 @@ public function fetch_fields() {}
337337
* @return object|false
338338
* @alias mysqli_fetch_field_direct
339339
*/
340-
public function fetch_field_direct(int $field_num) {}
340+
public function fetch_field_direct(int $index) {}
341341

342342
#if defined(MYSQLI_USE_MYSQLND)
343343
/**
@@ -363,7 +363,7 @@ public function fetch_assoc() {}
363363
* @return object|null
364364
* @alias mysqli_fetch_object
365365
*/
366-
public function fetch_object(string $class_name = "stdClass", array $params = []) {}
366+
public function fetch_object(string $class = "stdClass", array $params = []) {}
367367

368368
/**
369369
* @return array|null
@@ -375,7 +375,7 @@ public function fetch_row() {}
375375
* @return bool
376376
* @alias mysqli_field_seek
377377
*/
378-
public function field_seek(int $field_num) {}
378+
public function field_seek(int $index) {}
379379

380380
/**
381381
* @return void
@@ -400,7 +400,7 @@ public function attr_get(int $attr) {}
400400
* @return bool
401401
* @alias mysqli_stmt_attr_set
402402
*/
403-
public function attr_set(int $attr, int $mode) {}
403+
public function attr_set(int $attribute, int $value) {}
404404

405405
/**
406406
* @return bool
@@ -474,7 +474,7 @@ public function num_rows() {}
474474
* @return bool
475475
* @alias mysqli_stmt_send_long_data
476476
*/
477-
public function send_long_data(int $param_num, string $data) {}
477+
public function send_long_data(int $index, string $data) {}
478478

479479
/**
480480
* @return void
@@ -522,11 +522,11 @@ final class mysqli_sql_exception extends RuntimeException
522522

523523
function mysqli_affected_rows(mysqli $mysql_link): int|string {}
524524

525-
function mysqli_autocommit(mysqli $mysql_link, bool $autocommit): bool {}
525+
function mysqli_autocommit(mysqli $mysql_link, bool $enable): bool {}
526526

527527
function mysqli_begin_transaction(mysqli $mysql_link, int $flags = 0, ?string $name = null): bool {}
528528

529-
function mysqli_change_user(mysqli $mysql_link, string $user, string $password, ?string $database): bool {}
529+
function mysqli_change_user(mysqli $mysql_link, string $username, string $password, ?string $database): bool {}
530530

531531
function mysqli_character_set_name(mysqli $mysql_link): ?string {}
532532

@@ -536,7 +536,7 @@ function mysqli_commit(mysqli $mysql_link, int $flags = -1, ?string $name = null
536536

537537
function mysqli_connect(
538538
?string $host = null,
539-
?string $user = null,
539+
?string $username = null,
540540
?string $password = null,
541541
?string $database = null,
542542
?int $port = null,
@@ -547,7 +547,7 @@ function mysqli_connect_errno(): int {}
547547

548548
function mysqli_connect_error(): ?string {}
549549

550-
function mysqli_data_seek(mysqli_result $mysql_result, int $offset): bool {}
550+
function mysqli_data_seek(mysqli_result $result, int $offset): bool {}
551551

552552
function mysqli_dump_debug_info(mysqli $mysql_link): bool {}
553553

@@ -564,29 +564,29 @@ function mysqli_stmt_execute(mysqli_stmt $mysql_stmt): bool {}
564564
/** @alias mysqli_stmt_execute */
565565
function mysqli_execute(mysqli_stmt $mysql_stmt): bool {}
566566

567-
function mysqli_fetch_field(mysqli_result $mysql_result): object|false {}
567+
function mysqli_fetch_field(mysqli_result $result): object|false {}
568568

569-
function mysqli_fetch_fields(mysqli_result $mysql_result): array {}
569+
function mysqli_fetch_fields(mysqli_result $result): array {}
570570

571-
function mysqli_fetch_field_direct(mysqli_result $mysql_result, int $offset): object|false {}
571+
function mysqli_fetch_field_direct(mysqli_result $result, int $offset): object|false {}
572572

573-
function mysqli_fetch_lengths(mysqli_result $mysql_result): array|false {}
573+
function mysqli_fetch_lengths(mysqli_result $result): array|false {}
574574

575575
#if defined(MYSQLI_USE_MYSQLND)
576-
function mysqli_fetch_all(mysqli_result $mysql_result, int $mode = MYSQLI_NUM): array|false {}
576+
function mysqli_fetch_all(mysqli_result $result, int $mode = MYSQLI_NUM): array|false {}
577577
#endif
578578

579-
function mysqli_fetch_array(mysqli_result $mysql_result, int $fetchtype = MYSQLI_BOTH): array|null|false {}
579+
function mysqli_fetch_array(mysqli_result $result, int $fetchtype = MYSQLI_BOTH): array|null|false {}
580580

581-
function mysqli_fetch_assoc(mysqli_result $mysql_result): ?array {}
581+
function mysqli_fetch_assoc(mysqli_result $result): ?array {}
582582

583-
function mysqli_fetch_object(mysqli_result $mysqli_result, string $class_name = "stdClass", array $params = []): ?object {}
583+
function mysqli_fetch_object(mysqli_result $mysqli_result, string $class = "stdClass", array $params = []): ?object {}
584584

585585
function mysqli_fetch_row(mysqli_result $mysqli_result): ?array {}
586586

587587
function mysqli_field_count(mysqli $mysqli_link): int {}
588588

589-
function mysqli_field_seek(mysqli_result $mysqli_result, int $field_num): bool {}
589+
function mysqli_field_seek(mysqli_result $mysqli_result, int $index): bool {}
590590

591591
function mysqli_field_tell(mysqli_result $mysqli_result): int {}
592592

@@ -630,7 +630,7 @@ function mysqli_multi_query(mysqli $mysqli_link, string $query): bool {}
630630

631631
function mysqli_next_result(mysqli $mysqli_link): bool {}
632632

633-
function mysqli_num_fields(mysqli_result $mysql_result): int {}
633+
function mysqli_num_fields(mysqli_result $result): int {}
634634

635635
function mysqli_num_rows(mysqli_result $mysqli_result): int|string {}
636636

@@ -652,15 +652,15 @@ function mysqli_query(mysqli $mysqli_link, string $query, int $result_mode = MYS
652652
function mysqli_real_connect(
653653
mysqli $mysqli_link,
654654
?string $host = null,
655-
?string $user = null,
655+
?string $username = null,
656656
?string $password = null,
657657
?string $database = null,
658658
?int $port = null,
659659
?string $socket = null,
660660
int $flags = 0
661661
): bool {}
662662

663-
function mysqli_real_escape_string(mysqli $mysqli_link, string $string_to_escape): string {}
663+
function mysqli_real_escape_string(mysqli $mysqli_link, string $string): string {}
664664

665665
function mysqli_real_query(mysqli $mysqli_link, string $query): bool {}
666666

@@ -674,15 +674,15 @@ function mysqli_rollback(mysqli $mysqli_link, int $flags = 0, ?string $name = nu
674674

675675
function mysqli_savepoint(mysqli $mysqli_link, string $name): bool {}
676676

677-
function mysqli_select_db(mysqli $mysqli_link, string $dbname): bool {}
677+
function mysqli_select_db(mysqli $mysqli_link, string $database): bool {}
678678

679679
function mysqli_set_charset(mysqli $mysqli_link, string $charset): bool {}
680680

681681
function mysqli_stmt_affected_rows(mysqli_stmt $mysql_stmt): int|string {}
682682

683-
function mysqli_stmt_attr_get(mysqli_stmt $mysql_stmt, int $attr): int {}
683+
function mysqli_stmt_attr_get(mysqli_stmt $mysql_stmt, int $attribute): int {}
684684

685-
function mysqli_stmt_attr_set(mysqli_stmt $mysql_stmt, int $attr, int $mode): bool {}
685+
function mysqli_stmt_attr_set(mysqli_stmt $mysql_stmt, int $attribute, int $value): bool {}
686686

687687
function mysqli_stmt_bind_param(mysqli_stmt $mysql_stmt, string $types, mixed &...$vars): bool {}
688688

@@ -730,7 +730,7 @@ function mysqli_stmt_reset(mysqli_stmt $mysql_stmt): bool {}
730730

731731
function mysqli_stmt_result_metadata(mysqli_stmt $mysql_stmt): mysqli_result|false {}
732732

733-
function mysqli_stmt_send_long_data(mysqli_stmt $mysql_stmt, int $param_num, string $data): bool {}
733+
function mysqli_stmt_send_long_data(mysqli_stmt $mysql_stmt, int $index, string $data): bool {}
734734

735735
function mysqli_stmt_store_result(mysqli_stmt $mysql_stmt): bool {}
736736

@@ -741,10 +741,10 @@ function mysqli_sqlstate(mysqli $mysqli_link): ?string {}
741741
function mysqli_ssl_set(
742742
mysqli $mysql_link,
743743
string $key,
744-
string $cert,
744+
string $certificate,
745745
string $certificate_authority,
746746
string $certificate_authority_path,
747-
string $cipher
747+
string $cipher_algorithms
748748
): bool {}
749749

750750
function mysqli_stat(mysqli $mysql_link): string|false {}
@@ -762,7 +762,7 @@ function mysqli_warning_count(mysqli $mysql_link): int {}
762762
function mysqli_refresh(mysqli $mysqli_link, int $options): bool {}
763763

764764
/** @alias mysqli_real_escape_string */
765-
function mysqli_escape_string(mysqli $mysqli_link, string $string_to_escape): string {}
765+
function mysqli_escape_string(mysqli $mysqli_link, string $string): string {}
766766

767767
/**
768768
* @param string|int $value

0 commit comments

Comments
 (0)