Mercurial > dive4elements > gnv-client
diff gnv-artifacts/src/main/java/de/intevation/gnv/math/HeightValue.java @ 807:a645bd23c1c8
Added more javadoc. Removed trailing whitespace.
gnv-artifacts/trunk@889 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Thu, 08 Apr 2010 15:24:45 +0000 |
parents | 6cff63d0c434 |
children | f953c9a559d8 |
line wrap: on
line diff
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/math/HeightValue.java Thu Apr 08 13:10:39 2010 +0000 +++ b/gnv-artifacts/src/main/java/de/intevation/gnv/math/HeightValue.java Thu Apr 08 15:24:45 2010 +0000 @@ -5,12 +5,19 @@ import java.util.Comparator; /** + * An attributed height value. It holds a z value, a parameter value + * and a layer index. + * * @author <a href="mailto:ingo.weinzierl@intevation.de">Ingo Weinzierl</a> * @author <a href="mailto:sascha.teichmann@intevation.de">Sascha L. Teichmann</a> */ public class HeightValue implements Serializable { + /** + * Comparator to sort <code>HeightValue</code>s by their z value + * in reversed order. + */ public static final Comparator INV_Z_COMPARATOR = new Comparator() { public int compare(Object a, Object b) { HeightValue ha = (HeightValue)a; @@ -21,24 +28,54 @@ } }; + /** + * The height value. + */ public double z; + + /** + * The parameter value. + */ public double v; + + /** + * The layer index; + */ public int k; + /** + * Constructor to create a HeightValue with a given height, + * parameter value and layer index. + * @param z The height. + * @param v The parameter value. + * @param k The layer index. + */ public HeightValue(double z, double v, int k) { this.z = z; this.v = v; this.k = k; } + /** + * Return the height of this HeightValue. + * @return the height. + */ public double getZ() { return z; } + /** + * Return the parameter value of this HeightValue. + * @return The parameter value. + */ public double getV() { return v; } + /** + * Returns the layer index of this HeightValue. + * @return The layer index. + */ public double getK() { return k; }