Skip to content

Commit 4dfad3b

Browse files
committed
docs: fix @return type
1 parent 14a8971 commit 4dfad3b

File tree

8 files changed

+24
-14
lines changed

8 files changed

+24
-14
lines changed

system/Database/BaseResult.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -497,6 +497,8 @@ abstract public function getFieldData(): array;
497497

498498
/**
499499
* Frees the current result.
500+
*
501+
* @return void
500502
*/
501503
abstract public function freeResult();
502504

@@ -505,7 +507,7 @@ abstract public function freeResult();
505507
* internally before fetching results to make sure the result set
506508
* starts at zero.
507509
*
508-
* @return mixed
510+
* @return bool
509511
*/
510512
abstract public function dataSeek(int $n = 0);
511513

@@ -514,7 +516,7 @@ abstract public function dataSeek(int $n = 0);
514516
*
515517
* Overridden by driver classes.
516518
*
517-
* @return mixed
519+
* @return array|false|null
518520
*/
519521
abstract protected function fetchAssoc();
520522

@@ -523,7 +525,7 @@ abstract protected function fetchAssoc();
523525
*
524526
* Overridden by child classes.
525527
*
526-
* @return object
528+
* @return Entity|false|object|stdClass
527529
*/
528530
abstract protected function fetchObject(string $className = 'stdClass');
529531
}

system/Database/MySQLi/Result.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,8 @@ public function getFieldData(): array
103103

104104
/**
105105
* Frees the current result.
106+
*
107+
* @return void
106108
*/
107109
public function freeResult()
108110
{
@@ -117,7 +119,7 @@ public function freeResult()
117119
* internally before fetching results to make sure the result set
118120
* starts at zero.
119121
*
120-
* @return mixed
122+
* @return bool
121123
*/
122124
public function dataSeek(int $n = 0)
123125
{

system/Database/OCI8/Result.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ public function dataSeek(int $n = 0)
8080
*
8181
* Overridden by driver classes.
8282
*
83-
* @return mixed
83+
* @return array|false
8484
*/
8585
protected function fetchAssoc()
8686
{

system/Database/Postgre/Result.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,8 @@ public function getFieldData(): array
6969

7070
/**
7171
* Frees the current result.
72+
*
73+
* @return void
7274
*/
7375
public function freeResult()
7476
{
@@ -83,7 +85,7 @@ public function freeResult()
8385
* internally before fetching results to make sure the result set
8486
* starts at zero.
8587
*
86-
* @return mixed
88+
* @return bool
8789
*/
8890
public function dataSeek(int $n = 0)
8991
{
@@ -95,7 +97,7 @@ public function dataSeek(int $n = 0)
9597
*
9698
* Overridden by driver classes.
9799
*
98-
* @return mixed
100+
* @return array|false
99101
*/
100102
protected function fetchAssoc()
101103
{

system/Database/ResultInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public function getResult(string $type = 'object'): array;
2727
*
2828
* @param string $className The name of the class to use.
2929
*
30-
* @return mixed
30+
* @return array
3131
*/
3232
public function getCustomResultObject(string $className);
3333

system/Database/SQLSRV/Result.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,8 @@ public function getFieldData(): array
103103

104104
/**
105105
* Frees the current result.
106+
*
107+
* @return void
106108
*/
107109
public function freeResult()
108110
{
@@ -117,7 +119,7 @@ public function freeResult()
117119
* internally before fetching results to make sure the result set
118120
* starts at zero.
119121
*
120-
* @return mixed
122+
* @return bool
121123
*/
122124
public function dataSeek(int $n = 0)
123125
{
@@ -137,7 +139,7 @@ public function dataSeek(int $n = 0)
137139
*
138140
* Overridden by driver classes.
139141
*
140-
* @return mixed
142+
* @return array|false|null
141143
*/
142144
protected function fetchAssoc()
143145
{

system/Database/SQLite3/Result.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,8 @@ public function getFieldData(): array
8080

8181
/**
8282
* Frees the current result.
83+
*
84+
* @return void
8385
*/
8486
public function freeResult()
8587
{
@@ -94,7 +96,7 @@ public function freeResult()
9496
* internally before fetching results to make sure the result set
9597
* starts at zero.
9698
*
97-
* @return mixed
99+
* @return bool
98100
*
99101
* @throws DatabaseException
100102
*/
@@ -112,7 +114,7 @@ public function dataSeek(int $n = 0)
112114
*
113115
* Overridden by driver classes.
114116
*
115-
* @return mixed
117+
* @return array|false
116118
*/
117119
protected function fetchAssoc()
118120
{

system/Test/Mock/MockResult.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public function getFieldData(): array
4646
/**
4747
* Frees the current result.
4848
*
49-
* @return mixed
49+
* @return void
5050
*/
5151
public function freeResult()
5252
{
@@ -59,7 +59,7 @@ public function freeResult()
5959
*
6060
* @param int $n
6161
*
62-
* @return mixed
62+
* @return bool
6363
*/
6464
public function dataSeek($n = 0)
6565
{

0 commit comments

Comments
 (0)