| @@ 475-492 (lines=18) @@ | ||
| 472 | * |
|
| 473 | * @return array |
|
| 474 | */ |
|
| 475 | public function &fetchAllArray(): array |
|
| 476 | { |
|
| 477 | // init |
|
| 478 | $data = []; |
|
| 479 | ||
| 480 | if ($this->is_empty()) { |
|
| 481 | return $data; |
|
| 482 | } |
|
| 483 | ||
| 484 | $this->reset(); |
|
| 485 | ||
| 486 | /** @noinspection PhpAssignmentInConditionInspection */ |
|
| 487 | while ($row = $this->fetch_assoc()) { |
|
| 488 | $data[] = $this->cast($row); |
|
| 489 | } |
|
| 490 | ||
| 491 | return $data; |
|
| 492 | } |
|
| 493 | ||
| 494 | /** |
|
| 495 | * Fetch all results as "Arrayy"-object. |
|
| @@ 499-516 (lines=18) @@ | ||
| 496 | * |
|
| 497 | * @return Arrayy |
|
| 498 | */ |
|
| 499 | public function &fetchAllArrayy(): Arrayy |
|
| 500 | { |
|
| 501 | // init |
|
| 502 | $arrayy = Arrayy::create(); |
|
| 503 | ||
| 504 | if ($this->is_empty()) { |
|
| 505 | return $arrayy; |
|
| 506 | } |
|
| 507 | ||
| 508 | $this->reset(); |
|
| 509 | ||
| 510 | /** @noinspection PhpAssignmentInConditionInspection */ |
|
| 511 | while ($row = $this->fetch_assoc()) { |
|
| 512 | $arrayy[] = $this->cast($row); |
|
| 513 | } |
|
| 514 | ||
| 515 | return $arrayy; |
|
| 516 | } |
|
| 517 | ||
| 518 | /** |
|
| 519 | * Fetch all results as "Arrayy"-object. |
|