int port = s.getLocalPort();
s.close();
server = new Server( port );
ResourceHandler resource_handler = new ResourceHandler()
{
@Override
public void handle( String target, HttpServletRequest request, HttpServletResponse response, int dispatch )
throws IOException, ServletException
{
// System.out.print( "JETTY: " + target );
super.handle( target, request, response, dispatch );
// System.out.println( " :: " + ( (Response) response ).getStatus() );
}
};
resource_handler.setResourceBase( fakeCentral.getAbsolutePath() );
HandlerList handlers = new HandlerList();
handlers.setHandlers( new Handler[] { resource_handler, new DefaultHandler() } );
server.setHandler( handlers );
// System.out.print( "JETTY Started on port: " + port );