/[projects]/android/TrainInfoService/src/dk/thoerup/traininfoservice/TraininfoSettings.java
ViewVC logotype

Annotation of /android/TrainInfoService/src/dk/thoerup/traininfoservice/TraininfoSettings.java

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1607 - (hide annotations) (download)
Tue Oct 4 17:35:31 2011 UTC (12 years, 7 months ago) by torben
File size: 1301 byte(s)
make the sending of mails configurable
1 torben 1303 package dk.thoerup.traininfoservice;
2    
3 torben 1341 import java.util.logging.Logger;
4    
5 torben 1340 import javax.servlet.ServletContext;
6    
7 torben 1316 import dk.thoerup.circuitbreaker.config.BreakerConfig;
8 torben 1320 import dk.thoerup.webconfig.ConfigVariable;
9 torben 1340 import dk.thoerup.webconfig.ContextConfigLoader;
10 torben 1344 import dk.thoerup.webconfig.ReloadConfigMethod;
11 torben 1303
12 torben 1316
13     public class TraininfoSettings implements BreakerConfig{
14 torben 1372 public enum Backend {
15     Azure,
16     Mobile
17     }
18 torben 1303
19 torben 1341 Logger logger = Logger.getLogger(TraininfoSettings.class.getName() );
20    
21 torben 1320 @ConfigVariable
22 torben 1372 Backend backend;
23 torben 1303
24 torben 1325 @ConfigVariable(description = "Circuitbreaker", readonly = true)
25 torben 1303 int banedk_threshold;
26    
27 torben 1325 @ConfigVariable(readonly = true)
28 torben 1303 int banedk_timeout;
29    
30 torben 1325 @ConfigVariable(readonly = true)
31 torben 1303 int cache_timeout;
32    
33 torben 1320 @ConfigVariable(readonly = true)
34 torben 1303 int stats_interval;
35    
36 torben 1320 @ConfigVariable
37 torben 1303 int reply_timeout;
38 torben 1345
39 torben 1607 @ConfigVariable
40     String mail_recipient;
41    
42 torben 1303
43 torben 1372 public Backend getBackend() {
44     return backend;
45 torben 1303 }
46    
47    
48     public int getCacheTimeout() {
49     return cache_timeout;
50     }
51 torben 1316
52 torben 1303 public int getStatsInterval() {
53     return stats_interval;
54 torben 1316 }
55 torben 1303
56     public int getReplyTimeout() {
57     return reply_timeout;
58     }
59 torben 1316
60     @Override
61     public int getTreshold() {
62     return banedk_threshold;
63     }
64    
65     @Override
66     public int getTimeout() {
67     return banedk_timeout;
68     }
69 torben 1607
70     public String getMailRecipient() {
71     return mail_recipient;
72     }
73 torben 1303 }

  ViewVC Help
Powered by ViewVC 1.1.20