Mercurial > dive4elements > river
comparison artifacts/src/main/java/org/dive4elements/river/artifacts/model/WQ.java @ 6309:ebba1a795d76
Correctly set the reference system after conversion
author | Andre Heinecke <aheinecke@intevation.de> |
---|---|
date | Wed, 12 Jun 2013 17:45:35 +0200 |
parents | d5af7b17efc2 |
children | fe32a7f9655e |
comparison
equal
deleted
inserted
replaced
6308:aa4c13220fa0 | 6309:ebba1a795d76 |
---|---|
119 // Do nothing | 119 // Do nothing |
120 return wq; | 120 return wq; |
121 } | 121 } |
122 // If we convert we work on a copy to avoid side effects. | 122 // If we convert we work on a copy to avoid side effects. |
123 WQ ret = new WQ(wq.size(), wq.getName()); | 123 WQ ret = new WQ(wq.size(), wq.getName()); |
124 ret.setReferenceSystem(wq.CENTIMETER_AT_GAUGE); | |
124 | 125 |
125 // When we convert and have a datum we have a calculated | 126 // When we convert and have a datum we have a calculated |
126 // result at a gauge so we must subtract the datum. | 127 // result at a gauge so we must subtract the datum. |
127 double subtractDatum = datum == null ? 0 : datum.doubleValue(); | 128 double subtractDatum = datum == null ? 0 : datum.doubleValue(); |
128 for (int i=0; i < wq.size(); i++) { | 129 for (int i=0; i < wq.size(); i++) { |