ConfigurationPropertyとは? わかりやすく解説

ConfigurationProperty クラス

メモ : このクラスは、.NET Framework version 2.0新しく追加されたものです。

構成要素属性または子を表します。このクラス継承できません。

名前空間: System.Configuration
アセンブリ: System.Configuration (system.configuration.dll 内)
構文構文

Public NotInheritable Class
 ConfigurationProperty
Dim instance As ConfigurationProperty
public sealed class ConfigurationProperty
public ref class ConfigurationProperty sealed
public final class ConfigurationProperty
public final class ConfigurationProperty
解説解説

次の例に示す CustomSection のように、単純な ConfigurationElement の場合ConfigurationProperty オブジェクトは、fileName などの属性表します

authentication など、サブセクションを含むセクションのように、もっと複雑な構成要素場合ConfigurationProperty オブジェクトは、属性だけでなく ConfigurationElement オブジェクトも表すことがあります

ConfigurationPropertyCollection クラスは、構成要素属性または ConfigurationElement オブジェクトとなる、ConfigurationProperty オブジェクトコレクション表します

ConfigurationProperty クラスは、個々構成設定表します。このクラス使用すると、特定の構成エンティティ (属性または要素) の名前、型、および既定値取得または設定を行うことができ、また、属性必須かどうか属性要素キーであるかどうか、または属性既定要素コレクションを表すかどうか指定できます

実装時の注意 すべての ConfigurationElement オブジェクトは、要素属性または子要素コレクションを表す ConfigurationProperty オブジェクト内部コレクションである ConfigurationPropertyCollection作成しますカスタマイズできない情報機能は、ElementInformation プロパティ提供する ElementInformation オブジェクト格納されます。 プログラム コーディング モデルまたは宣言 (属性付き) コーディング モデル使用してカスタム構成要素作成できます

使用例使用例
  1. カスタム セクション作成時に ConfigurationProperty使用する方法次のコード例示します

' Define a custom section.
' It shows how to use the ConfigurationProperty
' class when defining a custom section
' programmatically. 
' The variables prefixed with the
' _ sign are ConfigurationProperty types.

NotInheritable Public Class
 CustomSection
   Inherits ConfigurationSection
   
   
   ' CustomSection constructor.
   Shared Sub New()
      
      ' Initialize the _FileName
         _FileName = New ConfigurationProperty( _
         "fileName", GetType(String),
 _
         "default.txt")
      ' Initialize the _MaxUsers
         _MaxUsers = New ConfigurationProperty( _
         "maxUsers", GetType(Long),
 _
         Fix(1000), ConfigurationPropertyOptions.None)
      ' Initialize the _MaxIdleTime
         Dim minTime As TimeSpan = _
         TimeSpan.FromSeconds(30)
         Dim maxTime As TimeSpan = _
         TimeSpan.FromMinutes(5)
      
         Dim _TimeSpanValidator = _
         New TimeSpanValidator(minTime, maxTime, False)
      
         _MaxIdleTime = New ConfigurationProperty( _
         "maxIdleTime", GetType(TimeSpan),
 _
         TimeSpan.FromMinutes(5), _
         TypeDescriptor.GetConverter(GetType(TimeSpan)), _
         _TimeSpanValidator, _
         ConfigurationPropertyOptions.IsRequired, _
         "[Description:This is the max idle time.]")

         ' Initialize the _Alias
         _Alias = New ConfigurationProperty( _
         "alias", GetType(String),
 "alias.txt")
      
      
      
      ' Property collection initialization.
      ' The collection (property bag) that contains 
      ' the properties is declared as:
      ' ConfigurationPropertyCollection _Properties;
      _Properties = New ConfigurationPropertyCollection()
      ' The collection (property bag) that contains 
      ' the properties is declared as:
      ' ConfigurationPropertyCollection _Properties;
      _Properties.Add(_FileName)
      _Properties.Add(_Alias)
      _Properties.Add(_MaxUsers)
         _Properties.Add(_MaxIdleTime)

     End Sub 'New 
   
   ' Return the initialized property bag
   ' for the configuration element.
   ' The collection (property bag) that contains 
   ' the properties is declared as:
   ' ConfigurationPropertyCollection _Properties;
   
     Protected Overrides ReadOnly
 Property Properties() _
     As ConfigurationPropertyCollection
         Get
             Return _Properties
         End Get
     End Property
   
   
   ' Clear the property.
   ' It deletes all the attributes of the
   ' configuration element represented by
   ' the property.
   Public Sub ClearCollection()
      Properties.Clear()
   End Sub 'ClearCollection
   
   ' Remove an element from the property collection.
   ' It deletes the specified attribute from the
   ' configuration element represented by
   ' the property.
   Public Sub RemoveCollectionElement(elName
 As String)
      Properties.Remove(elName)
   End Sub 'RemoveCollectionElement
   
   ' Get the property collection enumerator.
   Public Function GetCollectionEnumerator()
 As IEnumerator
      Return Properties.GetEnumerator()
   End Function 'GetCollectionEnumerator
   
   
   
     <StringValidator(InvalidCharacters:= _
     " ~!@#$%^&*()[]{}/;'""|\", MinLength:=1,
 _
     MaxLength:=60)> _
     Public Property FileName() As
 String
         Get
             Return CStr(Me("fileName"))
         End Get
         Set(ByVal value As
 String)
             Me("fileName") = Value
         End Set
     End Property
   
   
     <StringValidator(InvalidCharacters:= _
     " ~!@#$%^&*()[]{}/;'""|\", MinLength:=1,
 _
     MaxLength:=60)> _
     Public Property [Alias]() As
 String
         Get
             Return CStr(Me("alias"))
         End Get
         Set(ByVal value As
 String)
             Me("alias") = Value
         End Set
     End Property
   
   
     <LongValidator(MinValue:=1, _
     MaxValue:=1000000, ExcludeRange:=False)> _
     Public Property MaxUsers() As
 Long
         Get
             Return Fix(Me("maxUsers"))
         End Get
         Set(ByVal value As
 Long)
             Me("maxUsers") = Value
         End Set
     End Property
   
   
   
   Public Property MaxIdleTime() As
 TimeSpan
      Get
         Return CType(Me("maxIdleTime"),
 TimeSpan)
      End Get
      Set
         Me("maxIdleTime") = value
      End Set
   End Property
