Class Utils.Bool

java.lang.Object
valorless.valorlessutils.utils.Utils.Bool
Enclosing class:
Utils

public static class Utils.Bool extends Object
Utility class for converting between Boolean and Integer values.
  • Constructor Details

    • Bool

      public Bool()
  • Method Details

    • FromValue

      public static Boolean FromValue(Integer value)
      Converts an Integer value to a Boolean.
      Parameters:
      value - The Integer value to convert.
      Returns:
      The corresponding Boolean value (true for 1, false for 0).
    • ToValue

      public static Integer ToValue(Boolean bool)
      Converts a Boolean value to an Integer.
      Parameters:
      bool - The Boolean value to convert.
      Returns:
      The corresponding Integer value (1 for true, 0 for false).