語言

ContentCaptureSession.Version2 欄位

定義

警告

This constant will be removed in the future version. Use Android.Views.ContentCaptures.ContentCaptureSessionVersion enum directly instead of this field.

內容擷取版本 2。

[Android.Runtime.Register("VERSION_2", ApiSince=37)]
[System.Obsolete("This constant will be removed in the future version. Use Android.Views.ContentCaptures.ContentCaptureSessionVersion enum directly instead of this field.", true)]
public const Android.Views.ContentCaptures.ContentCaptureSessionVersion Version2 = 2;
[<Android.Runtime.Register("VERSION_2", ApiSince=37)>]
[<System.Obsolete("This constant will be removed in the future version. Use Android.Views.ContentCaptures.ContentCaptureSessionVersion enum directly instead of this field.", true)>]
val mutable Version2 : Android.Views.ContentCaptures.ContentCaptureSessionVersion

欄位值

Value = 2
屬性

備註

內容擷取版本 2。

第二款且較新的內容擷取採用更精簡且聚焦的方式,將視圖階層從應用程式傳遞給系統智慧服務。 所需資訊大多限於螢幕上的文字及這些文字節點的邊界框。 此版本的內容擷取在資源使用上也顯著更有效率,並建議成為各種系統情報服務的預設版本。

當 getContentCaptureVersion() 回傳此版本時,開發者應使用 Version 2 API 來回報節點生命週期及屬性更新。 當會話設定為版本 2 時呼叫版本 1 API,會導致無運。

一份明確屬於內容擷取版本 2 的函式清單:notifyNodeAppearedOrChanged(AutofillId,ContentCaptureNodeProperties);notifyNodeDisappeared(AutofillId)

Android 參考資料。android.view.contentcapture.ContentCaptureSession.VERSION_2

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於