private void decodeHeader(BufferedReader in, Properties pre,
			Properties parms, Properties header) throws InterruptedException {
		try {
			// Read the request line
			headLine = in.readLine();
			// System.out.println(inLine);
			if (headLine == null)
				return;
			StringTokenizer st = new StringTokenizer(headLine);
			if (!st.hasMoreTokens())
				sendError(Server.HTTP_BADREQUEST,
						"BAD REQUEST: Syntax error. Usage: GET /example/file.html");

			String method = st.nextToken();
			pre.put("method", method);

			if (!st.hasMoreTokens())
				sendError(Server.HTTP_BADREQUEST,
						"BAD REQUEST: Missing URI. Usage: GET /example/file.html");

			String uri = st.nextToken();

			// Decode parameters from the URI
			int qmi = uri.indexOf('?');
			if (qmi >= 0) {
				decodeParms(uri.substring(qmi + 1), parms);
				uri = decodePercent(uri.substring(0, qmi));
			} else
				uri = decodePercent(uri);

			// If there's another token, it's protocol version,
			// followed by HTTP headers. Ignore version but parse headers.
			// NOTE: this now forces header names lowercase since they are
			// case insensitive and vary by client.
			if (st.hasMoreTokens()) {
				String line = in.readLine();
				while (line != null && line.trim().length() > 0) {
					int p = line.indexOf(':');
					if (p >= 0)
						header.put(line.substring(0, p).trim().toLowerCase(),
								line.substring(p + 1).trim());
					line = in.readLine();
				}
			}

			pre.put("uri", uri);
		} catch (IOException ioe) {
			sendError(Server.HTTP_INTERNALERROR,
					"SERVER INTERNAL ERROR: IOException: " + ioe.getMessage());
		}
	}