Class DataFixUtils
java.lang.Object
com.mojang.datafixers.DataFixUtils
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic intceillog2(int input) static <T> UnaryOperator<T> consumerToFunction(Consumer<T> consumer) static intgetSubVersion(int key) static intgetVersion(int key) private static booleanisPowerOfTwo(int input) static <T> Tstatic <T> Tstatic intmakeKey(int version) static intmakeKey(int version, int subVersion) static <U> Optional<U> static <U> Ustatic <U> Ustatic intsmallestEncompassingPowerOfTwo(int input) static byte[]toArray(ByteBuffer input)
-
Field Details
-
MULTIPLY_DE_BRUIJN_BIT_POSITION
private static final int[] MULTIPLY_DE_BRUIJN_BIT_POSITION
-
-
Constructor Details
-
DataFixUtils
private DataFixUtils()
-
-
Method Details
-
smallestEncompassingPowerOfTwo
public static int smallestEncompassingPowerOfTwo(int input) -
isPowerOfTwo
private static boolean isPowerOfTwo(int input) -
ceillog2
public static int ceillog2(int input) -
make
-
make
-
orElse
-
orElseGet
-
or
-
toArray
-
makeKey
public static int makeKey(int version) -
makeKey
public static int makeKey(int version, int subVersion) -
getVersion
public static int getVersion(int key) -
getSubVersion
public static int getSubVersion(int key) -
consumerToFunction
-