AuthorizationRuleCollection.Clear メソッド

定義

コレクションからすべての AuthorizationRule オブジェクトを削除します。

public:
 void Clear();
public void Clear();
member this.Clear : unit -> unit
Public Sub Clear ()

次のコード例は、 Clear メソッドの使用方法を示しています。

// Using the AuthorizationRuleCollection Clear method.
authorizationSection.Rules.Clear();
' Using the AuthorizationRuleCollection Clear method.
authorizationSection.Rules.Clear()

注釈

このメソッドは、 clear ディレクティブを構成ファイルの適切なセクションに挿入して、上位の構成ファイルで定義されている要素への参照をすべてクリアします。 現在の構成ファイルの適切なセクションで定義されているすべての要素が削除されます。

適用対象

こちらもご覧ください