Mercurial > dive4elements > river
comparison artifacts/src/main/java/org/dive4elements/river/artifacts/model/fixings/FixAnalysisEventsFacet.java @ 8202:e4606eae8ea5
sed src/**/*.java 's/logger/log/g'
author | Sascha L. Teichmann <teichmann@intevation.de> |
---|---|
date | Fri, 05 Sep 2014 12:58:17 +0200 |
parents | 08e3c22500f3 |
children | 9744ce3c3853 0a5239a1e46e |
comparison
equal
deleted
inserted
replaced
8201:4b8c5a08de04 | 8202:e4606eae8ea5 |
---|---|
29 */ | 29 */ |
30 public class FixAnalysisEventsFacet | 30 public class FixAnalysisEventsFacet |
31 extends FixingsFacet | 31 extends FixingsFacet |
32 implements FacetTypes { | 32 implements FacetTypes { |
33 | 33 |
34 /** House logger. */ | 34 /** House log. */ |
35 private static Logger logger = Logger.getLogger(FixAnalysisEventsFacet.class); | 35 private static Logger log = Logger.getLogger(FixAnalysisEventsFacet.class); |
36 | 36 |
37 /** Trivial Constructor. */ | 37 /** Trivial Constructor. */ |
38 public FixAnalysisEventsFacet() { | 38 public FixAnalysisEventsFacet() { |
39 } | 39 } |
40 | 40 |
60 * | 60 * |
61 * @return the data. | 61 * @return the data. |
62 */ | 62 */ |
63 @Override | 63 @Override |
64 public Object getData(Artifact artifact, CallContext context) { | 64 public Object getData(Artifact artifact, CallContext context) { |
65 logger.debug("FixAnalysisEventsFacet.getData"); | 65 log.debug("FixAnalysisEventsFacet.getData"); |
66 | 66 |
67 if (!(artifact instanceof D4EArtifact)) { | 67 if (!(artifact instanceof D4EArtifact)) { |
68 logger.debug("Not an instance of FixationArtifact."); | 68 log.debug("Not an instance of FixationArtifact."); |
69 return null; | 69 return null; |
70 } | 70 } |
71 D4EArtifact flys = (D4EArtifact)artifact; | 71 D4EArtifact flys = (D4EArtifact)artifact; |
72 | 72 |
73 CalculationResult res = | 73 CalculationResult res = |
81 KMIndex<AnalysisPeriod []> kmPeriods = result.getAnalysisPeriods(); | 81 KMIndex<AnalysisPeriod []> kmPeriods = result.getAnalysisPeriods(); |
82 KMIndex.Entry<AnalysisPeriod []> kmPeriodsEntry = | 82 KMIndex.Entry<AnalysisPeriod []> kmPeriodsEntry = |
83 kmPeriods.binarySearch(currentKm); | 83 kmPeriods.binarySearch(currentKm); |
84 | 84 |
85 if (kmPeriodsEntry == null) { | 85 if (kmPeriodsEntry == null) { |
86 logger.debug("getData: kmPeriodsEntry == null"); | 86 log.debug("getData: kmPeriodsEntry == null"); |
87 return null; | 87 return null; |
88 } | 88 } |
89 | 89 |
90 AnalysisPeriod[] periods = kmPeriodsEntry.getValue(); | 90 AnalysisPeriod[] periods = kmPeriodsEntry.getValue(); |
91 if (periods == null) { | 91 if (periods == null) { |
92 logger.debug("getData: periods == null"); | 92 log.debug("getData: periods == null"); |
93 return null; | 93 return null; |
94 } | 94 } |
95 int ndx = index >> 8; | 95 int ndx = index >> 8; |
96 QWD[] qwdData = periods[ndx].getQWDs(); | 96 QWD[] qwdData = periods[ndx].getQWDs(); |
97 if (qwdData == null) { | 97 if (qwdData == null) { |