Click or drag to resize

SettingsBase Class

Represents the base class for application settings that are synchronized with its configuration file.
Inheritance Hierarchy

Namespace: GSF.Configuration
Assembly: GSF.Core (in GSF.Core.dll) Version: 2.4.207-beta+1781b796b2aa7a54013a031eb432fe4ccee31867
Syntax
View Source

The SettingsBase type exposes the following members.

Constructors
 NameDescription
Protected methodSettingsBase Creates a new instance of the SettingsBase class for the application's configuration file.
Top
Properties
 NameDescription
Public propertyCulture Gets or sets the CultureInfo to use for the conversion of setting values to and from String.
Public propertyItem Gets or sets the value of the specified field or property.
Protected propertyMemberAccessBindingFlags Gets or sets BindingFlags used to access fields and properties of derived class.
Public propertyRequireSerializeSettingAttribute Gets or sets flag that determines if SerializeSettingAttribute is required to exist before a field or property is serialized to the configuration file; defaults to False.
Top
Methods
 NameDescription
Protected methodCreateSetting Implementor should create setting in configuration file (or other location).
Public methodCreateValue Adds a setting to the application's configuration file, if it doesn't already exist.
Protected methodDeriveDefaultValue Attempts to get best default value for given member.
Public methodDispose Releases all the resources used by the CategorizedSettingsBase object.
Protected methodDispose(Boolean) Releases the unmanaged resources used by the CategorizedSettingsBase object and optionally releases the managed resources.
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodExecuteActionForFields Executes specified action over all public derived class member fields.
Protected methodExecuteActionForProperties Executes specified action over all public derived class properties.
Protected methodFinalize Releases the unmanaged resources before the CategorizedSettingsBase object is reclaimed by GC.
(Overrides ObjectFinalize)
Protected methodGetAttributeValueTAttribute, TValue Attempts to find specified attribute and return specified value.
Public methodGetDefaultValue Gets the default value specified by DefaultValueAttribute, if any, applied to the specified field or property.
Public methodGetEncryptKey Gets the optional private encryption key specified by EncryptSettingAttribute, if any, applied to the specified field or property.
Public methodGetEncryptStatus Gets the encryption status specified by EncryptSettingAttribute, if any, applied to the specified field or property.
Public methodGetEnumerator Returns an enumerator based on String elements that iterates over the field and property names of this class that are targeted for serialization to the configuration file.
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodGetSettingName Gets setting name to use for specified field or property.
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Public methodGetValue(String, Type) Gets the application's configuration file setting converted to the given type.
Public methodGetValueT(String) Gets the application's configuration file setting converted to the given type.
Public methodGetValueT(String, T) Copies the specified application setting into the given value.
Protected methodInitialize Initializes configuration settings from derived class fields or properties.
Public methodLoad Loads configuration file into setting fields.
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Protected methodPersistSettings Implementor should persist any pending changes to configuration file (or other location).
Public methodRestoreDefaultSettings Restores the default settings of the configuration file.
Protected methodRetrieveSetting Implementor should retrieve setting from configuration file (or other location).
Public methodSave Saves setting fields into configuration file.
Public methodSetValue Copies the given value into the specified application setting.
Protected methodStoreSetting Implementor should store setting to configuration file (or other location).
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
Extension Methods
 NameDescription
Public Extension MethodAllParallelString Determines whether all elements of a sequence satisfy a condition with each item being tested in parallel.
(Defined by CollectionExtensions)
Public Extension MethodDistinctByString, TKey Returns only the elements whose keys are distinct.
(Defined by CollectionExtensions)
Public Extension MethodGetEnumValueOrDefault Gets the enumeration constant for value, if defined in the enumeration, or a default value.
(Defined by EnumExtensions)
Public Extension MethodGetEnumValueOrDefaultT Gets the enumeration constant for this value, if defined in the enumeration, or a default value.
(Defined by EnumExtensions)
Public Extension MethodMajorityString Returns the majority value in the collection, or default type value if no item represents the majority.
(Defined by CollectionExtensions)
Public Extension MethodMajorityString Returns the majority value in the collection, or defaultValue if no item represents the majority.
(Defined by CollectionExtensions)
Public Extension MethodMajorityByString, TKey Returns the majority value in the collection, or default type value if no item represents the majority.
(Defined by CollectionExtensions)
Public Extension MethodMajorityByString, TKey Returns the majority value in the collection, or defaultValue if no item represents the majority.
(Defined by CollectionExtensions)
Public Extension MethodMaxStringReturns the largest item from the enumeration.
(Defined by CollectionExtensions)
Public Extension MethodMaxStringReturns the largest item from the enumeration.
(Defined by CollectionExtensions)
Public Extension MethodMaxByString, TKeySelects the largest item from the enumeration.
(Defined by CollectionExtensions)
Public Extension MethodMedianString Gets the median item(s) from an enumeration, i.e., one return item for odd lengths, two for even lengths.
(Defined by CollectionExtensions)
Public Extension MethodMiddleString Gets the middle item(s) from an enumeration, i.e., one return item for odd lengths, two for even lengths.
(Defined by CollectionExtensions)
Public Extension MethodMinStringReturns the smallest item from the enumeration.
(Defined by CollectionExtensions)
Public Extension MethodMinStringReturns the smallest item from the enumeration.
(Defined by CollectionExtensions)
Public Extension MethodMinByString, TKeySelects the smallest item from the enumeration.
(Defined by CollectionExtensions)
Public Extension MethodMinorityString Returns the minority value in the collection, or default type value if no item represents the minority.
(Defined by CollectionExtensions)
Public Extension MethodMinorityString Returns the minority value in the collection, or defaultValue if no item represents the minority.
(Defined by CollectionExtensions)
Public Extension MethodMinorityByString, TKey Returns the minority value in the collection, or default type value if no item represents the majority.
(Defined by CollectionExtensions)
Public Extension MethodMinorityByString, TKey Returns the minority value in the collection, or defaultValue if no item represents the majority.
(Defined by CollectionExtensions)
Public Extension MethodStandardDeviationString Computes the standard deviation over a sequence of Double values.
(Defined by NumericalAnalysisExtensions)
Public Extension MethodStandardDeviationString Computes the standard deviation over a sequence of Decimal values.
(Defined by NumericalAnalysisExtensions)
Public Extension MethodStandardDeviationString Computes the standard deviation over a sequence of Single values.
(Defined by NumericalAnalysisExtensions)
Public Extension MethodToDelimitedStringStringConverts an enumeration to a string, using the default delimiter ("|") that can later be converted back to a list using LoadDelimitedString.
(Defined by CollectionExtensions)
Public Extension MethodToDelimitedStringStringConverts an enumeration to a string that can later be converted back to a list using LoadDelimitedString.
(Defined by CollectionExtensions)
Public Extension MethodToDelimitedStringStringConverts an enumeration to a string that can later be converted back to a list using LoadDelimitedString.
(Defined by CollectionExtensions)
Public Extension MethodToPagedListString Gets a PagedListT to paginate source enumeration for a given page and specified pageSize.
(Defined by CollectionExtensions)
Top
Remarks
In order to make custom types serializable for the configuration file, implement a TypeConverter for the type.
See MSDN for details.
See Also