Enum Class TalkbackState

java.lang.Object
java.lang.Enum<TalkbackState>
com.bambuser.broadcaster.TalkbackState
All Implemented Interfaces:
Serializable, Comparable<TalkbackState>, java.lang.constant.Constable

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

    • IDLE

      public static final TalkbackState IDLE
      This is the default state. There is no pending talkback request and no talkback stream playing. This state requires no action, but is useful for updating any talkback status ui.
    • NEEDS_ACCEPT

      public static final TalkbackState NEEDS_ACCEPT
      This state means that there is a pending talkback request you must approve or reject.

      We recommend that you show a dialog asking the end user to plug in headphones, disable any silent mode and press accept or reject.

      You must invoke acceptTalkback(id) to start receiving the stream, or stopTalkback() to reject the request and return to IDLE.

    • ACCEPTED

      public static final TalkbackState ACCEPTED
      Talkback stream accepted. The server is connecting to the stream to relay it to you. This state requires no action, but it can be useful to signal to the end user that talkback is connecting. The state should soon transition to READY on success, or IDLE if the stream is no longer available.
    • READY

      public static final TalkbackState READY
      Temporary state between ACCEPTED and PLAYING. The Broadcaster is now receiving data from the server and it will be playing soon.
    • PLAYING

      public static final TalkbackState PLAYING
      The Broadcaster is receiving audio, and has signaled to the server that playback has started, so the "caller" knows that there is a live talkback stream to this Broadcaster.

      We recommend that you show some small UI that indicates to the end user that there is an ongoing talkback stream. You can also let the end user stop the talkback stream by invoking stopTalkback().

  • Method Details

    • values

      public static TalkbackState[] 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 TalkbackState 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