End Class 'CustomSection
 
// Define a custom section.
// It shows how to use the ConfigurationProperty
// class when defining a custom section
// programmatically. 
// The variables prefixed with the
// _ sign are ConfigurationProperty types.
public sealed class CustomSection :
    ConfigurationSection
{

    // CustomSection constructor.
    static CustomSection()
    {

        // Initialize the _FileName
        _FileName =
            new ConfigurationProperty("fileName",
            typeof(string), "default.txt");

        // Initialize the _MaxUsers
        _MaxUsers =
            new ConfigurationProperty("maxUsers",
            typeof(long), (long)1000,
            ConfigurationPropertyOptions.None);

        // Initialize the _MaxIdleTime
        TimeSpan minTime = TimeSpan.FromSeconds(30);
        TimeSpan maxTime = TimeSpan.FromMinutes(5);

        ConfigurationValidatorBase _TimeSpanValidator =
            new TimeSpanValidator(minTime, maxTime, false);

        _MaxIdleTime =
           new ConfigurationProperty("maxIdleTime",
       typeof(TimeSpan), TimeSpan.FromMinutes(5),
       TypeDescriptor.GetConverter(typeof(TimeSpan)),
       _TimeSpanValidator,
       ConfigurationPropertyOptions.IsRequired,
       "[Description:This is the max idle time.]");

        // Initialize the _Alias
        _Alias =
            new ConfigurationProperty("alias",
            typeof(string), "alias.txt");



        // Property collection initialization.
        // The collection (property bag) that contains 
        // the properties is declared as:
        // ConfigurationPropertyCollection _Properties;
        _Properties =
            new ConfigurationPropertyCollection();

        // The collection (property bag) that contains 
        // the properties is declared as:
        // ConfigurationPropertyCollection _Properties;
        _Properties.Add(_FileName);
        _Properties.Add(_Alias);
        _Properties.Add(_MaxUsers);
        _Properties.Add(_MaxIdleTime);

    }

    // Return the initialized property bag
    // for the configuration element.
    // The collection (property bag) that contains 
    // the properties is declared as:
    // ConfigurationPropertyCollection _Properties;
    protected override ConfigurationPropertyCollection Properties
    {
        get
        {
            return _Properties;
        }
    }


    // Clear the property.
    // It deletes all the attributes of the
    // configuration element represented by
    // the property.
    public void ClearCollection()
    {
        Properties.Clear();
    }

    // Remove an element from the property collection.
    // It deletes the specified attribute from the
    // configuration element represented by
    // the property.
    public void RemoveCollectionElement(string
 elName)
    {
        Properties.Remove(elName);
    }

    // Get the property collection enumerator.
    public IEnumerator GetCollectionEnumerator()
    {
        return (Properties.GetEnumerator());
    }

    

    [StringValidator(InvalidCharacters = " ~!@#$%^&*()[]{}/;'\"|\\"
,
        MinLength = 1, MaxLength = 60)]
    public string FileName
    {
        get
        {
            return (string)this["fileName"];
        }
        set
        {
            this["fileName"] = value;
        }
    }

    [StringValidator(InvalidCharacters = " ~!@#$%^&*()[]{}/;'\"|\\"
,
        MinLength = 1, MaxLength = 60)]
    public string Alias
    {
        get
        {
            return (string)this["alias"];
        }
        set
        {
            this["alias"] = value;
        }
    }

    [LongValidator(MinValue = 1, MaxValue = 1000000,
        ExcludeRange = false)]
    public long MaxUsers
    {
        get
        {
            return (long)this["maxUsers"];
        }
        set
        {
            this["maxUsers"] = value;
        }
    }


    public TimeSpan MaxIdleTime
    {
        get
        {
            return (TimeSpan)this["maxIdleTime"];
        }
        set
        {
            this["maxIdleTime"] = value;
        }
    }

}

