ServletFilterRequest extends DiscFilterRequest { public void setUri(URI uri) { parent.setUri(uri); } ServletFilterRequest(ServletRequest parent); void setUri(URI uri); @Override String getMethod(); @Override void setRemoteAddr(String remoteIpAddress); @Override Enumeration<String> getAttributeNames(); @Override Object getAttribute(String name); @Override void setAttribute(String name, Object value); @Override boolean containsAttribute(String name); @Override void removeAttribute(String name); @Override String getParameter(String name); @Override Enumeration<String> getParameterNames(); @Override void addHeader(String name, String value); @Override String getHeader(String name); @Override Enumeration<String> getHeaderNames(); List<String> getHeaderNamesAsList(); @Override Enumeration<String> getHeaders(String name); @Override List<String> getHeadersAsList(String name); @Override void setHeaders(String name, String value); @Override void setHeaders(String name, List<String> values); @Override Principal getUserPrincipal(); @Override void setUserPrincipal(Principal principal); @Override List<X509Certificate> getClientCertificateChain(); @Override void removeHeaders(String name); @Override void clearCookies(); @Override void setCharacterEncoding(String encoding);  }
@Test public void uri_can_be_set() throws Exception { URI newUri = new URI("http", null, host, port + 1, path, paramName + "=" + paramValue, null); filterRequest.setUri(newUri); assertEquals(filterRequest.getUri(), newUri); assertEquals(parentRequest.getUri(), newUri); }