Package com.castlabs.android.player

# Class AudioAttributes.Builder

java.lang.Object
com.castlabs.android.player.AudioAttributes.Builder

Enclosing class:
  `AudioAttributes`

public static final class AudioAttributes.Builder extends Object
Builder for `AudioAttributes`.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `Builder()`
  Creates a new builder for `AudioAttributes`.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `AudioAttributes`
  `get()`
  Creates an `AudioAttributes` instance from this builder.
  `AudioAttributes.Builder`
  `setContentType(@com.google.android.exoplayer2.C.AudioContentType int contentType)`
  Sets the content type.
  `AudioAttributes.Builder`
  `setFlags(@com.google.android.exoplayer2.C.AudioFlags int flags)`
  Sets the flags.
  `AudioAttributes.Builder`
  `setUsage(@com.google.android.exoplayer2.C.AudioUsage int usage)`
  Sets the usage.

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

  `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### Builder

    public Builder()
    Creates a new builder for `AudioAttributes`.

    By default the content type is `C.CONTENT_TYPE_MOVIE`, usage is `C.USAGE_MEDIA`, and no flags are set.

- ## Method Details

  - ### setContentType

    public AudioAttributes.Builder setContentType(@AudioContentType @com.google.android.exoplayer2.C.AudioContentType int contentType)
    Sets the content type.
    Parameters:
      `contentType` - The content type.
    Returns:
      This builder.
    See Also:
      - `AudioAttributes.Builder.setContentType(int)`

  - ### setFlags

    public AudioAttributes.Builder setFlags(@AudioFlags @com.google.android.exoplayer2.C.AudioFlags int flags)
    Sets the flags.
    Parameters:
      `flags` - The flags.
    Returns:
      This builder.
    See Also:
      - `AudioAttributes.Builder.setFlags(int)`

  - ### setUsage

    public AudioAttributes.Builder setUsage(@AudioUsage @com.google.android.exoplayer2.C.AudioUsage int usage)
    Sets the usage.
    Parameters:
      `usage` - The usage.
    Returns:
      This builder.
    See Also:
      - `AudioAttributes.Builder.setUsage(int)`

  - ### get

    public AudioAttributes get()
    Creates an `AudioAttributes` instance from this builder.
    Returns:
      The `AudioAttributes` instance.