Enum FluidAmount.FluidMergeRounding

java.lang.Object
java.lang.Enum<FluidAmount.FluidMergeRounding>
alexiil.mc.lib.attributes.fluid.amount.FluidAmount.FluidMergeRounding
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<FluidAmount.FluidMergeRounding>, java.lang.constant.Constable
Enclosing class:
FluidAmount

public static enum FluidAmount.FluidMergeRounding
extends java.lang.Enum<FluidAmount.FluidMergeRounding>
Specifies how merged FluidAmount's should handle rounding.
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    java.lang.Enum.EnumDesc<E extends java.lang.Enum<E>>
  • Enum Constant Summary

    Enum Constants 
    Enum Constant Description
    FAIL
    Specifies that any fluid amounts that don't completely fit together should fail.
    MAXIMUM_POSSIBLE
    Move only an amount which can be validly moved, leaving the rest in the source.
    ROUND_CEILING
    Always empty the source, but leave the target with (potentially) slightly different amount fluid than the exact sum of the two volumes.
    ROUND_DOWN
    Always empty the source, but leave the target with (potentially) slightly less fluid than the exact sum of the two volumes.
    ROUND_FLOOR
    Always empty the source, but leave the target with (potentially) slightly different amount fluid than the exact sum of the two volumes.
    ROUND_HALF_DOWN
    Always empty the source, but leave the target with (potentially) slightly different amount of fluid than the exact sum of the two volumes.
    ROUND_HALF_EVEN
    Always empty the source, but leave the target with (potentially) slightly different amount of fluid than the exact sum of the two volumes.
    ROUND_HALF_UP
    Always empty the source, but leave the target with (potentially) slightly different amount of fluid than the exact sum of the two volumes.
    ROUND_UNNECESSARY
    Throw an ArithmeticException if the end result needs to be rounded.
    ROUND_UP
    Always empty the source, but leave the target with (potentially) slightly more fluid than the exact sum of the two volumes.
  • Field Summary

    Fields 
    Modifier and Type Field Description
    static FluidAmount.FluidMergeRounding DEFAULT  
    java.math.RoundingMode rounding
    The rounding mode to use, or null if this requires special handling.
  • Method Summary

    Modifier and Type Method Description
    static FluidAmount.FluidMergeRounding fromRounding​(java.math.RoundingMode rounding)  
    static FluidAmount.FluidMergeRounding valueOf​(java.lang.String name)
    Returns the enum constant of this type with the specified name.
    static FluidAmount.FluidMergeRounding[] values()
    Returns an array containing the constants of this enum type, in the order they are declared.

    Methods inherited from class java.lang.Enum

    clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait