Package | Description |
---|---|
squidpony.squidmath |
A very broad package containing random number generators, geometry tools, data structures, and noise functions.
|
Modifier and Type | Field and Description |
---|---|
java.util.ArrayList<ProbabilityTable<T>> |
ProbabilityTable.extraTable
The list of items that can be produced indirectly from
random() (looking up values from inside
the nested tables). |
Modifier and Type | Method and Description |
---|---|
ProbabilityTable<T> |
ProbabilityTable.add(ProbabilityTable<T> table,
int weight)
Adds the given probability table as a possible set of results for this table.
|
ProbabilityTable<T> |
ProbabilityTable.add(T item,
int weight)
Adds the given item to the table.
|
ProbabilityTable<T> |
ProbabilityTable.addAll(OrderedMap<T,java.lang.Integer> itemsAndWeights)
Given an OrderedMap of T element keys and Integer weight values, adds all T keys with their corresponding weights
into this ProbabilityTable.
|
ProbabilityTable<T> |
ProbabilityTable.addAllNested(OrderedMap<ProbabilityTable<T>,java.lang.Integer> itemsAndWeights)
Given an OrderedMap of ProbabilityTable keys and Integer weight values, adds all keys as nested tables with their
corresponding weights into this ProbabilityTable.
|
ProbabilityTable<T> |
ProbabilityTable.copy()
Copies this ProbabilityTable so nothing in the copy is shared with the original, except for the T items (which
might not be possible to copy).
|
Modifier and Type | Method and Description |
---|---|
java.util.ArrayList<ProbabilityTable<T>> |
ProbabilityTable.tables()
Provides a set of the nested ProbabilityTable values in this table, without reference
to their weight.
|
Modifier and Type | Method and Description |
---|---|
ProbabilityTable<T> |
ProbabilityTable.add(ProbabilityTable<T> table,
int weight)
Adds the given probability table as a possible set of results for this table.
|
boolean |
ProbabilityTable.contentEquals(ProbabilityTable<T> o)
Can avoid some checks that
equals(Object) needs because this always takes a ProbabilityTable. |
int |
ProbabilityTable.weight(ProbabilityTable<T> item)
Returns the weight of the extra table if present.
|
Modifier and Type | Method and Description |
---|---|
ProbabilityTable<T> |
ProbabilityTable.addAllNested(OrderedMap<ProbabilityTable<T>,java.lang.Integer> itemsAndWeights)
Given an OrderedMap of ProbabilityTable keys and Integer weight values, adds all keys as nested tables with their
corresponding weights into this ProbabilityTable.
|
Copyright © Eben Howard 2012–2022. All rights reserved.