public String getContextHref() { String serverPort = (port == 80) ? "" : ":" + port.ToString(); return "http://" + host + serverPort + servletPath; }