public function readLine()
    {
        $line = null;
        while (($ch = $this->readChar()) !== -1) {
            if ($ch === "\n") {
                break;
            }
            $line .= $ch;
        }

        // Warning : Not considering an empty line as an EOF
        if ($line === null && $ch !== -1) {
            return "";
        }

        return $line;
    }