XamlType.LookupAttachableMember(String) Method

Definition

Returns a XamlMember for a specific named attachable from this XamlType.

protected:
 virtual System::Xaml::XamlMember ^ LookupAttachableMember(System::String ^ name);
protected virtual System.Xaml.XamlMember LookupAttachableMember (string name);
abstract member LookupAttachableMember : string -> System.Xaml.XamlMember
override this.LookupAttachableMember : string -> System.Xaml.XamlMember
Protected Overridable Function LookupAttachableMember (name As String) As XamlMember

Parameters

name
String

The name of the attachable member to get, in ownerTypeName.MemberName form.

Returns

A XamlMember object for the requested attachable member; otherwise, null, if no attachable member by that name exists.

Remarks

This method can be invoked when a caller gets a value from GetAttachableMember.

The default implementation uses the internal CLR reflection. When UnderlyingType is null, the default implementation can use BaseType, if it is available. This behavior calls LookupAttachableMember recursively to attempt to find a valid base type and returns null if no valid base type exists.

Override this method if you are not relying on default internal CLR reflection and are using metadata or other techniques for reporting the XAML type system information or schema information of a type.

Important

LookupAttachableMember is virtual, and therefore, can be overridden. The override has the potential (whether for malicious purposes or otherwise) to change the reported members of a XAML type so that they no longer align in an expected way with the TypeDescriptor Get* information about the underlying CLR type. For any security-critical checks of member reporting, use the underlying CLR type instead.

Applies to