Partager via


Connection.OnAnswer Method

Definition

Overloads

OnAnswer()

Notifies this Connection, which is in #STATE_RINGING, of a request to accept.

OnAnswer(VideoProfileState)

Notifies this Connection, which is in #STATE_RINGING, of a request to accept.

OnAnswer()

Notifies this Connection, which is in #STATE_RINGING, of a request to accept.

[Android.Runtime.Register("onAnswer", "()V", "GetOnAnswerHandler", ApiSince=23)]
public virtual void OnAnswer ();
[<Android.Runtime.Register("onAnswer", "()V", "GetOnAnswerHandler", ApiSince=23)>]
abstract member OnAnswer : unit -> unit
override this.OnAnswer : unit -> unit
Attributes

Remarks

Notifies this Connection, which is in #STATE_RINGING, of a request to accept.

For managed ConnectionServices, this will be called when the user answers a call via the default dialer's InCallService.

Although a self-managed ConnectionService provides its own incoming call UI, the Telecom framework may request that the call is answered in the following circumstances: <ul> <li>The user chooses to answer an incoming call via a Bluetooth device.</li> <li>A car mode InCallService is in use which has declared TelecomManager#METADATA_INCLUDE_SELF_MANAGED_CALLS in its manifest. Such an InCallService will be able to see calls from self-managed ConnectionServices, and will be able to display an incoming call UI on their behalf.</li> </ul>

Java documentation for android.telecom.Connection.onAnswer().

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

OnAnswer(VideoProfileState)

Notifies this Connection, which is in #STATE_RINGING, of a request to accept.

[Android.Runtime.Register("onAnswer", "(I)V", "GetOnAnswer_IHandler", ApiSince=23)]
public virtual void OnAnswer (Android.Telecom.VideoProfileState videoState);
[<Android.Runtime.Register("onAnswer", "(I)V", "GetOnAnswer_IHandler", ApiSince=23)>]
abstract member OnAnswer : Android.Telecom.VideoProfileState -> unit
override this.OnAnswer : Android.Telecom.VideoProfileState -> unit

Parameters

videoState
VideoProfileState

The video state in which to answer the connection.

Attributes

Remarks

Notifies this Connection, which is in #STATE_RINGING, of a request to accept.

For managed ConnectionServices, this will be called when the user answers a call via the default dialer's InCallService.

Although a self-managed ConnectionService provides its own incoming call UI, the Telecom framework may request that the call is answered in the following circumstances: <ul> <li>The user chooses to answer an incoming call via a Bluetooth device.</li> <li>A car mode InCallService is in use which has declared TelecomManager#METADATA_INCLUDE_SELF_MANAGED_CALLS in its manifest. Such an InCallService will be able to see calls from self-managed ConnectionServices, and will be able to display an incoming call UI on their behalf.</li> </ul>

Java documentation for android.telecom.Connection.onAnswer(int).

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