ClaimsAuthenticationManager.LoadCustomConfiguration(XmlNodeList) 方法

定义

在派生类中重写时,将从 XML 中加载自定义配置。When overridden in a derived class, loads custom configuration from XML.

public:
 virtual void LoadCustomConfiguration(System::Xml::XmlNodeList ^ nodelist);
public virtual void LoadCustomConfiguration (System.Xml.XmlNodeList nodelist);
abstract member LoadCustomConfiguration : System.Xml.XmlNodeList -> unit
override this.LoadCustomConfiguration : System.Xml.XmlNodeList -> unit
Public Overridable Sub LoadCustomConfiguration (nodelist As XmlNodeList)

参数

nodelist
XmlNodeList

自定义配置元素。The custom configuration elements. 列表中的每个节点都属于 XmlElement 类型。Each node in the list is of type XmlElement.

实现

注解

LoadCustomConfiguration 方法由配置基础结构调用。The LoadCustomConfiguration method is called by the configuration infrastructure. 调用此方法时, nodelist 将包含配置文件中的 < claimsAuthenticationManager > 元素的顶级子元素。When this method is called, the nodelist will contain the top-level child elements of the <claimsAuthenticationManager> element from the configuration file. 其中每个元素反过来都包含特性或子元素,具体取决于为派生类定义的配置架构。Each of these elements may, in turn, contain attributes or child elements depending on the configuration schema you define for your derived class. 如果在配置文件中的元素下未显示任何子元素 <claimsAuthenticationManager> ,则不会调用此方法。If no child elements appear under the <claimsAuthenticationManager> element in the configuration file, this method is not called.

默认实现引发 NotImplementedExceptionThe default implementation throws a NotImplementedException. 在派生类中重写此方法可以从配置文件中启用声明身份验证管理器的初始化。Override this method in your derived class to enable initialization of your claims authentication manager from a configuration file. 例如,配置元素可以描述在对声明主体进行身份验证时要遵循的策略;还可以使用它们指向要将其他声明添加到主体中的属性存储。For example, the configuration elements might describe a policy to be followed when authenticating a claims principal; or they might be used to point to an attribute store from which additional claims are to be added to the principal.

适用于