AudioFocusRequestCompat
open class AudioFocusRequestCompat
kotlin.Any | |
↳ | androidx.media.AudioFocusRequestCompat |
Compatibility version of an AudioFocusRequest
.
Summary
Nested classes | |
---|---|
Builder class for |
Public methods | |
---|---|
open Boolean | |
open AudioAttributesCompat |
Gets the |
open Handler |
Gets the |
open Int |
Gets the type of audio focus request configured for this |
open OnAudioFocusChangeListener |
Gets the focus change listener set for this |
open Int |
hashCode() |
open Boolean |
Gets whether the application that would use this |
Public methods
getAudioAttributesCompat
@NonNull open fun getAudioAttributesCompat(): AudioAttributesCompat
Gets the AudioAttributesCompat
set for this AudioFocusRequestCompat
, or the default attributes if none were set.
Return | |
---|---|
AudioAttributesCompat |
non-null AudioAttributesCompat . |
getFocusChangeHandler
@NonNull open fun getFocusChangeHandler(): Handler
Gets the Handler
to be used for the focus change listener.
Return | |
---|---|
Handler |
the same Handler set in. . |
getFocusGain
open fun getFocusGain(): Int
Gets the type of audio focus request configured for this AudioFocusRequestCompat
.
Return | |
---|---|
Int |
one of AudioManagerCompat#AUDIOFOCUS_GAIN , , , and . |
getOnAudioFocusChangeListener
@NonNull open fun getOnAudioFocusChangeListener(): OnAudioFocusChangeListener
Gets the focus change listener set for this AudioFocusRequestCompat
.
Return | |
---|---|
OnAudioFocusChangeListener |
The AudioManager.OnAudioFocusChangeListener that was set. |
hashCode
open fun hashCode(): Int