上記コード例使用した構成抜粋次に示します

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <configSections>
    <section name="CustomSection" type="Samples.AspNet, ConfigurationProperty,
 Version=1.0.0.0, Culture=neutral, PublicKeyToken=null" allowDefinition="Everywhere"
 allowExeDefinition="MachineToApplication" restartOnExternalChanges="true" />
  </configSections>
  <CustomSection fileName="default.txt" alias="alias.txt" maxUsers="1000"
    maxIdleTime="00:05:00" />
</configuration>

上記セクション作成する方法の例を次に示します

' Create a custom section.
Shared Sub CreateSection()
   Try
      
      Dim customSection As CustomSection
      
      ' Get the current configuration file.
         Dim config As System.Configuration.Configuration
 = _
         ConfigurationManager.OpenExeConfiguration( _
         ConfigurationUserLevel.None)
      
      ' Create the section entry  
      ' in the <configSections> and the 
      ' related target section in <configuration>.
      If config.Sections("CustomSection")
 Is Nothing Then
         customSection = New CustomSection()
         config.Sections.Add("CustomSection", customSection)
         customSection.SectionInformation.ForceSave = True
         config.Save(ConfigurationSaveMode.Full)
      End If
   Catch err As ConfigurationErrorsException
      Console.WriteLine(err.ToString())
   End Try
End Sub 'CreateSection
 
// Create a custom section.
static void CreateSection()
{
    try
    {

        CustomSection customSection;

        // Get the current configuration file.
        System.Configuration.Configuration config =
                ConfigurationManager.OpenExeConfiguration(
                ConfigurationUserLevel.None);

        // Create the section entry  
        // in the <configSections> and the 
        // related target section in <configuration>.
        if (config.Sections["CustomSection"] == null)
        {
            customSection = new CustomSection();
            config.Sections.Add("CustomSection", customSection);
            customSection.SectionInformation.ForceSave = true;
            config.Save(ConfigurationSaveMode.Full);
        }
    }
    catch (ConfigurationErrorsException err)
    {
        Console.WriteLine(err.ToString());
    }

}
継承階層継承階層
System.Object
  System.Configuration.ConfigurationProperty
スレッド セーフスレッド セーフ
この型の public static (Visual Basic では Shared) メンバはすべて、スレッド セーフです。インスタンス メンバ場合は、スレッド セーフであるとは限りません。
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
ConfigurationProperty メンバ
System.Configuration 名前空間
ElementInformation
ConfigurationElementCollection クラス
ConfigurationElementCollectionType 列挙
ConfigurationElement クラス
ConfigurationPropertyCollection
ConfigurationSection

ConfigurationProperty コンストラクタ (String, Type, Object)

