Mercurial > dive4elements > river
annotate flys-artifacts/src/main/java/de/intevation/flys/artifacts/access/FixationArtifactAccess.java @ 3209:03fc05655258
SQ: Added artifact access stub.
flys-artifacts/trunk@4828 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Thu, 28 Jun 2012 15:06:58 +0000 |
parents | 90c4ce100ce1 |
children | ae14f412ba10 |
rev | line source |
---|---|
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
1 package de.intevation.flys.artifacts.access; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
2 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
3 import de.intevation.artifactdatabase.data.StateData; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
4 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
5 import de.intevation.flys.artifacts.FLYSArtifact; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
6 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
7 import de.intevation.flys.artifacts.model.fixings.DateRange; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
8 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
9 import java.util.Arrays; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
10 import java.util.Date; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
11 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
12 import org.apache.log4j.Logger; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
13 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
14 public class FixationArtifactAccess |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
15 extends Access |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
16 { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
17 private static Logger log = Logger.getLogger(FixationArtifactAccess.class); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
18 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
19 protected String river; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
20 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
21 protected String calculationMode; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
22 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
23 protected Double from; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
24 protected Double to; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
25 protected Double step; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
26 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
27 protected Long start; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
28 protected Long end; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
29 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
30 protected Integer qSectorStart; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
31 protected Integer qSectorEnd; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
32 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
33 protected DateRange referencePeriod; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
34 protected DateRange [] analysisPeriods; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
35 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
36 protected int [] events; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
37 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
38 protected Boolean preprocessing; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
39 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
40 protected String function; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
41 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
42 protected double [] qs; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
43 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
44 public FixationArtifactAccess() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
45 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
46 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
47 public FixationArtifactAccess(FLYSArtifact artifact) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
48 super(artifact); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
49 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
50 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
51 public String getRiver() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
52 if (river == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
53 river = getString("river"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
54 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
55 if (log.isDebugEnabled()) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
56 log.debug("river: '" + river + "'"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
57 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
58 return river; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
59 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
60 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
61 public String getCalculationMode() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
62 if (calculationMode == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
63 calculationMode = getString("calculation.mode"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
64 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
65 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
66 if (log.isDebugEnabled()) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
67 log.debug("calculationMode: '" + calculationMode + "'"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
68 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
69 return calculationMode; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
70 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
71 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
72 public Double getFrom() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
73 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
74 if (from == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
75 from = getDouble("from"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
76 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
77 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
78 if (log.isDebugEnabled()) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
79 log.debug("from: '" + from + "'"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
80 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
81 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
82 return from; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
83 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
84 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
85 public Double getTo() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
86 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
87 if (to == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
88 to = getDouble("to"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
89 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
90 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
91 if (log.isDebugEnabled()) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
92 log.debug("to: '" + to + "'"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
93 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
94 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
95 return to; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
96 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
97 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
98 public Double getStep() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
99 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
100 if (step == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
101 step = getDouble("step"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
102 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
103 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
104 if (log.isDebugEnabled()) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
105 log.debug("step: '" + step + "'"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
106 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
107 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
108 return step; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
109 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
110 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
111 public Long getStart() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
112 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
113 if (start == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
114 start = getLong("start"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
115 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
116 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
117 if (log.isDebugEnabled()) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
118 log.debug("start: '" + start + "'"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
119 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
120 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
121 return start; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
122 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
123 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
124 public Long getEnd() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
125 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
126 if (end == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
127 end = getLong("end"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
128 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
129 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
130 if (log.isDebugEnabled()) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
131 log.debug("end: '" + end + "'"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
132 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
133 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
134 return end; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
135 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
136 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
137 public Integer getQSectorStart() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
138 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
139 if (qSectorStart == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
140 qSectorStart = getInteger("q1"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
141 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
142 |
3209
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
143 if (log.isDebugEnabled()) { |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
144 log.debug("q1: '" + qSectorStart + "'"); |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
145 } |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
146 |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
147 return qSectorStart; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
148 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
149 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
150 public Integer getQSectorEnd() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
151 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
152 if (qSectorEnd == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
153 qSectorEnd = getInteger("q2"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
154 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
155 |
3209
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
156 if (log.isDebugEnabled()) { |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
157 log.debug("q2: '" + qSectorEnd + "'"); |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
158 } |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
159 |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
160 return qSectorEnd; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
161 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
162 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
163 public int [] getEvents() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
164 if (events == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
165 events = getIntArray("events"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
166 } |
3209
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
167 if (log.isDebugEnabled() && events != null) { |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
168 log.debug("events: " + Arrays.toString(events)); |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
169 } |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
170 return events; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
171 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
172 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
173 public DateRange getReferencePeriod() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
174 if (referencePeriod == null) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
175 StateData refStart = artifact.getData("ref_start"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
176 StateData refEnd = artifact.getData("ref_end"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
177 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
178 if (refStart == null || refEnd == null) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
179 log.warn("missing 'ref_start' or 'ref_start' value"); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
180 return null; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
181 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
182 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
183 try { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
184 long rs = Long.parseLong((String)refStart.getValue()); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
185 long re = Long.parseLong((String)refEnd .getValue()); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
186 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
187 if (rs > re) { long t = rs; rs = re; re = t; } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
188 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
189 Date from = new Date(rs); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
190 Date to = new Date(re); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
191 referencePeriod = new DateRange(from, to); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
192 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
193 catch (NumberFormatException nfe) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
194 log.warn("ref_start or ref_end is not an integer."); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
195 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
196 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
197 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
198 return referencePeriod; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
199 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
200 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
201 public DateRange [] getAnalysisPeriods() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
202 if (analysisPeriods == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
203 analysisPeriods = getDateRange("ana_date"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
204 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
205 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
206 return analysisPeriods; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
207 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
208 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
209 public Boolean getPreprocessing() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
210 if (preprocessing == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
211 preprocessing = getBoolean("preprocessing"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
212 } |
3209
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
213 if (log.isDebugEnabled()) { |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
214 log.debug("preprocessing: " + preprocessing); |
03fc05655258
SQ: Added artifact access stub.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3208
diff
changeset
|
215 } |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
216 return preprocessing; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
217 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
218 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
219 public String getFunction() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
220 if (function == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
221 function = getString("function"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
222 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
223 if (log.isDebugEnabled()) { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
224 log.debug("function: " + function); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
225 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
226 return function; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
227 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
228 |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
229 public double [] getQs() { |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
230 if (qs == null) { |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
231 qs = getDoubleArray("qs"); |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
232 } |
3207
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
233 |
babb0798d548
Removed dead code.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
3206
diff
changeset
|
234 if (log.isDebugEnabled() && qs != null) { |
3203
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
235 log.debug("qs: " + Arrays.toString(qs)); |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
236 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
237 return qs; |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
238 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
239 } |
1b9f791937c3
Moved FixationArtifactAccess to new access package.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
240 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 : |