共用方式為


UITechnologyElementProxy 類別

委派 UITechnologyElement 類別。延伸插入必須覆寫這個和自訂其技術項目行為。

繼承階層架構

System.Object
  Microsoft.VisualStudio.TestTools.UITest.Extension.UITechnologyElement
    Microsoft.VisualStudio.TestTools.UITesting.UITechnologyElementProxy

命名空間:  Microsoft.VisualStudio.TestTools.UITesting
組件:  Microsoft.VisualStudio.TestTools.UITesting (在 Microsoft.VisualStudio.TestTools.UITesting.dll 中)

語法

'宣告
<ComVisibleAttribute(True)> _
Public MustInherit Class UITechnologyElementProxy _
    Inherits UITechnologyElement
[ComVisibleAttribute(true)]
public abstract class UITechnologyElementProxy : UITechnologyElement
[ComVisibleAttribute(true)]
public ref class UITechnologyElementProxy abstract : public UITechnologyElement
[<AbstractClass>]
[<ComVisibleAttribute(true)>]
type UITechnologyElementProxy =  
    class
        inherit UITechnologyElement
    end
public abstract class UITechnologyElementProxy extends UITechnologyElement

UITechnologyElementProxy 型別會公開下列成員。

建構函式

  名稱 說明
受保護的方法 UITechnologyElementProxy 初始化具有指定技術管理員委派的項目。

回頁首

屬性

  名稱 說明