メモ : このコンストラクタは、.NET Framework version 2.0新しく追加されたものです。

ConfigurationProperty クラス新しインスタンス作成します

名前空間: System.Configuration
アセンブリ: System.Configuration (system.configuration.dll 内)
構文構文

解説解説
使用例使用例

System.Configuration.ConfigurationProperty(String,Type,Object) コンストラクタ使用して構成プロパティ オブジェクトインスタンス化する方法次のコード例示します

' Initialize the _FileName
   _FileName = New ConfigurationProperty( _
   "fileName", GetType(String),
 _
   "default.txt")
// Initialize the _FileName
_FileName =
    new ConfigurationProperty("fileName",
    typeof(string), "default.txt");
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
ConfigurationProperty クラス
ConfigurationProperty メンバ
System.Configuration 名前空間
ElementInformation
ConfigurationElementCollection クラス
ConfigurationElementCollectionType 列挙
ConfigurationElement クラス
ConfigurationPropertyCollection
ConfigurationSection

ConfigurationProperty コンストラクタ (String, Type, Object, ConfigurationPropertyOptions)

メモ : このコンストラクタは、.NET Framework version 2.0新しく追加されたものです。

ConfigurationProperty クラス新しインスタンス作成します

名前空間: System.Configuration
アセンブリ: System.Configuration (system.configuration.dll 内)
構文構文

Public Sub New ( _
    name As String, _
    type As Type, _
    defaultValue As Object, _
    options As ConfigurationPropertyOptions _
)
Dim name As String
Dim type As Type
Dim defaultValue As Object
Dim options As ConfigurationPropertyOptions

Dim instance As New ConfigurationProperty(name,
 type, defaultValue, options)
public ConfigurationProperty (
    string name,
    Type type,
    Object defaultValue,
    ConfigurationPropertyOptions options
)
public:
ConfigurationProperty (
    String^ name, 
    Type^ type, 
    Object^ defaultValue, 
    ConfigurationPropertyOptions options
)
public ConfigurationProperty (
    String name, 
    Type type, 
    Object defaultValue, 
    ConfigurationPropertyOptions options
)
public function ConfigurationProperty (
    name : String, 
    type : Type, 
    defaultValue : Object, 
    options : ConfigurationPropertyOptions
)

パラメータ

name

構成エンティティの名前。

type

構成エンティティの型。

defaultValue

構成エンティティ既定値

options

ConfigurationPropertyOptions 列挙値の 1 つ

使用例使用例

System.Configuration.ConfigurationProperty(String,Type,Object,ConfigurationPropertyOptions) コンストラクタ使用して構成プロパティ オブジェクトインスタンス化する方法次のコード例示します

' Initialize the _MaxUsers
   _MaxUsers = New ConfigurationProperty( _
   "maxUsers", GetType(Long),
 _
   Fix(1000), ConfigurationPropertyOptions.None)
// Initialize the _MaxUsers
_MaxUsers =
    new ConfigurationProperty("maxUsers",
    typeof(long), (long)1000,
    ConfigurationPropertyOptions.None);
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
ConfigurationProperty クラス
ConfigurationProperty メンバ
System.Configuration 名前空間
ElementInformation
ConfigurationElementCollection クラス
ConfigurationElementCollectionType 列挙
ConfigurationElement クラス
ConfigurationPropertyCollection
ConfigurationSection

ConfigurationProperty コンストラクタ (String, Type, Object, TypeConverter, ConfigurationValidatorBase, ConfigurationPropertyOptions)

メモ : このコンストラクタは、.NET Framework version 2.0新しく追加されたものです。

ConfigurationProperty クラス新しインスタンス作成します

名前空間: System.Configuration
アセンブリ: System.Configuration (system.configuration.dll 内)
構文構文

Public Sub New ( _
    name As String, _
    type As Type, _
    defaultValue As Object, _
    typeConverter As TypeConverter, _
    validator As ConfigurationValidatorBase, _
    options As ConfigurationPropertyOptions _
)
Dim name As String
Dim type As Type
Dim defaultValue As Object
Dim typeConverter As TypeConverter
Dim validator As ConfigurationValidatorBase
Dim options As ConfigurationPropertyOptions

Dim instance As New ConfigurationProperty(name,
 type, defaultValue, typeConverter, validator, options)
