ProfilePropertySettings クラス
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
ProfilePropertySettings クラスは、構成ファイルの profiles セクションにプログラムでアクセスして変更する方法を提供します。 このクラスは継承できません。
public ref class ProfilePropertySettings sealed : System::Configuration::ConfigurationElement
public sealed class ProfilePropertySettings : System.Configuration.ConfigurationElement
type ProfilePropertySettings = class
inherit ConfigurationElement
Public NotInheritable Class ProfilePropertySettings
Inherits ConfigurationElement
- 継承
例
次のコード例は、ProfilePropertySettings オブジェクトのコレクションを含むPropertySettingsプロパティ値にアクセスする方法を示しています。 このコード例は、 ProfileSection クラスに提供されるより大きな例の一部です。
// Display all current root ProfilePropertySettings.
Console.WriteLine("Current Root ProfilePropertySettings:");
int rootPPSCtr = 0;
foreach (ProfilePropertySettings rootPPS in profileSection.PropertySettings)
{
Console.WriteLine(" {0}: ProfilePropertySetting '{1}'", ++rootPPSCtr,
rootPPS.Name);
}
' Display all current root ProfilePropertySettings.
Console.WriteLine("Current Root ProfilePropertySettings:")
Dim rootPPSCtr As Integer = 0
For Each rootPPS As ProfilePropertySettings In profileSection.PropertySettings
Console.WriteLine(" {0}: ProfilePropertySetting '{1}'", ++rootPPSCtr, _
rootPPS.Name)
Next
注釈
ProfilePropertySettings クラスは、構成ファイルの profile セクションの properties サブセクションに追加された個々のプロパティの定義をプログラムで作成、アクセス、および変更する方法を提供します。
構成ファイルの profile セクションでは、ユーザー プロファイルのスキーマを指定します。 実行時に、ASP.NET コンパイル システムは、profile セクションで指定された情報を使用して、ProfileBaseから派生した ProfileCommon というクラスを生成します。
ProfileCommon クラス定義は、構成ファイルの profile セクションの properties サブセクションで定義されているプロパティに基づいています。 このクラスのインスタンスはユーザー プロファイルごとに作成され、 HttpContext.Profile プロパティを使用してコード内の個々のプロファイル値にアクセスできます。 プロファイルプロパティの詳細については、「プロファイルプロパティ の概要 ASP.NET 参照してください。 ASP.NET 2.0 に追加されたプロファイル機能の詳細については、「 ASP.NET プロファイルプロパティの概要」を参照してください。
コンストラクター
| 名前 | 説明 |
|---|---|
| ProfilePropertySettings(String, Boolean, SerializationMode, String, String, String, Boolean, String) |
指定した名前と設定を使用して、 ProfilePropertySettings クラスの新しいインスタンスを初期化します。 |
| ProfilePropertySettings(String) |
指定した名前を使用して、 ProfilePropertySettings クラスの新しいインスタンスを初期化します。 |
プロパティ
| 名前 | 説明 |
|---|---|
| AllowAnonymous |
動的に生成された |
| CurrentConfiguration |
現在のConfiguration インスタンスが属している構成階層を表す最上位ConfigurationElement インスタンスへの参照を取得します。 (継承元 ConfigurationElement) |
| CustomProviderData |
プロファイル プロパティ プロバイダーのカスタム データの文字列を取得または設定します。 |
| DefaultValue |
動的に生成された |
| ElementInformation |
ElementInformation オブジェクトのカスタマイズ不可能な情報と機能を含むConfigurationElement オブジェクトを取得します。 (継承元 ConfigurationElement) |
| ElementProperty |
ConfigurationElementProperty オブジェクト自体を表すConfigurationElement オブジェクトを取得します。 (継承元 ConfigurationElement) |
| EvaluationContext |
ContextInformation オブジェクトの ConfigurationElement オブジェクトを取得します。 (継承元 ConfigurationElement) |
| HasContext |
CurrentConfiguration プロパティが |
| Item[ConfigurationProperty] |
この構成要素のプロパティまたは属性を取得または設定します。 (継承元 ConfigurationElement) |
| Item[String] |
この構成要素のプロパティ、属性、または子要素を取得または設定します。 (継承元 ConfigurationElement) |
| LockAllAttributesExcept |
ロックされた属性のコレクションを取得します。 (継承元 ConfigurationElement) |
| LockAllElementsExcept |
ロックされた要素のコレクションを取得します。 (継承元 ConfigurationElement) |
| LockAttributes |
ロックされた属性のコレクションを取得します。 (継承元 ConfigurationElement) |
| LockElements |
ロックされた要素のコレクションを取得します。 (継承元 ConfigurationElement) |
| LockItem |
要素がロックされているかどうかを示す値を取得または設定します。 (継承元 ConfigurationElement) |
| Name |
動的に生成された |
| Properties |
プロパティのコレクションを取得します。 (継承元 ConfigurationElement) |
| Provider |
名前付きプロパティをシリアル化するときに使用するプロバイダーの名前を取得または設定します。 |
| ReadOnly |
動的に生成された |
| SerializeAs |
動的に生成された |
| Type |
動的に生成された |