private final Server server;
public ExampleServer(Module... modules) {
ServletContextHandler handler = new ServletContextHandler();
handler.setContextPath("/");
handler.addEventListener(new GuiceInjectorServletContextListener(modules));
handler.addFilter(GuiceFilter.class, "/*", EnumSet.allOf(DispatcherType.class));
handler.addServlet(DefaultServlet.class, "/");
server = new Server(0);
server.setHandler(handler);