summaryrefslogtreecommitdiff
path: root/BJC-Utils2/src/main/java/bjc/utils/gen/WeightedRandom.java
diff options
context:
space:
mode:
authorbculkin2442 <bjculkin@mix.wvu.edu>2016-05-10 16:02:45 -0400
committerbculkin2442 <bjculkin@mix.wvu.edu>2016-05-10 16:02:45 -0400
commit61fd71f69e080790da722e0e03b71ecd7c2538a2 (patch)
treee5c1150b27b84d550f807e44ac82688216451f00 /BJC-Utils2/src/main/java/bjc/utils/gen/WeightedRandom.java
parent87ae1dfc8d8cb7b51d7bda4750ce841bbe691cfc (diff)
General update
Diffstat (limited to 'BJC-Utils2/src/main/java/bjc/utils/gen/WeightedRandom.java')
-rw-r--r--BJC-Utils2/src/main/java/bjc/utils/gen/WeightedRandom.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/BJC-Utils2/src/main/java/bjc/utils/gen/WeightedRandom.java b/BJC-Utils2/src/main/java/bjc/utils/gen/WeightedRandom.java
index 43d9928..7c6af23 100644
--- a/BJC-Utils2/src/main/java/bjc/utils/gen/WeightedRandom.java
+++ b/BJC-Utils2/src/main/java/bjc/utils/gen/WeightedRandom.java
@@ -6,7 +6,7 @@ import bjc.utils.data.IHolder;
import bjc.utils.data.IPair;
import bjc.utils.data.Identity;
import bjc.utils.funcdata.FunctionalList;
-import bjc.utils.funcdata.IFunctionalList;
+import bjc.utils.funcdata.IList;
/**
* Represents a random number generator where certain results are weighted
@@ -21,12 +21,12 @@ public class WeightedRandom<E> {
/**
* The list of probabilities for each result
*/
- private IFunctionalList<Integer> probabilities;
+ private IList<Integer> probabilities;
/**
* The list of possible results to pick from
*/
- private IFunctionalList<E> results;
+ private IList<E> results;
/**
* The source for any needed random numbers
@@ -103,7 +103,7 @@ public class WeightedRandom<E> {
*
* @return A list of all the values that can be generated
*/
- public IFunctionalList<E> getResults() {
+ public IList<E> getResults() {
return results;
}
@@ -113,7 +113,7 @@ public class WeightedRandom<E> {
*
* @return A list of pairs of values and value probabilities
*/
- public IFunctionalList<IPair<Integer, E>> getValues() {
+ public IList<IPair<Integer, E>> getValues() {
return probabilities.pairWith(results);
}
} \ No newline at end of file