| @@ 51-60 (lines=10) @@ | ||
| 48 | /** |
|
| 49 | * @throws Exception |
|
| 50 | */ |
|
| 51 | public function rewind() |
|
| 52 | { |
|
| 53 | if (!file_exists($this->path)) { |
|
| 54 | throw new Exception("Le fichier specifie n'existe pas ou est introuvable"); |
|
| 55 | } |
|
| 56 | $this->fHandle = fopen($this->path, "r"); |
|
| 57 | rewind($this->fHandle); |
|
| 58 | $this->next(); |
|
| 59 | $this->line = 0; |
|
| 60 | } |
|
| 61 | ||
| 62 | /** |
|
| 63 | * @return mixed |
|
| @@ 33-42 (lines=10) @@ | ||
| 30 | $this->path = $path; |
|
| 31 | } |
|
| 32 | ||
| 33 | public function rewind() |
|
| 34 | { |
|
| 35 | if (!file_exists($this->path)) { |
|
| 36 | throw new Exception("Le fichier specifie n'existe pas ou est introuvable"); |
|
| 37 | } |
|
| 38 | $this->line = -1; |
|
| 39 | $this->fHandle = fopen($this->path, "r"); |
|
| 40 | rewind($this->fHandle); |
|
| 41 | $this->next(); |
|
| 42 | } |
|
| 43 | ||
| 44 | public function current() |
|
| 45 | { |
|