Intent.ParseIntent(Resources, XmlReader, IAttributeSet) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
從 XML 解析「意圖」元素(及其子節點)並實例化一個意圖物件。
[Android.Runtime.Register("parseIntent", "(Landroid/content/res/Resources;Lorg/xmlpull/v1/XmlPullParser;Landroid/util/AttributeSet;)Landroid/content/Intent;", "")]
public static Android.Content.Intent ParseIntent(Android.Content.Res.Resources resources, System.Xml.XmlReader parser, Android.Util.IAttributeSet? attrs);
[<Android.Runtime.Register("parseIntent", "(Landroid/content/res/Resources;Lorg/xmlpull/v1/XmlPullParser;Landroid/util/AttributeSet;)Landroid/content/Intent;", "")>]
static member ParseIntent : Android.Content.Res.Resources * System.Xml.XmlReader * Android.Util.IAttributeSet -> Android.Content.Intent
參數
- resources
- Resources
膨脹資源時應使用的資源。
- parser
- XmlReader
XML 解析器指向一個「意圖」標籤。
- attrs
- IAttributeSet
AttributeSet 介面用於在目前 <var>解析器</var> 位置擷取擴展屬性資料。
傳回
一個與 XML 資料相符的意圖物件。
- 屬性
例外狀況
如果有 XML 解析錯誤。
如果有 I/O 錯誤。
備註
從 XML 解析「意圖」元素(及其子節點)並實例化一個意圖物件。 給定的 XML 解析器應位於解析開始的標籤(通常稱為「意圖」),從中擷取基本動作、資料、型別、套件和類別名稱。 函式接著會解析到任何子元素,尋找 <android:name=“xxx”> 標籤來新增分類,以及 <額外的 android:name=“xxx” android:value=“yyy”> ,用來附加額外資料到意圖上。
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。