ProviderSettingsCollection クラス
アセンブリ: System.Configuration (system.configuration.dll 内)



ProviderSettingsCollection を返す Providers プロパティを反復処理する方法を次のコード例に示します。
Imports System Imports System.Collections Imports System.Collections.Specialized Imports System.Text Imports System.Configuration ' Show how to use a custom protected configuration ' provider. Public Class UsingProviderSettings Private Shared Sub GetProviderSettings() ' Get the application configuration file. Dim config _ As System.Configuration.Configuration = _ ConfigurationManager.OpenExeConfiguration( _ ConfigurationUserLevel.None) Dim pSection As _ ProtectedConfigurationSection = _ config.GetSection("protectedData") Dim providerSettings _ As ProviderSettingsCollection = _ pSection.Providers Dim pSettings As ProviderSettings For Each pSettings In providerSettings Console.WriteLine( _ "Provider settings name: {0}", _ pSettings.Name) Console.WriteLine( _ "Provider settings type: {0}", _ pSettings.Type) Dim parameters _ As NameValueCollection = pSettings.Parameters Dim pEnum _ As IEnumerator = parameters.GetEnumerator() Dim i As Integer = 0 While pEnum.MoveNext() Dim pLength As String = _ parameters(i).Length.ToString() Console.WriteLine( _ "Provider ssettings: {0} has {1} parameters", _ pSettings.Name, pLength) End While Next pSettings End Sub 'GetProviderSettings Public Shared Sub Main(ByVal args() As String) GetProviderSettings() End Sub 'Main End Class 'UsingProviderSettings
using System; using System.Collections; using System.Collections.Specialized; using System.Text; using System.Configuration; namespace Samples.AspNet.Configuration { // Show how to use a custom protected configuration // provider. public class UsingProviderSettings { private static void GetProviderSettings() { // Get the application configuration file. System.Configuration.Configuration config = ConfigurationManager.OpenExeConfiguration( ConfigurationUserLevel.None); ProtectedConfigurationSection pSection = config.GetSection("protectedData") as ProtectedConfigurationSection; ProviderSettingsCollection providerSettings = pSection.Providers; foreach (ProviderSettings pSettings in providerSettings) { Console.WriteLine( "Provider settings name: {0}", pSettings.Name); Console.WriteLine( "Provider settings type: {0}", pSettings.Type); NameValueCollection parameters = pSettings.Parameters; IEnumerator pEnum = parameters.GetEnumerator(); int i = 0; while (pEnum.MoveNext()) { string pLength = parameters[i].Length.ToString(); Console.WriteLine( "Provider ssettings: {0} has {1} parameters", pSettings.Name, pLength); } } } static void Main(string[] args) { GetProviderSettings(); } } }

System.Configuration.ConfigurationElement
System.Configuration.ConfigurationElementCollection
System.Configuration.ProviderSettingsCollection


Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


ProviderSettingsCollection コンストラクタ
アセンブリ: System.Configuration (system.configuration.dll 内)


Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


ProviderSettingsCollection プロパティ

名前 | 説明 | |
---|---|---|
![]() | CollectionType | ConfigurationElementCollection の型を取得します。 ( ConfigurationElementCollection から継承されます。) |
![]() | Count | コレクション内の要素の数を取得します。 ( ConfigurationElementCollection から継承されます。) |
![]() | ElementInformation | ConfigurationElement オブジェクトのカスタマイズできない情報と機能を格納する ElementInformation オブジェクトを取得します。 ( ConfigurationElement から継承されます。) |
![]() | EmitClear | コレクションが削除されているかどうかを指定します。 ( ConfigurationElementCollection から継承されます。) |
![]() | IsSynchronized | コレクションへのアクセスが同期されている (スレッド セーフである) かどうかを示す値を取得します。 ( ConfigurationElementCollection から継承されます。) |
![]() | Item | オーバーロードされます。 |
![]() | LockAllAttributesExcept | ロックされている属性のコレクションを取得します。 ( ConfigurationElement から継承されます。) |
![]() | LockAllElementsExcept | ロックされている要素のコレクションを取得します。 ( ConfigurationElement から継承されます。) |
![]() | LockAttributes | ロックされている属性のコレクションを取得します。 ( ConfigurationElement から継承されます。) |
![]() | LockElements | ロックされている要素のコレクションを取得します。 ( ConfigurationElement から継承されます。) |
![]() | LockItem | 要素がロックされているかどうかを示す値を取得または設定します。 ( ConfigurationElement から継承されます。) |
![]() | SyncRoot | ConfigurationElementCollection へのアクセスを同期するために使用するオブジェクトを取得します。 ( ConfigurationElementCollection から継承されます。) |

ProviderSettingsCollection メソッド

名前 | 説明 | |
---|---|---|
![]() | Add | ProviderSettings オブジェクトをコレクションに追加します。 |
![]() | Clear | コレクションを空にします。 |
![]() | CopyTo | ConfigurationElementCollection の内容を配列にコピーします。 ( ConfigurationElementCollection から継承されます。) |
![]() | Equals | オーバーロードされます。 ConfigurationElementCollection と指定したオブジェクトを比較します。 ( ConfigurationElementCollection から継承されます。) |
![]() | GetEnumerator | ConfigurationElementCollection の反復処理に使用する IEnumerator を取得します。 ( ConfigurationElementCollection から継承されます。) |
![]() | GetHashCode | ConfigurationElementCollection インスタンスを表す一意の値を取得します。 ( ConfigurationElementCollection から継承されます。) |
![]() | GetType | 現在のインスタンスの Type を取得します。 ( Object から継承されます。) |
![]() | IsReadOnly | ConfigurationElementCollection オブジェクトが読み取り専用かどうかを示す値を取得します。 ( ConfigurationElementCollection から継承されます。) |
![]() | ReferenceEquals | 指定した複数の Object インスタンスが同一かどうかを判断します。 ( Object から継承されます。) |
![]() | Remove | コレクションから要素を削除します。 |
![]() | ToString | 現在の Object を表す String を返します。 ( Object から継承されます。) |

名前 | 説明 | |
---|---|---|
![]() | Finalize | Object がガベージ コレクションにより収集される前に、その Object がリソースを解放し、その他のクリーンアップ操作を実行できるようにします。 ( Object から継承されます。) |
![]() | MemberwiseClone | 現在の Object の簡易コピーを作成します。 ( Object から継承されます。) |

ProviderSettingsCollection メンバ
ProviderSettings オブジェクトのコレクションを表します。
ProviderSettingsCollection データ型で公開されるメンバを以下の表に示します。


名前 | 説明 | |
---|---|---|
![]() | CollectionType | ConfigurationElementCollection の型を取得します。(ConfigurationElementCollection から継承されます。) |
![]() | Count | コレクション内の要素の数を取得します。(ConfigurationElementCollection から継承されます。) |
![]() | ElementInformation | ConfigurationElement オブジェクトのカスタマイズできない情報と機能を格納する ElementInformation オブジェクトを取得します。 (ConfigurationElement から継承されます。) |
![]() | EmitClear | コレクションが削除されているかどうかを指定します。(ConfigurationElementCollection から継承されます。) |
![]() | IsSynchronized | コレクションへのアクセスが同期されている (スレッド セーフである) かどうかを示す値を取得します。(ConfigurationElementCollection から継承されます。) |
![]() | Item | オーバーロードされます。 |
![]() | LockAllAttributesExcept | ロックされている属性のコレクションを取得します。(ConfigurationElement から継承されます。) |
![]() | LockAllElementsExcept | ロックされている要素のコレクションを取得します。(ConfigurationElement から継承されます。) |
![]() | LockAttributes | ロックされている属性のコレクションを取得します。 (ConfigurationElement から継承されます。) |
![]() | LockElements | ロックされている要素のコレクションを取得します。(ConfigurationElement から継承されます。) |
![]() | LockItem | 要素がロックされているかどうかを示す値を取得または設定します。(ConfigurationElement から継承されます。) |
![]() | SyncRoot | ConfigurationElementCollection へのアクセスを同期するために使用するオブジェクトを取得します。(ConfigurationElementCollection から継承されます。) |

名前 | 説明 | |
---|---|---|
![]() | Add | ProviderSettings オブジェクトをコレクションに追加します。 |
![]() | Clear | コレクションを空にします。 |
![]() | CopyTo | ConfigurationElementCollection の内容を配列にコピーします。 (ConfigurationElementCollection から継承されます。) |
![]() | Equals | オーバーロードされます。 ConfigurationElementCollection と指定したオブジェクトを比較します。 (ConfigurationElementCollection から継承されます。) |
![]() | GetEnumerator | ConfigurationElementCollection の反復処理に使用する IEnumerator を取得します。 (ConfigurationElementCollection から継承されます。) |
![]() | GetHashCode | ConfigurationElementCollection インスタンスを表す一意の値を取得します。 (ConfigurationElementCollection から継承されます。) |
![]() | GetType | 現在のインスタンスの Type を取得します。 (Object から継承されます。) |
![]() | IsReadOnly | ConfigurationElementCollection オブジェクトが読み取り専用かどうかを示す値を取得します。 (ConfigurationElementCollection から継承されます。) |
![]() | ReferenceEquals | 指定した複数の Object インスタンスが同一かどうかを判断します。 (Object から継承されます。) |
![]() | Remove | コレクションから要素を削除します。 |
![]() | ToString | 現在の Object を表す String を返します。 (Object から継承されます。) |

名前 | 説明 | |
---|---|---|
![]() | Finalize | Object がガベージ コレクションにより収集される前に、その Object がリソースを解放し、その他のクリーンアップ操作を実行できるようにします。 (Object から継承されます。) |
![]() | MemberwiseClone | 現在の Object の簡易コピーを作成します。 (Object から継承されます。) |

Weblioに収録されているすべての辞書からProviderSettingsCollectionを検索する場合は、下記のリンクをクリックしてください。

- ProviderSettingsCollectionのページへのリンク