Skip to content

Most visited

Recently visited

navigation
added in API level 23
Deprecated since API level 24

AudioTrack.OnRoutingChangedListener

public static interface AudioTrack.OnRoutingChangedListener
implements AudioRouting.OnRoutingChangedListener

android.media.AudioTrack.OnRoutingChangedListener


This interface was deprecated in API level 24.
users should switch to the general purpose AudioRouting.OnRoutingChangedListener class instead.

Defines the interface by which applications can receive notifications of routing changes for the associated AudioTrack.

Summary

Public methods

abstract void onRoutingChanged(AudioTrack audioTrack)

Called when the routing of an AudioTrack changes from either and explicit or policy rerouting.

default void onRoutingChanged(AudioRouting router)

Inherited methods

From interface android.media.AudioRouting.OnRoutingChangedListener

Public methods

onRoutingChanged

added in API level 23
void onRoutingChanged (AudioTrack audioTrack)

Called when the routing of an AudioTrack changes from either and explicit or policy rerouting. Use getRoutedDevice() to retrieve the newly routed-to device.

Parameters
audioTrack AudioTrack

onRoutingChanged

added in API level 24
void onRoutingChanged (AudioRouting router)

Parameters
router AudioRouting

This site uses cookies to store your preferences for site-specific language and display options.

Get the latest Android developer news and tips that will help you find success on Google Play.

* Required Fields

Hooray!

Browse this site in ?

You requested a page in , but your language preference for this site is .

Would you like to change your language preference and browse this site in ? If you want to change your language preference later, use the language menu at the bottom of each page.

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.

Take a short survey?
Help us improve the Android developer experience.
(Sep 2017 survey)