org.metasyntactic.net.servlet
Class ServletUtilities

java.lang.Object
  |
  +--org.metasyntactic.net.servlet.ServletUtilities

public class ServletUtilities
extends java.lang.Object


Constructor Summary
ServletUtilities()
           
 
Method Summary
static void main(java.lang.String[] args)
           
static java.util.Map parseQuery(java.lang.String query)
          Parses the query in the same way that HttpUtils.parseQueryString does, with the added feature that a get on the returned map will not return null.
static java.util.Map parseQueryAsSingletons(java.lang.String query)
          Parses the query in the same way that HttpUtils.parseQueryString does.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServletUtilities

public ServletUtilities()
Method Detail

parseQuery

public static java.util.Map parseQuery(java.lang.String query)
Parses the query in the same way that HttpUtils.parseQueryString does, with the added feature that a get on the returned map will not return null. If you ask if the string "foo" was in the query and it wasn't, an String[0] will be returned.


parseQueryAsSingletons

public static java.util.Map parseQueryAsSingletons(java.lang.String query)
Parses the query in the same way that HttpUtils.parseQueryString does. However, this method assumes that for each key/value pair, there is only a single value. So instead of returning a String[], a single String is returned.


main

public static void main(java.lang.String[] args)