SSJ API Documentation
Stochastic Simulation in Java
Loading...
Searching...
No Matches
SingletonWeight.java
1package umontreal.ssj.latnetbuilder.weights;
2
18
19public class SingletonWeight<T> {
20
21 protected T index;
22 protected double weight;
23
30 SingletonWeight(T ind, double w) {
31 index = ind;
32 weight = w;
33 }
34
40 public T getIndex() {
41 return index;
42 }
43
49 public void setIndex(T ind) {
50 index = ind;
51 }
52
58 public double getWeight() {
59 return weight;
60 }
61
67 public void setWeight(double w) {
68 weight = w;
69 }
70}
void setWeight(double w)
Sets the value of the weight to 'w'.
double getWeight()
Returns the current value of the weight.
void setIndex(T ind)
Sets the index of the weight to 'ind'.
SingletonWeight(T ind, double w)
Constructs a weight with given 'index' and 'weight'.