Enum DataSizeUnit

java.lang.Object
java.lang.Enum<DataSizeUnit>
no.digipost.io.DataSizeUnit
All Implemented Interfaces:
Serializable, Comparable<DataSizeUnit>, java.lang.constant.Constable

public enum DataSizeUnit extends Enum<DataSizeUnit>
  • Enum Constant Details

    • BYTES

      public static final DataSizeUnit BYTES
      The byte unit.
    • KILOBYTES

      public static final DataSizeUnit KILOBYTES
      The kilobyte unit, i.e. 1024 BYTES.
    • MEGABYTES

      public static final DataSizeUnit MEGABYTES
      The Megabyte unit, i.e. 1024 KILOBYTES, i.e. 1 048 576 bytes.
    • GIGABYTES

      public static final DataSizeUnit GIGABYTES
      The Gigabyte unit, i.e. 1024 MEGABYTES, i.e. 1 048 576 kilobytes.
  • Field Details

  • Method Details

    • values

      public static DataSizeUnit[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static DataSizeUnit valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null
    • toString

      public String toString()
      Overrides:
      toString in class Enum<DataSizeUnit>