RuneHive-Game
Loading...
Searching...
No Matches
WeightedObject.java
Go to the documentation of this file.
1package com.runehive.util.chance;
2
3/**
4 * Represents a weighted object.
5 *
6 * @author Michael | Chex
7 */
8public interface WeightedObject<T> extends Comparable<WeightedObject<T>> {
9
10 /** Gets the object's weight. */
11 double getWeight();
12
13 /** Gets the representation of the weighted chance. */
14 T get();
15
16 @Override
17 String toString();
18}
Represents a weighted object.
double getWeight()
Gets the object's weight.