公用屬性 ChildIndex 取得父項目的集合以 0 起始的位置。 (覆寫 UITechnologyElement.ChildIndex。)
公用屬性 ClassName 取得這個項目的類別名稱。 (覆寫 UITechnologyElement.ClassName。)
公用屬性 ControlTypeName 取得這個項目的萬用控制項類型。 (覆寫 UITechnologyElement.ControlTypeName。)
公用屬性 FriendlyName 取得物件的使用者易記名稱,由這個項目可協助使用者更快速地辨識螢幕上的項目的顯示文字。 (覆寫 UITechnologyElement.FriendlyName。)
公用屬性 IsLeafNode 取得這個項目是否是沒有任何子系) 的分葉節點 (。 (覆寫 UITechnologyElement.IsLeafNode。)
公用屬性 IsPassword 取得這個值表示此項目是否包含受保護的內容。 (覆寫 UITechnologyElement.IsPassword。)
公用屬性 IsTreeSwitchingRequired 取得樹參數是否為無視窗 (Windowless) 控制項樹狀結構 switch case 是必要的。 (覆寫 UITechnologyElement.IsTreeSwitchingRequired。)
公用屬性 Name 取得這個項目的名稱。 (覆寫 UITechnologyElement.Name。)
公用屬性 NativeElement 取得對應基礎原生技術的項目 (如 IAccessible) 這個項目。 (覆寫 UITechnologyElement.NativeElement。)
公用屬性 QueryId 取得可用來唯一識別/尋找這個項目的 QueryId。 在某些情況下,例如 TreeItem, QueryIds 可能包含完整的項目階層架構,但在大部分的情況中會包含項目的只有關鍵祖系。 技術管理員必須決定要擷取的是哪個祖系階層透過適當設定每個項目 QueryId.Ancestor 屬性。 在條件類別。AndCondition.ToString() 和 AndCondition.Parse() 的 API 可能用來從反之亦然。這個類別會轉換為字串或。 EXT-PROTO1-NOTES:這個 QID 遞迴地也會將所有祖系核心技術項目轉換成延伸項目並適當地祖系階層。 (覆寫 UITechnologyElement.QueryId。)
公用屬性 SupportLevel 取得測試錄製和播放引擎所使用的值,以尋找此項目的相符 UITechnologyManager。 (繼承自 UITechnologyElement)。
公用屬性 SwitchingElement 如果一個技術會裝載在另一個技術內,取得或設定容器項目。 架構會使用此項目。 (覆寫 UITechnologyElement.SwitchingElement。)
公用屬性 TechnologyManager 取得對應的技術管理員。 (覆寫 UITechnologyElement.TechnologyManager。)
公用屬性 TechnologyName 取得對應之技術的名稱。 這個值應該與 UITechnologyManager.TechnologyName 相同。 (覆寫 UITechnologyElement.TechnologyName。)
公用屬性 TopLevelElement 取得或設定的最上層視窗與這個視窗的項目。最上層視窗通常都是桌面的子系。如果未設定這個,架構會將這個加入至項目中的祖系 (在覆寫為祖系的桌面之後)。 (覆寫 UITechnologyElement.TopLevelElement。)
公用屬性 Value 取得這個項目的值。 (覆寫 UITechnologyElement.Value。)
公用屬性 WindowHandle 取得包含此項目之 Win32 視窗的控制代碼。 (覆寫 UITechnologyElement.WindowHandle。)
公用屬性 WindowTitles 取得最上層視窗標題的清單 (其中一個視窗是這個項目的上階)。 (繼承自 UITechnologyElement)。

回頁首

方法

  名稱 說明
公用方法 CacheProperties 快取此項目所有通用屬性之後使用,以便稍後可以使用這些屬性,即使基礎 UI 控制項不存在。 這通常包含像名稱、ClassName、用於識別字串和其他屬性 (Attribute) 的屬性 (Property) ControlType、QueryId。 (覆寫 UITechnologyElement.CacheProperties()。)
公用方法 EnsureVisibleByScrolling 將此項目加入至 檢視。 如果技術管理員不支援捲動多個容器,則應該傳回 outPointX 和 outPointY 為-1, -1。 (覆寫 UITechnologyElement.EnsureVisibleByScrolling(Int32, Int32, Int32%, Int32%)。)
公用方法 Equals(Object) 判斷指定的物件是否等於目前物件。 (覆寫 Object.Equals(Object)。)
公用方法 Equals(IUITechnologyElement) 判斷指定的物件是否等於目前物件。 (覆寫 UITechnologyElement.Equals(IUITechnologyElement)。)
受保護的方法 Finalize 允許物件在記憶體回收進行回收之前,嘗試釋放資源並執行其他清除作業。 (繼承自 Object)。
公用方法 GetBoundingRectangle 取得完全圍住這個項目的矩形座標。 (覆寫 UITechnologyElement.GetBoundingRectangle(Int32%, Int32%, Int32%, Int32%)。)
公用方法 GetClickablePoint 取得這個項目的可點選點。架構會使用此取得點 UITechnologyElement.GetOption (UITechnologyElementOption.GetClickablePointFrom) 是否傳回 GetClickablePointFromTechnologyManager。若要使用架構所提供的預設演算法,則會擲回 NotSupportedException。 (覆寫 UITechnologyElement.GetClickablePoint(Int32%, Int32%)。)
公用方法 GetHashCode 取得這個物件的雜湊程式碼。 如果等於,則會忽略, .NET Framework 設計方針建議太覆寫這項屬性。 (覆寫 Object.GetHashCode()。)
公用方法 GetNativeControlType 取得這個項目的原生控制項型別。,當 ControlType 不區分足夠的控制項時,這可與傳遞 GetControlType() 取得的通用型別串聯。 例如,在中,如果是在本機技術項目是 HTML,這可能是在標記名稱。 (覆寫 UITechnologyElement.GetNativeControlType(NativeControlTypeKind)。)
公用方法 GetOption 取得這 IUITechnologyElement 的選項。 (覆寫 UITechnologyElement.GetOption(UITechnologyElementOption)。)
公用方法 GetPropertyValue 取得指定之屬性值的這個項目的。 (覆寫 UITechnologyElement.GetPropertyValue(String)。)
公用方法 GetQueryIdForRelatedElement 取得 UITestElementKind 指定的相關項目的 QueryId。 (覆寫 UITechnologyElement.GetQueryIdForRelatedElement(UITestElementKind, Object, Int32%)。)
公用方法 GetRequestedState 取得此項目的目前狀態資訊指定要求的狀態。 如果項目不支援查詢只有選取的狀態,它會傳回完整的狀態資訊。 (覆寫 UITechnologyElement.GetRequestedState(AccessibleStates)。)
公用方法 GetRightToLeftProperty 取得 true/false 值為由右至左格式化以指定的型別。 (覆寫 UITechnologyElement.GetRightToLeftProperty(RightToLeftKind)。)
公用方法 GetScrolledPercentage 在百分比值數量移動。 (覆寫 UITechnologyElement.GetScrolledPercentage(ScrollDirection, IUITechnologyElement)。)
公用方法 GetType 取得目前執行個體的 Type。 (繼承自 Object)。
公用方法 InitializeProgrammaticScroll 初始化這個項目以程式方式捲動。 (覆寫 UITechnologyElement.InitializeProgrammaticScroll()。)
公用方法 InvokeProgrammaticAction 根據項目所傳遞的, ProgrammaticActionOption 執行程式設計動作,否則為。 (覆寫 UITechnologyElement.InvokeProgrammaticAction(ProgrammaticActionOption)。)
公用方法 IsInteractable 檢查項目是否為可見和 interactable 在這個執行個體。 插入應該多載這個泛型實作更精確且效能。 (繼承自 UITechnologyElement)。
受保護的方法 MemberwiseClone 建立目前 Object 的淺層複本 (Shallow Copy)。 (繼承自 Object)。
公用方法 ScrollProgrammatically 將這個項目的方式捲動。 (覆寫 UITechnologyElement.ScrollProgrammatically(ScrollDirection, ScrollAmount)。)
公用方法 SetFocus 在項目上設定焦點。 (覆寫 UITechnologyElement.SetFocus()。)
公用方法 SetOption 設定這 IUITechnologyElement 的選項。 (覆寫 UITechnologyElement.SetOption(UITechnologyElementOption, Object)。)
公用方法 SetPropertyValue (繼承自 UITechnologyElement)。
公用方法 ToString 取得這個控制項的字串表示。 (覆寫 Object.ToString()。)
公用方法 WaitForReady 等候項目已可與使用者動作。 (覆寫 UITechnologyElement.WaitForReady()。)

回頁首

執行緒安全

這個型別的任何 Public static (在 Visual Basic 中為 Shared) 成員都具備執行緒安全。不保證任何執行個體成員是安全執行緒。

請參閱

參考

Microsoft.VisualStudio.TestTools.UITesting 命名空間