StorageUnit (Apache Hadoop Common 3.5.0 API)
Description: declaration: package: org.apache.hadoop.conf, enum: StorageUnit

Package org.apache.hadoop.conf

# Enum Class StorageUnit

java.lang.Object
java.lang.Enum<StorageUnit>
org.apache.hadoop.conf.StorageUnit

All Implemented Interfaces:
  `Serializable`, `Comparable<StorageUnit>`, `Constable`

public enum StorageUnit extends Enum<StorageUnit>
Class that maintains different forms of Storage Units.

- ## Nested Class Summary

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

  `Enum.EnumDesc<E extends Enum<E>>`

- ## Enum Constant Summary

  Enum Constants
  Enum Constant
  Description
  `BYTES`
  `EB`
  `GB`
  `KB`
  `MB`
  `PB`
  `TB`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `abstract double`
  `fromBytes(double value)`
  `abstract double`
  `getDefault(double value)`
  `abstract String`
  `getLongName()`
  `abstract String`
  `getShortName()`
  `abstract String`
  `getSuffixChar()`
  `abstract double`
  `toBytes(double value)`
  `abstract double`
  `toEBs(double value)`
  `abstract double`
  `toGBs(double value)`
  `abstract double`
  `toKBs(double value)`
  `abstract double`
  `toMBs(double value)`
  `abstract double`
  `toPBs(double value)`
  `String`
  `toString()`
  `abstract double`
  `toTBs(double value)`
  `static StorageUnit`
  `valueOf(String name)`
  Returns the enum constant of this class with the specified name.
  `static StorageUnit[]`
  `values()`
  Returns an array containing the constants of this enum class, in the order they are declared.

  ### Methods inherited from class java.lang.Enum

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

  ### Methods inherited from class java.lang.Object

  `getClass, notify, notifyAll, wait, wait, wait`

- ## Enum Constant Details

  - ### EB

    public static final StorageUnit EB

  - ### PB

    public static final StorageUnit PB

  - ### TB

    public static final StorageUnit TB

  - ### GB

    public static final StorageUnit GB

  - ### MB

    public static final StorageUnit MB

  - ### KB

    public static final StorageUnit KB

  - ### BYTES

    public static final StorageUnit BYTES

- ## Method Details

  - ### values

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

  - ### valueOf

    public static StorageUnit valueOf(String name)
    Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      `NullPointerException` - if the argument is null

  - ### toBytes

    public abstract double toBytes(double value)

  - ### toKBs

    public abstract double toKBs(double value)

  - ### toMBs

    public abstract double toMBs(double value)

  - ### toGBs

    public abstract double toGBs(double value)

  - ### toTBs

    public abstract double toTBs(double value)

  - ### toPBs

    public abstract double toPBs(double value)

  - ### toEBs

    public abstract double toEBs(double value)

  - ### getLongName

    public abstract String getLongName()

  - ### getShortName

    public abstract String getShortName()

  - ### getSuffixChar

    public abstract String getSuffixChar()

  - ### getDefault

    public abstract double getDefault(double value)

  - ### fromBytes

    public abstract double fromBytes(double value)

  - ### toString

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