Parcourir la source

Detail in spec in IRNG

smelc il y a 6 ans
Parent
commit
73368aad07
1 fichiers modifiés avec 7 ajouts et 0 suppressions
  1. 7 0
      squidlib-util/src/main/java/squidpony/squidmath/IRNG.java

+ 7 - 0
squidlib-util/src/main/java/squidpony/squidmath/IRNG.java

@@ -20,8 +20,15 @@ public interface IRNG {
 	/**
 	/**
 	 * Returns a value between min (inclusive) and max (exclusive).
 	 * Returns a value between min (inclusive) and max (exclusive).
 	 *
 	 *
+	 * <p>
 	 * The inclusive and exclusive behavior is to match the behavior of the similar
 	 * The inclusive and exclusive behavior is to match the behavior of the similar
 	 * method that deals with floating point values.
 	 * method that deals with floating point values.
+	 * </p>
+	 * 
+	 * <p>
+	 * If {@code min} and {@code max} happen to be the same, {@code min} is returned
+	 * (breaking the exclusive behavior, but it's convenient to do so).
+	 * </p>
 	 *
 	 *
 	 * @param min
 	 * @param min
 	 *            the minimum bound on the return value (inclusive)
 	 *            the minimum bound on the return value (inclusive)