ShortcutInfo.Builder.SetPerson(Person) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
設定與此快捷鍵相關的人物,取代先前設定的人員。
[Android.Runtime.Register("setPerson", "(Landroid/app/Person;)Landroid/content/pm/ShortcutInfo$Builder;", "GetSetPerson_Landroid_app_Person_Handler", ApiSince=29)]
public virtual Android.Content.PM.ShortcutInfo.Builder SetPerson(Android.App.Person person);
[<Android.Runtime.Register("setPerson", "(Landroid/app/Person;)Landroid/content/pm/ShortcutInfo$Builder;", "GetSetPerson_Landroid_app_Person_Handler", ApiSince=29)>]
abstract member SetPerson : Android.App.Person -> Android.Content.PM.ShortcutInfo.Builder
override this.SetPerson : Android.App.Person -> Android.Content.PM.ShortcutInfo.Builder
參數
- person
- Person
非空的人物要儲存為捷徑的單一入口人物清單。
傳回
此建構器在取得個人紀錄副本(不含圖示)後被儲存。
- 屬性
備註
設定與此快捷鍵相關的人物,取代先前設定的人員。 或者,也可以使用 SetPersons 來設定多個人物。 此欄位為選填欄位,但新增個人可能會使此捷徑在使用者介面中更顯眼(例如 ShareSheet)。 通常應該包含一個 URI,才能從排名提升中受益。 不過,即使沒有提供 URI,提供快捷方式中的人員也是有益的,讓聽眾和純語音裝置能夠正確地廣播和處理。
Android 參考資料。android.content.pm.ShortcutInfo.Builder.setPerson
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。