| Conditions | 2 |
| Paths | 2 |
| Total Lines | 27 |
| Code Lines | 18 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 21 | public function getAllContinents() { |
||
| 22 | $stmt = \AL\Db\execute_query( |
||
| 23 | "ContinentDAO: getAllContinents", |
||
| 24 | $this->mysqli, |
||
| 25 | "SELECT continent_id, continent_name |
||
| 26 | FROM continent |
||
| 27 | ORDER BY continent_id ASC", |
||
| 28 | null, null |
||
| 29 | ); |
||
| 30 | |||
| 31 | \AL\Db\bind_result( |
||
| 32 | "ContinentDAO: getAllContinents", |
||
| 33 | $stmt, |
||
| 34 | $id, $name |
||
| 35 | ); |
||
| 36 | |||
| 37 | $continents = []; |
||
| 38 | while ($stmt->fetch()) { |
||
| 39 | $continents[] = new \AL\Common\Model\Continent\Continent( |
||
| 40 | $id, |
||
| 41 | $name |
||
| 42 | ); |
||
| 43 | } |
||
| 44 | |||
| 45 | $stmt->close(); |
||
| 46 | |||
| 47 | return $continents; |
||
| 48 | } |
||
| 50 |