ReadOnlyTagHelperAttributeList.TryGetAttributes 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
使用匹配 name
的 TagHelperAttribute检索集合Name中的 。
public:
bool TryGetAttributes(System::String ^ name, [Runtime::InteropServices::Out] System::Collections::Generic::IReadOnlyList<Microsoft::AspNetCore::Razor::TagHelpers::TagHelperAttribute ^> ^ % attributes);
public bool TryGetAttributes (string name, out System.Collections.Generic.IReadOnlyList<Microsoft.AspNetCore.Razor.TagHelpers.TagHelperAttribute> attributes);
member this.TryGetAttributes : string * IReadOnlyList -> bool
Public Function TryGetAttributes (name As String, ByRef attributes As IReadOnlyList(Of TagHelperAttribute)) As Boolean
参数
- name
- String
要 Name 获取的 的 TagHelperAttribute。
- attributes
- IReadOnlyList<TagHelperAttribute>
此方法返回时,TagHelperAttribute具有匹配 name
的 Name 。
返回
true
如果集合中至少有一个 TagHelperAttribute 具有相同 Name 的 ,则为 ;否则为 false
。
注解
name
不区分大小写地进行比较。
适用于
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