Language

AudioRecord.Builder.SetContext(Context) Method

Definition

Sets the context the record belongs to.

[Android.Runtime.Register("setContext", "(Landroid/content/Context;)Landroid/media/AudioRecord$Builder;", "GetSetContext_Landroid_content_Context_Handler", ApiSince=31)]
public virtual Android.Media.AudioRecord.Builder SetContext(Android.Content.Context context);
[<Android.Runtime.Register("setContext", "(Landroid/content/Context;)Landroid/media/AudioRecord$Builder;", "GetSetContext_Landroid_content_Context_Handler", ApiSince=31)>]
abstract member SetContext : Android.Content.Context -> Android.Media.AudioRecord.Builder
override this.SetContext : Android.Content.Context -> Android.Media.AudioRecord.Builder

Parameters

context
Context

a non-null Context instance

Returns

the same Builder instance. This value cannot be null.

Attributes

Remarks

Sets the context the record belongs to. This context will be used to pull information, such as AttributionSource and device specific session ids, which will be associated with the AudioRecord the AudioRecord. However, the context itself will not be retained by the AudioRecord.

Android reference for android.media.AudioRecord.Builder.setContext.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to