@@ -89,12 +89,12 @@ public function __construct(
8989 #[SensitiveParameter]
9090 array | string $ username ,
9191 #[SensitiveParameter]
92- string $ password = null ,
93- string $ schema = null ,
92+ ? string $ password = null ,
93+ ? string $ schema = null ,
9494 string $ host = 'localhost ' ,
9595 int $ port = 3306 ,
96- Logger $ logger = null ,
97- DatabaseCollector $ collector = null
96+ ? Logger $ logger = null ,
97+ ? DatabaseCollector $ collector = null
9898 ) {
9999 if ($ collector ) {
100100 $ this ->setDebugCollector ($ collector );
@@ -187,8 +187,8 @@ protected function connect(
187187 #[SensitiveParameter]
188188 array | string $ username ,
189189 #[SensitiveParameter]
190- string $ password = null ,
191- string $ schema = null ,
190+ ? string $ password = null ,
191+ ? string $ schema = null ,
192192 string $ host = 'localhost ' ,
193193 int $ port = 3306
194194 ) : static {
@@ -415,7 +415,7 @@ public function use(string $schema) : static
415415 *
416416 * @return CreateSchema
417417 */
418- public function createSchema (string $ schemaName = null ) : CreateSchema
418+ public function createSchema (? string $ schemaName = null ) : CreateSchema
419419 {
420420 $ instance = new CreateSchema ($ this );
421421 if ($ schemaName !== null ) {
@@ -431,7 +431,7 @@ public function createSchema(string $schemaName = null) : CreateSchema
431431 *
432432 * @return DropSchema
433433 */
434- public function dropSchema (string $ schemaName = null ) : DropSchema
434+ public function dropSchema (? string $ schemaName = null ) : DropSchema
435435 {
436436 $ instance = new DropSchema ($ this );
437437 if ($ schemaName !== null ) {
@@ -447,7 +447,7 @@ public function dropSchema(string $schemaName = null) : DropSchema
447447 *
448448 * @return AlterSchema
449449 */
450- public function alterSchema (string $ schemaName = null ) : AlterSchema
450+ public function alterSchema (? string $ schemaName = null ) : AlterSchema
451451 {
452452 $ instance = new AlterSchema ($ this );
453453 if ($ schemaName !== null ) {
@@ -463,7 +463,7 @@ public function alterSchema(string $schemaName = null) : AlterSchema
463463 *
464464 * @return CreateTable
465465 */
466- public function createTable (string $ tableName = null ) : CreateTable
466+ public function createTable (? string $ tableName = null ) : CreateTable
467467 {
468468 $ instance = new CreateTable ($ this );
469469 if ($ tableName !== null ) {
@@ -480,7 +480,7 @@ public function createTable(string $tableName = null) : CreateTable
480480 *
481481 * @return DropTable
482482 */
483- public function dropTable (string $ table = null , string ...$ tables ) : DropTable
483+ public function dropTable (? string $ table = null , string ...$ tables ) : DropTable
484484 {
485485 $ instance = new DropTable ($ this );
486486 if ($ table !== null ) {
@@ -496,7 +496,7 @@ public function dropTable(string $table = null, string ...$tables) : DropTable
496496 *
497497 * @return AlterTable
498498 */
499- public function alterTable (string $ tableName = null ) : AlterTable
499+ public function alterTable (? string $ tableName = null ) : AlterTable
500500 {
501501 $ instance = new AlterTable ($ this );
502502 if ($ tableName !== null ) {
@@ -508,14 +508,14 @@ public function alterTable(string $tableName = null) : AlterTable
508508 /**
509509 * Call a DELETE statement.
510510 *
511- * @param array<string,Closure|string>|Closure |string|null $reference
512- * @param array<string,Closure|string>|Closure |string ...$references
511+ * @param Closure| array<string,Closure|string>|string|null $reference
512+ * @param Closure| array<string,Closure|string>|string ...$references
513513 *
514514 * @return Delete
515515 */
516516 public function delete (
517- array | Closure | string $ reference = null ,
518- array | Closure | string ...$ references
517+ Closure | array | string | null $ reference = null ,
518+ Closure | array | string ...$ references
519519 ) : Delete {
520520 $ instance = new Delete ($ this );
521521 if ($ reference !== null ) {
@@ -531,7 +531,7 @@ public function delete(
531531 *
532532 * @return Insert
533533 */
534- public function insert (string $ intoTable = null ) : Insert
534+ public function insert (? string $ intoTable = null ) : Insert
535535 {
536536 $ instance = new Insert ($ this );
537537 if ($ intoTable !== null ) {
@@ -547,7 +547,7 @@ public function insert(string $intoTable = null) : Insert
547547 *
548548 * @return LoadData
549549 */
550- public function loadData (string $ intoTable = null ) : LoadData
550+ public function loadData (? string $ intoTable = null ) : LoadData
551551 {
552552 $ instance = new LoadData ($ this );
553553 if ($ intoTable !== null ) {
@@ -563,7 +563,7 @@ public function loadData(string $intoTable = null) : LoadData
563563 *
564564 * @return Replace
565565 */
566- public function replace (string $ intoTable = null ) : Replace
566+ public function replace (? string $ intoTable = null ) : Replace
567567 {
568568 $ instance = new Replace ($ this );
569569 if ($ intoTable !== null ) {
@@ -575,14 +575,14 @@ public function replace(string $intoTable = null) : Replace
575575 /**
576576 * Call a SELECT statement.
577577 *
578- * @param array<string,Closure|string>|Closure |string|null $reference
579- * @param array<string,Closure|string>|Closure |string ...$references
578+ * @param Closure| array<string,Closure|string>|string|null $reference
579+ * @param Closure| array<string,Closure|string>|string ...$references
580580 *
581581 * @return Select
582582 */
583583 public function select (
584- array | Closure | string $ reference = null ,
585- array | Closure | string ...$ references
584+ Closure | array | string | null $ reference = null ,
585+ Closure | array | string ...$ references
586586 ) : Select {
587587 $ instance = new Select ($ this );
588588 if ($ reference !== null ) {
@@ -594,14 +594,14 @@ public function select(
594594 /**
595595 * Call a UPDATE statement.
596596 *
597- * @param array<string,Closure|string>|Closure |string|null $reference
598- * @param array<string,Closure|string>|Closure |string ...$references
597+ * @param Closure| array<string,Closure|string>|string|null $reference
598+ * @param Closure| array<string,Closure|string>|string ...$references
599599 *
600600 * @return Update
601601 */
602602 public function update (
603- array | Closure | string $ reference = null ,
604- array | Closure | string ...$ references
603+ Closure | array | string | null $ reference = null ,
604+ Closure | array | string ...$ references
605605 ) : Update {
606606 $ instance = new Update ($ this );
607607 if ($ reference !== null ) {
@@ -773,7 +773,7 @@ public function protectIdentifier(string $identifier) : string
773773 * the word "NULL". If is false, "FALSE". If is true, "TRUE". If is a string,
774774 * returns the quoted string. The types int or float returns the same input value.
775775 */
776- public function quote (float | bool | int | string | null $ value ) : float | int | string
776+ public function quote (bool | float | int | string | null $ value ) : float | int | string
777777 {
778778 $ type = \gettype ($ value );
779779 if ($ type === 'string ' ) {
@@ -818,7 +818,7 @@ protected function addToDebug(Closure $function) : mixed
818818
819819 protected function finalizeAddToDebug (
820820 float $ start ,
821- string | null $ description = null
821+ ? string $ description = null
822822 ) : void {
823823 $ end = \microtime (true );
824824 $ rows = $ this ->mysqli ->affected_rows ;
0 commit comments