Mercurial > dive4elements > river
diff flys-artifacts/src/main/java/de/intevation/flys/artifacts/FLYSArtifact.java @ 320:a8e7c351bdf1
The getGauge() method of the FLYSArtifact returns the first gauge based on the given stationing now.
flys-artifacts/trunk@1712 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Mon, 18 Apr 2011 07:39:17 +0000 |
parents | 8f40a57229c3 |
children | 9581b88f2920 |
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/FLYSArtifact.java Fri Apr 15 13:47:10 2011 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/FLYSArtifact.java Mon Apr 18 07:39:17 2011 +0000 @@ -487,10 +487,13 @@ logger.debug("... distance: " + dist[0] + " - " + dist[1]); } - List<Gauge> gauges = river.getGauges(); + Gauge gauge = river.determineGauge(dist[0], dist[1]); + gauge = null; - // TODO Search the desired gauge! - return gauges.get(0); + String name = gauge != null ? gauge.getName() : "'n/a"; + logger.debug("Found gauge: " + name); + + return gauge; } } // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :