private static boolean match(String patt, String s, Request req) {
      HashMap<String, String> m = new HashMap<String, String>();
      if (!UrlMatcher.match(patt, s, m)) return false;

      for (Map.Entry<String, String> e : m.entrySet()) req.set(e.getKey(), e.getValue());

      return true;
    }