comparison artifacts/src/main/java/org/dive4elements/river/artifacts/model/fixings/FixRealizingCalculationExtended.java @ 9415:9744ce3c3853

Rework of fixanalysis computation and dWt and WQ facets. Got rid of strange remapping and bitshifting code by explicitely saving the column information and using it in the facets. The facets also put the valid station range into their xml-metadata
author gernotbelger
date Thu, 16 Aug 2018 16:27:53 +0200
parents 7565d7dce850
children
comparison
equal deleted inserted replaced
9414:096f151a0a9f 9415:9744ce3c3853
14 import java.util.List; 14 import java.util.List;
15 import java.util.SortedSet; 15 import java.util.SortedSet;
16 import java.util.TreeSet; 16 import java.util.TreeSet;
17 17
18 import org.dive4elements.river.artifacts.access.FixRealizingAccess; 18 import org.dive4elements.river.artifacts.access.FixRealizingAccess;
19 import org.dive4elements.river.artifacts.model.FixingsOverview;
20 import org.dive4elements.river.artifacts.model.FixingsOverviewFactory;
21 19
22 /** 20 /**
23 * REMARK: this inheritance is only needed, beause changing the orignal calculation will probably break the 21 * REMARK: this inheritance is only needed, beause changing the orignal calculation will probably break the
24 * serialization of the artifact.... 22 * serialization of the artifact....
25 * 23 *
38 36
39 final SortedSet<Integer> years = new TreeSet<>(); 37 final SortedSet<Integer> years = new TreeSet<>();
40 38
41 final Calendar cal = Calendar.getInstance(); 39 final Calendar cal = Calendar.getInstance();
42 40
43 final List<Column> columns = getEventColumns(overview, cc); 41 final List<FixingColumnWithData> columns = getEventColumns(overview, cc);
44 for (final Column column : columns) { 42 for (final FixingColumnWithData column : columns) {
45 final Date date = column.getDate(); 43 final Date date = column.getDate();
46 cal.setTime(date); 44 cal.setTime(date);
47 45
48 final int year = cal.get(Calendar.YEAR); 46 final int year = cal.get(Calendar.YEAR);
49 years.add(year); 47 years.add(year);

http://dive4elements.wald.intevation.org