TypedArray 類別
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
使用 擷取之值的陣列容器Resources.Theme#obtainStyledAttributes(AttributeSet, int[], int, int)
或 Resources#obtainAttributes
。
[Android.Runtime.Register("android/content/res/TypedArray", DoNotGenerateAcw=true)]
public class TypedArray : Java.Lang.Object, IDisposable, Java.Interop.IJavaPeerable, Java.Lang.IAutoCloseable
[<Android.Runtime.Register("android/content/res/TypedArray", DoNotGenerateAcw=true)>]
type TypedArray = class
inherit Object
interface IAutoCloseable
interface IJavaObject
interface IDisposable
interface IJavaPeerable
- 繼承
- 屬性
- 實作
備註
使用 或 Resources#obtainAttributes
擷取 Resources.Theme#obtainStyledAttributes(AttributeSet, int[], int, int)
之值的陣列容器。 請務必在完成時呼叫 #recycle
。
用來從這個結構擷取值的索引會對應至提供給 getStyledAttributes 的屬性位置。
的 android.content.res.TypedArray
JAVA 檔。
此頁面的部分是根據 原始碼專案所建立和共用的工作進行修改,並根據中所述的詞彙使用。
建構函式
TypedArray(IntPtr, JniHandleOwnership) |
建立 JNI 物件的 Managed 標記法時所使用的建構函式;由執行時間呼叫。 |
屬性
ChangingConfigurations |
傳回此類型陣列中值可能會變更之組態參數的遮罩。 |
Class |
傳回這個 |
Handle |
基礎 Android 實例的控制碼。 (繼承來源 Object) |
IndexCount |
傳回陣列中實際具有資料的索引數目。 |
JniIdentityHashCode |
使用 擷取之值的陣列容器 |
JniPeerMembers |
使用 擷取之值的陣列容器 |
PeerReference |
使用 擷取之值的陣列容器 |
PositionDescription |
傳回適用于列印錯誤訊息之剖析器狀態的相關訊息。 |
Resources |
傳回這個陣列從中載入的 Resources 物件。 |
ThresholdClass |
此 API 支援 Mono for Android 基礎結構,並不適合直接從您的程式碼使用。 |
ThresholdType |
此 API 支援 Mono for Android 基礎結構,並不適合直接從您的程式碼使用。 |
方法
Clone() |
建立並傳回這個 物件的複本。 (繼承來源 Object) |
Close() |
回收 TypedArray,以供稍後呼叫端重複使用。 |
Dispose() |
使用 擷取之值的陣列容器 |
Dispose(Boolean) |
使用 擷取之值的陣列容器 |
Equals(Object) |
指出其他物件是否「等於」這個物件。 (繼承來源 Object) |
GetBoolean(Int32, Boolean) |
擷取 var index < /var >> 屬性的 < 布林值。 |
GetColor(Int32, Int32) |
擷取 var > index < /var > 屬性的 < 色彩值。 |
GetColorStateList(Int32) |
擷取 var > index < /var > 屬性 < 的 ColorStateList。 |
GetDimension(Int32, Single) |
擷取 var > index < /var > 的 < 維度單位屬性。 |
GetDimensionPixelOffset(Int32, Int32) |
擷取 var > index < /var > 的維度單位屬性 < ,以作為原始圖元中的位移。 |
GetDimensionPixelSize(Int32, Int32) |
擷取 var > index < /var > 的維度單位屬性 < ,以作為原始圖元的大小。 |
GetDrawable(Int32) |
擷取 var > index < /var > 屬性的 < Drawable。 |
GetFloat(Int32, Single) |
擷取 var > index < /var > 屬性的 < float 值。 |
GetFont(Int32) |
擷取 var > index < /var > 屬性 < 的 Typeface。 |
GetFraction(Int32, Int32, Int32, Single) |
擷取 var > index < /var > 的 < 分數單位屬性。 |
GetHashCode() |
傳回此物件的雜湊碼值。 (繼承來源 Object) |
GetIndex(Int32) |
傳回陣列中具有資料的索引。 |
GetInt(Int32, Int32) |
擷取 var > index < /var > 屬性 < 的整數值。 |
GetInteger(Int32, Int32) |
擷取 var > index < /var > 屬性 < 的整數值。 |
GetLayoutDimension(Int32, Int32) |
用於擷 |
GetLayoutDimension(Int32, String) |
用於擷 |
GetNonResourceString(Int32) |
擷取 var index < /var >> 屬性的 < 字串值,但只有在該字串來自 XML 檔案中的立即值時。 |
GetResourceId(Int32, Int32) |
擷取 var > index < /var > 屬性 < 的資源識別碼。 |
GetSourceResourceId(Int32, Int32) |
傳回已解析指定屬性之樣式或配置的資源識別碼,否則會傳回 defValue。 |
GetString(Int32) |
擷取 var > index < /var > 屬性 < 的字串值。 |
GetText(Int32) |
擷取 var index < /var >> 屬性 < 的樣式字串值。 |
GetTextArray(Int32) |
擷取 var > index < /var > 屬性 < 的 CharSequence[]。 |
GetTextArrayFormatted(Int32) |
擷取 var > index < /var > 屬性 < 的 CharSequence[]。 |
GetTextFormatted(Int32) |
擷取 var index < /var >> 屬性 < 的樣式字串值。 |
GetType(Int32) |
傳回指定索引處的屬性類型。 |
GetValue(Int32, TypedValue) |
擷取 var index < /var >> 屬性 < 的原始 TypedValue。 |
HasValue(Int32) |
判斷 var index < /var > 是否有屬性 < 。 > |
HasValueOrEmpty(Int32) |
判斷 var index/var 是否有屬性 < ,如果屬性已明確設定 |
JavaFinalize() |
當垃圾收集判斷物件沒有其他參考時,由物件上的垃圾收集行程呼叫。 (繼承來源 Object) |
Length() |
傳回這個陣列中的值數目。 |
Notify() |
喚醒正在等候此物件的監視器的單一線程。 (繼承來源 Object) |
NotifyAll() |
喚醒正在等候此物件監視器的所有線程。 (繼承來源 Object) |
PeekValue(Int32) |
擷取 var index < /var >> 屬性 < 的原始 TypedValue,並傳回保存其資料的暫存物件。 |
Recycle() |
回收 TypedArray,以供稍後呼叫端重複使用。 |
SetHandle(IntPtr, JniHandleOwnership) |
設定 Handle 屬性。 (繼承來源 Object) |
ToArray<T>() |
使用 擷取之值的陣列容器 |
ToString() |
傳回物件的字串表示。 (繼承來源 Object) |
UnregisterFromRuntime() |
使用 擷取之值的陣列容器 |
Wait() |
讓目前的執行緒等到喚醒為止,通常是藉由 < em > notified < /em > 或 < em > interrupted < /em > 來喚醒。 (繼承來源 Object) |
Wait(Int64) |
讓目前的執行緒等到喚醒為止,通常是 < 透過 em > notified < /em 或 em > interrupted < /em >> ,或 < 直到經過一定數量的即時為止。 (繼承來源 Object) |
Wait(Int64, Int32) |
讓目前的執行緒等到喚醒為止,通常是 < 透過 em > notified < /em 或 em > interrupted < /em >> ,或 < 直到經過一定數量的即時為止。 (繼承來源 Object) |
明確介面實作
IJavaPeerable.Disposed() |
使用 擷取之值的陣列容器 |
IJavaPeerable.DisposeUnlessReferenced() |
使用 擷取之值的陣列容器 |
IJavaPeerable.Finalized() |
使用 擷取之值的陣列容器 |
IJavaPeerable.JniManagedPeerState |
使用 擷取之值的陣列容器 |
IJavaPeerable.SetJniIdentityHashCode(Int32) |
使用 擷取之值的陣列容器 |
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) |
使用 擷取之值的陣列容器 |
IJavaPeerable.SetPeerReference(JniObjectReference) |
使用 擷取之值的陣列容器 |
擴充方法
JavaCast<TResult>(IJavaObject) |
執行 Android 執行時間檢查的類型轉換。 |
JavaCast<TResult>(IJavaObject) |
使用 擷取之值的陣列容器 |
GetJniTypeName(IJavaPeerable) |
使用 擷取之值的陣列容器 |