comparison artifacts/src/main/java/org/dive4elements/river/artifacts/bundu/BunduResultType.java @ 9480:7228bd10a8cc

Fixed bundu bzws bedheightfinder todos, added types for excavation volume and costs total
author mschaefer
date Mon, 10 Sep 2018 17:06:23 +0200
parents 9e471031cc1e
children 3fa8551c3d1b
comparison
equal deleted inserted replaced
9479:2b83d3a96703 9480:7228bd10a8cc
110 @Override 110 @Override
111 protected NumberFormat createFormatter(final CallContext context) { 111 protected NumberFormat createFormatter(final CallContext context) {
112 throw new UnsupportedOperationException(); 112 throw new UnsupportedOperationException();
113 } 113 }
114 }; 114 };
115
116 // TODO missVolumeTotal und missMassTotal differenzieren in Gesamtsumme und Feld1-10-Summe
115 public static final BunduResultType missVolumeTotal = new BunduResultType(I18NStrings.UNIT_CUBIC_M, "bundu.export.bezugswst.csv.meta.miss.volume.total") { 117 public static final BunduResultType missVolumeTotal = new BunduResultType(I18NStrings.UNIT_CUBIC_M, "bundu.export.bezugswst.csv.meta.miss.volume.total") {
116 private static final long serialVersionUID = 1L; 118 private static final long serialVersionUID = 1L;
117 119
118 @Override 120 @Override
119 public String exportValue(final CallContext context, final Object value) { 121 public String exportValue(final CallContext context, final Object value) {
172 protected NumberFormat createFormatter(final CallContext context) { 174 protected NumberFormat createFormatter(final CallContext context) {
173 return Formatter.getCurrencyFormat(context); 175 return Formatter.getCurrencyFormat(context);
174 } 176 }
175 }; 177 };
176 178
179 public static final BunduResultType excavationVolumeTotal = new BunduResultType(I18NStrings.UNIT_CUBIC_M,
180 "bundu.export.bezugswst.csv.meta.miss.excavationtotal", "bundu.export.bezugswst.pdf.meta.miss.excavationtotal") {
181 private static final long serialVersionUID = 1L;
182
183 @Override
184 public String exportValue(final CallContext context, final Object value) {
185 final double doubleValue = asDouble(value);
186 return exportDoubleValue(context, doubleValue);
187 }
188
189 @Override
190 protected NumberFormat createFormatter(final CallContext context) {
191 return Formatter.getIntegerFormatter(context);
192 }
193 };
194
195 public static final BunduResultType excavationCostsTotal = new BunduResultType(I18NStrings.UNIT_EURO, "bundu.export.bezugswst.csv.meta.miss.coststotal",
196 "bundu.export.bezugswst.pdf.meta.miss.coststotal") {
197 private static final long serialVersionUID = 1L;
198
199 @Override
200 public String exportValue(final CallContext context, final Object value) {
201 final double doubleValue = asDouble(value);
202 return exportDoubleValue(context, doubleValue);
203 }
204
205 @Override
206 protected NumberFormat createFormatter(final CallContext context) {
207 return Formatter.getCurrencyFormat(context);
208 }
209 };
210
177 public static final BunduResultType channelWidth = new BunduResultType(I18NStrings.UNIT_M, "bundu.export.bezugswst.csv.meta.miss.channel.width", 211 public static final BunduResultType channelWidth = new BunduResultType(I18NStrings.UNIT_M, "bundu.export.bezugswst.csv.meta.miss.channel.width",
178 "bundu.export.bezugswst.pdf.meta.miss.channel.width") { 212 "bundu.export.bezugswst.pdf.meta.miss.channel.width") {
179 private static final long serialVersionUID = 1L; 213 private static final long serialVersionUID = 1L;
180 214
181 @Override 215 @Override

http://dive4elements.wald.intevation.org