changcheng / wro4j

Automatically exported from code.google.com/p/wro4j
0 stars 0 forks source link

Support for RequestHandlers concept #438

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Create RequestHandler interface:
interface RequestHandler {
  void handle(request, response);
  boolean accept();
  boolean enable();
}
The WroFilter can be configured with a list of handlers. Handlers should be 
applied before the actual processing is performed. Only one handler can be 
applied. Once a handler is applied, other handlers are skipped and processing 
is not performed. 

The default implementations of RequestHandler should be: 
ReloadCacheRequestHandler, ReloadModelRequestHandler & 
ExposeModelAsJsonRequestHandler. 

The purpose of request handlers is to plug-in custom behavior for a given 
request, like API calls.

Original issue reported on code.google.com by alex.obj...@gmail.com on 16 May 2012 at 7:10

GoogleCodeExporter commented 9 years ago
Pull request merged (with small changes) in branch 1.4.x.

Original comment by alex.obj...@gmail.com on 25 May 2012 at 2:57