This is an error 404
There are `0` results
preferences:
152.41 ms | 1399 KiB | 7 Q<?php
class IOException {
protected $file;
public function __construct($file, $message) {
parent::__construct($message);
$this->file = $file;
}
public function getFile() {
return $this->file;
}
}
class File {
protected $path;
protected $handle;
public function __construct($path) {
$this->path = $path;
}
public function open($mode) {
$this->handle = @fopen($this->path, $mode);
if (!$this->handle) {
throw new IOException($this->path, "could not open the file");
}
}
}
$file = new File("/no/file");
try {
$file->open();
} catch (IOException $io) {
$io->printStackTrace();
}
?>