Mercurial > dive4elements > river
diff flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/fixings/FixOutlierFacet.java @ 3729:e727e3ebdf85
Factored out a pure QW model to be more reusable.
flys-artifacts/trunk@5402 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Sat, 08 Sep 2012 14:19:40 +0000 |
parents | 8160e62bbb3a |
children | 26774405c884 |
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/fixings/FixOutlierFacet.java Sat Sep 08 13:36:06 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/fixings/FixOutlierFacet.java Sat Sep 08 14:19:40 2012 +0000 @@ -65,15 +65,17 @@ double currentKm = ((Double)context.getContextValue("currentKm")).doubleValue(); - KMIndex<QW []> kmQWs = result.getOutliers(); - KMIndex.Entry<QW []> qwsEntry = kmQWs.binarySearch(currentKm); + KMIndex<QWI []> kmQWs = result.getOutliers(); + KMIndex.Entry<QWI []> qwsEntry = kmQWs.binarySearch(currentKm); - QW[] qws = null; - if(qwsEntry != null) { + QWI [] qws = null; + if (qwsEntry != null) { qws = qwsEntry.getValue(); - logger.debug("Found " + (qws != null ? qws.length : 0) - + " KMIndex.Entry for km " + currentKm); + if (logger.isDebugEnabled()) { + logger.debug("Found " + (qws != null ? qws.length : 0) + + " KMIndex.Entry for km " + currentKm); + } } else { logger.debug("Found no KMIndex.Entry for km " + currentKm); @@ -81,10 +83,9 @@ return qws; } - else { - logger.warn("Not an instance of FLYSArtifact."); - return null; - } + + logger.warn("Not an instance of FLYSArtifact."); + return null; }