Package net.kyori.adventure.util
Class ShadyPines
java.lang.Object
net.kyori.adventure.util.ShadyPines
public final class ShadyPines extends Object
Various utilities.
- Since:
- 4.0.0
-
Method Summary
Modifier and Type Method Description static <E extends Enum<E>>
@NonNull Set<E>enumSet(Class<E> type, E @NonNull ... constants)
Creates a set from an array of enum constants.static boolean
equals(double a, double b)
Checks ifa
is equal tob
.static boolean
equals(float a, float b)
Checks ifa
is equal tob
.
-
Method Details
-
enumSet
@SafeVarargs public static <E extends Enum<E>> @NonNull Set<E> enumSet(Class<E> type, E @NonNull ... constants)Creates a set from an array of enum constants.- Type Parameters:
E
- the enum type- Parameters:
type
- the enum typeconstants
- the enum constants- Returns:
- the set
- Since:
- 4.0.0
-
equals
public static boolean equals(double a, double b)Checks ifa
is equal tob
.- Parameters:
a
- a doubleb
- a double- Returns:
true
ifa
is equal tob
, otherwisefalse
- Since:
- 4.0.0
-
equals
public static boolean equals(float a, float b)Checks ifa
is equal tob
.- Parameters:
a
- a floatb
- a float- Returns:
true
ifa
is equal tob
, otherwisefalse
- Since:
- 4.0.0
-