Conditions | 1 |
Paths | 1 |
Total Lines | 8 |
Code Lines | 3 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
26 | public function __construct(PDOStatement $statement) |
||
27 | { |
||
28 | $this->statement = $statement; |
||
29 | // Since no more than one PDOStatement for any one connection can be safely |
||
30 | // traversed, each statement simply requests all rows at once for safety. |
||
31 | // This could be re-engineered to call fetchAll on an as-needed basis |
||
32 | $this->results = $statement->fetchAll(PDO::FETCH_ASSOC); |
||
33 | $statement->closeCursor(); |
||
34 | } |
||
46 |