Mercurial > dive4elements > river
comparison flys-artifacts/src/main/java/de/intevation/flys/artifacts/FLYSArtifact.java @ 685:d45c3ddaed1b
Added a parameter 'wq_free' that determines that mode of calculation 1 (specifies if the calculation is bound to a gauge or not).
flys-artifacts/trunk@2148 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Fri, 17 Jun 2011 13:00:54 +0000 |
parents | fdc898a134a7 |
children | eab5e5089d77 |
comparison
equal
deleted
inserted
replaced
684:82eb41beb4de | 685:d45c3ddaed1b |
---|---|
704 logger.warn("You try to get Qs, but W has been inserted."); | 704 logger.warn("You try to get Qs, but W has been inserted."); |
705 return null; | 705 return null; |
706 } | 706 } |
707 } | 707 } |
708 | 708 |
709 | |
709 public boolean isQ() { | 710 public boolean isQ() { |
710 StateData mode = getData("wq_mode"); | 711 StateData mode = getData("wq_mode"); |
711 return mode != null && mode.getValue().equals("Q"); | 712 return mode != null && mode.getValue().equals("Q"); |
713 } | |
714 | |
715 | |
716 /** | |
717 * Returns true, if the parameter is set to compute data on a free range. | |
718 * Otherwise it returns false, which tells the calculation that it is bound | |
719 * to a gauge. | |
720 * | |
721 * @return true, if the calculation should compute on a free range otherwise | |
722 * false and the calculation is bound to a gauge. | |
723 */ | |
724 public boolean isFreeQ() { | |
725 StateData mode = getData("wq_free"); | |
726 String value = mode != null ? (String) mode.getValue() : null; | |
727 | |
728 if (mode == null) { | |
729 return false; | |
730 } | |
731 | |
732 return Boolean.valueOf(value); | |
712 } | 733 } |
713 | 734 |
714 | 735 |
715 /** | 736 /** |
716 * Returns the Q values based on a specified kilometer range. | 737 * Returns the Q values based on a specified kilometer range. |