public ConfigurationProperty (
    string name,
    Type type,
    Object defaultValue,
    TypeConverter typeConverter,
    ConfigurationValidatorBase validator,
    ConfigurationPropertyOptions options
)
public:
ConfigurationProperty (
    String^ name, 
    Type^ type, 
    Object^ defaultValue, 
    TypeConverter^ typeConverter, 
    ConfigurationValidatorBase^ validator, 
    ConfigurationPropertyOptions options
)
public ConfigurationProperty (
    String name, 
    Type type, 
    Object defaultValue, 
    TypeConverter typeConverter, 
    ConfigurationValidatorBase validator, 
    ConfigurationPropertyOptions options
)
public function ConfigurationProperty (
    name : String, 
    type : Type, 
    defaultValue : Object, 
    typeConverter : TypeConverter, 
    validator : ConfigurationValidatorBase, 
    options : ConfigurationPropertyOptions
)

パラメータ

name

構成エンティティの名前。

type

構成エンティティの型。

defaultValue

構成エンティティ既定値

typeConverter

適用するコンバータの型。

validator

使用する検証コントロール

options

ConfigurationPropertyOptions 列挙値の 1 つ

使用例使用例

System.Configuration.ConfigurationProperty(String,Type,Object,TypeConverter,ConfigurationValidatorBase,ConfigurationPropertyOptions) コンストラクタ呼び出すときに使用するパラメータ種類次のコード例示します

' Initialize the _MaxIdleTime
   Dim minTime As TimeSpan = _
   TimeSpan.FromSeconds(30)
   Dim maxTime As TimeSpan = _
   TimeSpan.FromMinutes(5)

   Dim _TimeSpanValidator = _
   New TimeSpanValidator(minTime, maxTime, False)

   _MaxIdleTime = New ConfigurationProperty( _
   "maxIdleTime", GetType(TimeSpan),
 _
   TimeSpan.FromMinutes(5), _
   TypeDescriptor.GetConverter(GetType(TimeSpan)), _
   _TimeSpanValidator, _
   ConfigurationPropertyOptions.IsRequired, _
   "[Description:This is the max idle time.]")
 // Initialize the _MaxIdleTime
 TimeSpan minTime = TimeSpan.FromSeconds(30);
 TimeSpan maxTime = TimeSpan.FromMinutes(5);

 ConfigurationValidatorBase _TimeSpanValidator =
     new TimeSpanValidator(minTime, maxTime, false);

 _MaxIdleTime =
    new ConfigurationProperty("maxIdleTime",
typeof(TimeSpan), TimeSpan.FromMinutes(5),
TypeDescriptor.GetConverter(typeof(TimeSpan)),
_TimeSpanValidator,
ConfigurationPropertyOptions.IsRequired,
"[Description:This is the max idle time.]");
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
ConfigurationProperty クラス
ConfigurationProperty メンバ
System.Configuration 名前空間
ElementInformation
ConfigurationElementCollection クラス
ConfigurationElementCollectionType 列挙
ConfigurationElement クラス
ConfigurationPropertyCollection
ConfigurationSection

ConfigurationProperty コンストラクタ (String, Type, Object, TypeConverter, ConfigurationValidatorBase, ConfigurationPropertyOptions, String)

メモ : このコンストラクタは、.NET Framework version 2.0新しく追加されたものです。

ConfigurationProperty クラス新しインスタンス作成します

名前空間: System.Configuration
アセンブリ: System.Configuration (system.configuration.dll 内)
構文構文

Public Sub New ( _
    name As String, _
    type As Type, _
    defaultValue As Object, _
    typeConverter As TypeConverter, _
    validator As ConfigurationValidatorBase, _
    options As ConfigurationPropertyOptions, _
    description As String _
)
Dim name As String
Dim type As Type
Dim defaultValue As Object
Dim typeConverter As TypeConverter
Dim validator As ConfigurationValidatorBase
Dim options As ConfigurationPropertyOptions
Dim description As String

Dim instance As New ConfigurationProperty(name,
 type, defaultValue, typeConverter, validator, options, description)
