@Override
    public boolean equals(Object o) {
        if (o == this) return true;
        if (!(o instanceof WeightedObject)) return false;
        final WeightedObject other = (WeightedObject) o;
        return this.object.equals(other.object) && Double.compare(this.getWeight(), other.getWeight()) == 0;
    }
Represents a {@link Weighted} object.

@param <T> the object type
helper/src/main/java/me/lucko/helper/random/WeightedObject.java