public String readLine() throws IOException {
		final StringBuilder lineBuilder = new StringBuilder(lengthOfLastLine);
		final StringBuilder eol = new StringBuilder(2);

		int status = reader.read(characterBuffer, 0, 1);

		if (status == -1) {
			lastLineByteCount = 0;
			return null;
		}

		while (status != -1) {
			final char c = characterBuffer[0];

			if (c == '\n') {
				eol.append(c);
				break;
			}

			if (c == '\r') {
				eol.append(c);
			} else {
				lineBuilder.append(c);
			}

			status = reader.read(characterBuffer, 0, 1);
		}

		lengthOfLastLine = lineBuilder.length();

		// For single-byte charsets (ISO-8859-1, ASCII etc) lastLineByteCount == lengthOfLastLine
		if (multibyte) {
			final String line = lineBuilder.toString();
			lastLineByteCount = line.getBytes(encoding).length + eol.toString().getBytes(encoding).length;
			return line;
		}

		lastLineByteCount = lengthOfLastLine + eol.length();
		return lineBuilder.toString();
	}