Logo Search packages:      
Sourcecode: jaminid version File versions  Download package

void com::prolixtech::jaminid::Request::processParamString ( String  paramStringL  )  [inline, private]

processes a parameter string for HTTP query ? parameters

Parameters:
paramStringL 

Definition at line 269 of file Request.java.

References getHeader(), and unEscape().

Referenced by setMethodLine().

                                                         {
        try {
            String cookie = (String) this.getHeader().get("Cookie");
            if (cookie != null) {
                String cookieparts[] = cookie.split(";");
                for (int i = 0; i < cookieparts.length; i++) {

                    cookieparts[i] = cookieparts[i].trim();

                    if (cookieparts[i].indexOf("=") > 0) {

                        String valuepair[] = cookieparts[i].split("=");
                        if (valuepair.length == 2) {
                            this.paramMap.put(valuepair[0].trim(), valuepair[1]
                                    .trim());
                        }
                    }
                }

            }
        } catch (Exception e) {
            SingletonLogger.Instance().http(this, "Error processing cookie" + e);
            e.printStackTrace();
        }

        String[] comps = paramStringL.split("&");
        for (int i = 0; i < comps.length; i++) {
            int equalsLoc = comps[i].indexOf("=");
            if (equalsLoc > 0) {
                this.paramMap.put(comps[i].substring(0, equalsLoc),
                        unEscape(comps[i].substring(equalsLoc + 1)));
            } else {
                this.paramMap.put(comps[i], "");
            }
        }
    }


Generated by  Doxygen 1.6.0   Back to index