public abstract class AbstractControllerConfig extends AppConfig
app.config.AppControllerConfig
.
This class provides ways to bind filters to controllers. It has coarse grain methods for binding as well as
fine grained.
See ControllerFilter
.
Filters before() methods are executed in the same order as filters are registered.
addGlobalFilters(org.javalite.activeweb.controller_filters.ControllerFilter...)
add(org.javalite.activeweb.controller_filters.ControllerFilter...)
)}
add(mew TimingFilter(), new DBConnectionFilter()).to(PostsController.class).forActions("index", "show");
Modifier and Type | Class and Description |
---|---|
class |
AbstractControllerConfig.ExcludeBuilder |
class |
AbstractControllerConfig.FilterBuilder |
Constructor and Description |
---|
AbstractControllerConfig() |
Modifier and Type | Method and Description |
---|---|
protected AbstractControllerConfig.FilterBuilder |
add(ControllerFilter... filters)
Adds a set of filters to a set of controllers.
|
protected AbstractControllerConfig.ExcludeBuilder |
addGlobalFilters(ControllerFilter... filters)
Adds filters to all controllers globally.
|
void |
completeInit() |
protected AbstractControllerConfig.FilterBuilder add(ControllerFilter... filters)
filters
- filters to be added.to()
method which accepts a controller class. The return type is not important and not used by itself.protected AbstractControllerConfig.ExcludeBuilder addGlobalFilters(ControllerFilter... filters)
... addGlobalFilters(new TimingFilter(), new DBConnectionFilter()); ...
filters
- filters to be added.public void completeInit()
completeInit
in class AppConfig
Copyright © 2016. All rights reserved.