Enum Class Websocket.AudioRate

java.lang.Object
java.lang.Enum<Websocket.AudioRate>
com.vonage.client.video.Websocket.AudioRate
All Implemented Interfaces:
Serializable, Comparable<Websocket.AudioRate>, java.lang.constant.Constable
Enclosing class:
Websocket

public static enum Websocket.AudioRate extends Enum<Websocket.AudioRate>
Represents the possible audio sampling rate values for a WebSocket connection.
  • Enum Constant Details

  • Method Details

    • values

      public static Websocket.AudioRate[] 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 Websocket.AudioRate 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
    • getAudioRate

      public int getAudioRate()
      Converts the enum to an integer value representing the bitrate (Hz).
      Returns:
      The audio rate in Hertz as an int.
    • fromInt

      public static Websocket.AudioRate fromInt(int value)
      Converts an integer sampling value into the appropriate enum representation.
      Parameters:
      value - The sampling rate in Hz or KHz.
      Returns:
      The corresponding enum representation.