public ConfigurationProperty (
    string name,
    Type type,
    Object defaultValue,
    TypeConverter typeConverter,
    ConfigurationValidatorBase validator,
    ConfigurationPropertyOptions options,
    string description
)
public:
ConfigurationProperty (
    String^ name, 
    Type^ type, 
    Object^ defaultValue, 
    TypeConverter^ typeConverter, 
    ConfigurationValidatorBase^ validator, 
    ConfigurationPropertyOptions options, 
    String^ description
)
public ConfigurationProperty (
    String name, 
    Type type, 
    Object defaultValue, 
    TypeConverter typeConverter, 
    ConfigurationValidatorBase validator, 
    ConfigurationPropertyOptions options, 
    String description
)
public function ConfigurationProperty (
    name : String, 
    type : Type, 
    defaultValue : Object, 
    typeConverter : TypeConverter, 
    validator : ConfigurationValidatorBase, 
    options : ConfigurationPropertyOptions, 
    description : String
)

パラメータ

name

構成エンティティの名前。

type

構成エンティティの型。

defaultValue

構成エンティティ既定値

typeConverter

適用するコンバータの型。

validator

使用する検証コントロール

options

ConfigurationPropertyOptions 列挙値の 1 つ

description

構成エンティティ説明

使用例使用例

System.Configuration.ConfigurationProperty(String,Type,Object,TypeConverter,ConfigurationValidatorBase,ConfigurationPropertyOptions,String) コンストラクタ使用して構成プロパティ オブジェクトインスタンス化する方法次のコード例示します

' Initialize the _MaxIdleTime
   Dim minTime As TimeSpan = _
   TimeSpan.FromSeconds(30)
   Dim maxTime As TimeSpan = _
   TimeSpan.FromMinutes(5)

   Dim _TimeSpanValidator = _
   New TimeSpanValidator(minTime, maxTime, False)

   _MaxIdleTime = New ConfigurationProperty( _
   "maxIdleTime", GetType(TimeSpan),
 _
   TimeSpan.FromMinutes(5), _
   TypeDescriptor.GetConverter(GetType(TimeSpan)), _
   _TimeSpanValidator, _
   ConfigurationPropertyOptions.IsRequired, _
   "[Description:This is the max idle time.]")
 // Initialize the _MaxIdleTime
 TimeSpan minTime = TimeSpan.FromSeconds(30);
 TimeSpan maxTime = TimeSpan.FromMinutes(5);

 ConfigurationValidatorBase _TimeSpanValidator =
     new TimeSpanValidator(minTime, maxTime, false);

 _MaxIdleTime =
    new ConfigurationProperty("maxIdleTime",
typeof(TimeSpan), TimeSpan.FromMinutes(5),
TypeDescriptor.GetConverter(typeof(TimeSpan)),
_TimeSpanValidator,
ConfigurationPropertyOptions.IsRequired,
"[Description:This is the max idle time.]");
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
ConfigurationProperty クラス
ConfigurationProperty メンバ
System.Configuration 名前空間
ElementInformation
ConfigurationElementCollection クラス
ConfigurationElementCollectionType 列挙
ConfigurationElement クラス
ConfigurationPropertyCollection
ConfigurationSection

ConfigurationProperty コンストラクタ (String, Type)

メモ : このコンストラクタは、.NET Framework version 2.0新しく追加されたものです。

ConfigurationProperty クラス新しインスタンス作成します

名前空間: System.Configuration
アセンブリ: System.Configuration (system.configuration.dll 内)
構文構文

Dim name As String
Dim type As Type

Dim instance As New ConfigurationProperty(name,
 type)
public ConfigurationProperty (
    string name,
    Type type
)
public:
ConfigurationProperty (
    String^ name, 
    Type^ type
)
public ConfigurationProperty (
    String name, 
    Type type
)
public function ConfigurationProperty (
    name : String, 
    type : Type
)

パラメータ

name

構成エンティティの名前。

type

構成エンティティの型。

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
ConfigurationProperty クラス
ConfigurationProperty メンバ
System.Configuration 名前空間

ConfigurationProperty コンストラクタ

この ConfigurationProperty の新しインスタンス作成します
オーバーロードの一覧オーバーロードの一覧

