protected void createInterceptorTable(List<Interceptor> interceptors) {
   table().attr("cellpadding", "0", "cellspacing", "0", "border", "0", "class", "display");
   thead();
   tr();
   createThs("Name", "Priority");
   end();
   end();
   tbody();
   for (Interceptor i : interceptors) {
     tr();
     createTds(i.getDisplayName(), "" + i.getPriority());
     end();
   }
   end();
   end();
 }
Ejemplo n.º 2
0
 /**
  * Called after parsing is complete and this has been added to the object tree (whose root is
  * Router).
  */
 public void init(Router router) throws Exception {
   init();
   for (Interceptor i : interceptors) i.init(router);
 }
 private Outcome getOutcome(Request request, Interceptor interceptor, String fileName)
     throws Exception {
   request.setBodyContent(getContent(fileName));
   exc.setRequest(request);
   return interceptor.handleRequest(exc);
 }