Connection.php
2 years ago
Converter.php
2 years ago
Driver.php
2 years ago
Middleware.php
2 years ago
OptimizeFlags.php
2 years ago
Result.php
2 years ago
Statement.php
2 years ago
index.php
2 years ago
Result.php
40 lines
| 1 | <?php |
| 2 | declare (strict_types=1); |
| 3 | namespace MailPoetVendor\Doctrine\DBAL\Portability; |
| 4 | if (!defined('ABSPATH')) exit; |
| 5 | use MailPoetVendor\Doctrine\DBAL\Driver\Middleware\AbstractResultMiddleware; |
| 6 | use MailPoetVendor\Doctrine\DBAL\Driver\Result as ResultInterface; |
| 7 | final class Result extends AbstractResultMiddleware |
| 8 | { |
| 9 | private Converter $converter; |
| 10 | public function __construct(ResultInterface $result, Converter $converter) |
| 11 | { |
| 12 | parent::__construct($result); |
| 13 | $this->converter = $converter; |
| 14 | } |
| 15 | public function fetchNumeric() |
| 16 | { |
| 17 | return $this->converter->convertNumeric(parent::fetchNumeric()); |
| 18 | } |
| 19 | public function fetchAssociative() |
| 20 | { |
| 21 | return $this->converter->convertAssociative(parent::fetchAssociative()); |
| 22 | } |
| 23 | public function fetchOne() |
| 24 | { |
| 25 | return $this->converter->convertOne(parent::fetchOne()); |
| 26 | } |
| 27 | public function fetchAllNumeric() : array |
| 28 | { |
| 29 | return $this->converter->convertAllNumeric(parent::fetchAllNumeric()); |
| 30 | } |
| 31 | public function fetchAllAssociative() : array |
| 32 | { |
| 33 | return $this->converter->convertAllAssociative(parent::fetchAllAssociative()); |
| 34 | } |
| 35 | public function fetchFirstColumn() : array |
| 36 | { |
| 37 | return $this->converter->convertFirstColumn(parent::fetchFirstColumn()); |
| 38 | } |
| 39 | } |
| 40 |