XamlType.LookupCollectionKind Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns a value of the XamlCollectionKind enumeration that declares which specific collection type this XamlType uses.
protected:
virtual System::Xaml::Schema::XamlCollectionKind LookupCollectionKind();
protected virtual System.Xaml.Schema.XamlCollectionKind LookupCollectionKind ();
abstract member LookupCollectionKind : unit -> System.Xaml.Schema.XamlCollectionKind
override this.LookupCollectionKind : unit -> System.Xaml.Schema.XamlCollectionKind
Protected Overridable Function LookupCollectionKind () As XamlCollectionKind
Returns
A value of the XamlCollectionKind enumeration.
Remarks
This method is invoked by an internal private method (no public CollectionKind
or GetCollectionKind
API exists on XamlType).
The default implementation uses the internal CLR reflection. For cases where UnderlyingType is null
, the default implementation can use BaseType, if it is available. This behavior indirectly calls LookupCollectionKind recursively to attempt to find a valid base type; it returns XamlCollectionKind.None if no valid base type exists. In general, the default implementation attempts to find the Add
method of the underlying type by reflection. If found, the MethodInfo of the Add
method is enough information to determine which XamlCollectionKind value should be returned. Otherwise, it returns XamlCollectionKind.None.
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.
Applies to
.NET
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기