Android Guides | Samples

Android.Media.VolumeProvider Class

Handles requests to adjust or set the volume on a session.

See Also: VolumeProvider

Syntax

[Android.Runtime.Register("android/media/VolumeProvider", DoNotGenerateAcw=true)]
public abstract class VolumeProvider : Object

Remarks

Handles requests to adjust or set the volume on a session. This is also used to push volume updates back to the session. The provider must call VolumeProvider.CurrentVolume each time the volume being provided changes.

You can set a volume provider on a session by calling MediaSession.SetPlaybackToRemote(VolumeProvider).

[Android Documentation]

Requirements

Namespace: Android.Media
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0

The members of Android.Media.VolumeProvider are listed below.

See Also: Object

Protected Constructors

A constructor used when creating managed representations of JNI objects; called by the runtime.

Public Properties

CurrentVolumeInt32. Gets the current volume.
[read-only]
MaxVolumeInt32. Get the maximum volume this provider allows.

Protected Properties

[read-only]
override
ThresholdClassIntPtr. This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.
[read-only]
override
ThresholdTypeType. This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

Public Methods

OnAdjustVolume(Adjust)
Override to handle requests to adjust the volume of the current output.
OnSetVolumeTo(Int32)
Override to handle requests to set the volume of the current output.