名前 説明
ConfigurationProperty (String, Type) ConfigurationProperty クラス新しインスタンス作成します
ConfigurationProperty (String, Type, Object) ConfigurationProperty クラス新しインスタンス作成します
ConfigurationProperty (String, Type, Object, ConfigurationPropertyOptions) ConfigurationProperty クラス新しインスタンス作成します
ConfigurationProperty (String, Type, Object, TypeConverter, ConfigurationValidatorBase, ConfigurationPropertyOptions) ConfigurationProperty クラス新しインスタンス作成します
ConfigurationProperty (String, Type, Object, TypeConverter, ConfigurationValidatorBase, ConfigurationPropertyOptions, String) ConfigurationProperty クラス新しインスタンス作成します
参照参照

関連項目

ConfigurationProperty クラス
ConfigurationProperty メンバ
System.Configuration 名前空間

ConfigurationProperty プロパティ


パブリック プロパティパブリック プロパティ

  名前 説明
パブリック プロパティ Converter 構成ファイルへの書き込み目的として、この ConfigurationProperty を XML 表現変換するために使用する TypeConverter を取得します
パブリック プロパティ DefaultValue この ConfigurationProperty プロパティ既定値取得します
パブリック プロパティ Description ConfigurationProperty関連付けられている説明取得します
パブリック プロパティ IsDefaultCollection プロパティ要素既定コレクションであるかどうか取得または設定します
パブリック プロパティ IsKey この ConfigurationProperty が、格納する側の ConfigurationElement オブジェクトキーかどうかを示す値を取得します
パブリック プロパティ IsRequired この ConfigurationProperty が必要かどうかを示す値を取得します
パブリック プロパティ Name この ConfigurationProperty の名前を取得します
パブリック プロパティ Type この ConfigurationProperty オブジェクトの型を取得します
パブリック プロパティ Validator この ConfigurationProperty オブジェクト検証するために使用する ConfigurationValidatorAttribute を取得します
参照参照

関連項目

ConfigurationProperty クラス
System.Configuration 名前空間
ElementInformation
ConfigurationElementCollection クラス
ConfigurationElementCollectionType 列挙
ConfigurationElement クラス
ConfigurationPropertyCollection
ConfigurationSection

ConfigurationProperty メソッド


パブリック メソッドパブリック メソッド

プロテクト メソッドプロテクト メソッド
参照参照

関連項目

ConfigurationProperty クラス
System.Configuration 名前空間
ElementInformation
ConfigurationElementCollection クラス
ConfigurationElementCollectionType 列挙
ConfigurationElement クラス
ConfigurationPropertyCollection
ConfigurationSection

ConfigurationProperty メンバ

構成要素属性または子を表します。このクラス継承できません。

ConfigurationProperty データ型公開されるメンバを以下の表に示します


パブリック コンストラクタパブリック コンストラクタ
  名前 説明
パブリック メソッド ConfigurationProperty オーバーロードされます。 この ConfigurationProperty の新しインスタンス作成します
パブリック プロパティパブリック プロパティ
  名前 説明
パブリック プロパティ Converter 構成ファイルへの書き込み目的として、この ConfigurationPropertyXML 表現変換するために使用する TypeConverter を取得します
パブリック プロパティ DefaultValue この ConfigurationProperty プロパティ既定値取得します
パブリック プロパティ Description ConfigurationProperty関連付けられている説明取得します
パブリック プロパティ IsDefaultCollection プロパティ要素既定コレクションであるかどうか取得または設定します
パブリック プロパティ IsKey この ConfigurationProperty が、格納する側の ConfigurationElement オブジェクトキーかどうかを示す値を取得します
パブリック プロパティ IsRequired この ConfigurationProperty が必要かどうかを示す値を取得します
パブリック プロパティ Name この ConfigurationProperty の名前を取得します
パブリック プロパティ Type この ConfigurationProperty オブジェクトの型を取得します
パブリック プロパティ Validator この ConfigurationProperty オブジェクト検証するために使用する ConfigurationValidatorAttribute を取得します
パブリック メソッドパブリック メソッド
プロテクト メソッドプロテクト メソッド
参照参照

関連項目

ConfigurationProperty クラス
System.Configuration 名前空間
ElementInformation
ConfigurationElementCollection クラス
ConfigurationElementCollectionType 列挙
ConfigurationElement クラス
ConfigurationPropertyCollection
ConfigurationSection



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

「ConfigurationProperty」の関連用語

ConfigurationPropertyのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



ConfigurationPropertyのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.

©2025 GRAS Group, Inc.RSS