# 配置代码

# JFinal配置

在jfinal中,我们可以通过继承JFinalConfig来实现对jfinal的web项目进行配置。详情参考:JFinalConfig (opens new window)
不过在Jboot下,其对JFinalConfig进行了卦装,配置方法为通过继承JbootAppListenerBase来实现。详情参考:JBootConfig (opens new window)

示例:

public class JwebConfig extends JbootAppListenerBase {
    @Override
    public void onHandlerConfig(JfinalHandlers handlers) {
    }

    @Override
    public void onInit() {
    }

    @Override
    public void onConstantConfig(Constants constants) {
    }

    @Override
    public void onRouteConfig(Routes routes) {
    }

    @Override
    public void onEngineConfig(Engine engine) {
    }

    @Override
    public void onPluginConfig(JfinalPlugins plugins) {
    }

    @Override
    public void onInterceptorConfig(Interceptors interceptors) {
    }

    @Override
    public void onStartBefore() {
    }

    @Override
    public void onStart() {
    }

    @Override
    public void onStartFinish() {
    }

    @Override
    public void onStop() {
    }
}

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46