UIElementAutomationPeer.GetPattern(PatternInterface) 方法

定义

获取与此 UIElementAutomationPeer 关联的 UIElement 的控件模式。Gets the control pattern for the UIElement that is associated with this UIElementAutomationPeer.

public:
 override System::Object ^ GetPattern(System::Windows::Automation::Peers::PatternInterface patternInterface);
public override object GetPattern (System.Windows.Automation.Peers.PatternInterface patternInterface);
override this.GetPattern : System.Windows.Automation.Peers.PatternInterface -> obj
Public Overrides Function GetPattern (patternInterface As PatternInterface) As Object

参数

patternInterface
PatternInterface

枚举中的一个值。A value from the enumeration.

返回

Object

如果 patternInterfaceSynchronizedInput,则为实现 ISynchronizedInputProvider 接口的对象;否则为 nullAn object that implements the ISynchronizedInputProvider interface if patternInterface is SynchronizedInput; otherwise, null.

适用于