Show / Hide Table of Contents

Class PropertyDefaults

Expose the AppSettingsSection associated with this DLL.

The configuration settings come from the base class. The configuration settings come from the base class, AssemblyLocatorBase; hence, this class also serves as the concrete example that is recommended to accompany distribution of any abstract base class.

The settings exposed by this class inhabit a configuration file that is associated with the DLL, itself, as opposed to the application configuration. Though its format is similar to that of the application configuration file, the DLL configuration lives in its own configuration file that has the same name as the DLL, with an additional suffix of .config.

Inheritance
System.Object
AssemblyLocatorBase
PropertyDefaults
DefaultErrorMessageColors
Inherited Members
AssemblyLocatorBase.ASSEMBLYDATAPATH_TOKEN
AssemblyLocatorBase._strAssemblyLocation
AssemblyLocatorBase.AssemblyDataPath
AssemblyLocatorBase.AssemblyLocation
AssemblyLocatorBase.RecoveredConfigurationExceptions
AssemblyLocatorBase.MissingConfigSettings
AssemblyLocatorBase.DLLConfiguration
AssemblyLocatorBase.DLLSettingsSection
AssemblyLocatorBase.DLLSettings
AssemblyLocatorBase.GetAssemblyVersion()
AssemblyLocatorBase.GetDLLSetting(String)
AssemblyLocatorBase.SetPropertiesFromDLLConfiguration(Type)
Namespace: WizardWrx.Core
Assembly: WizardWrx.Core.dll
Syntax
public class PropertyDefaults : AssemblyLocatorBase
Remarks

The rationale behind segregating these settings is that the affected application properties are ones that you want to keep consistent, or nearly so, across large groups of applications. Keeping them in a dedicated configuration file that travels with the DLL that implements them eliminates the thankless task of adding them to every application configuration file.

Constructors

| Improve this Doc View Source

PropertyDefaults()

Use this constructor when the class instance is a sibling (defined in the same assembly).

Declaration
public PropertyDefaults()
| Improve this Doc View Source

PropertyDefaults(System.Reflection.Assembly)

Use this constructor when the class instance and base class are defined in different assemblies.

Declaration
public PropertyDefaults(System.Reflection.Assembly pasmLinkedAssembly)
Parameters
Type Name Description
System.Reflection.Assembly pasmLinkedAssembly

Properties

| Improve this Doc View Source

ValuesCollection

Return the KeyValueConfigurationCollection from the AppSettingsSection section of the DLL configuration file.

Declaration
public KeyValueConfigurationCollection ValuesCollection { get; }
Property Value
Type Description
KeyValueConfigurationCollection

Methods

| Improve this Doc View Source

EnumerateMissingConfigurationValues()

Enumeate missing configuration values, if any.

Declaration
public string EnumerateMissingConfigurationValues()
Returns
Type Description
System.String

This method returns a message suitable for display on a console or a Windows message box. The returned message summarises the state of affairs, even when all defined values are represented in the configuration file.

| Improve this Doc View Source

GetAssemblyBuildDate(DateTimeKind)

Get the date on which the assembly was built.

Declaration
public DateTime GetAssemblyBuildDate(DateTimeKind pdtmKind)
Parameters
Type Name Description
DateTimeKind pdtmKind

Specify whether to return local or UTC time. Altough all three types are nominally supported, Unspecified is treated as Local.

Returns
Type Description
DateTime

The return value is the System.DateTime when the assembly was built.

| Improve this Doc View Source

GetAssemblyVersionString()

Get a version string, suitable for display in reports.

Declaration
public string GetAssemblyVersionString()
Returns
Type Description
System.String

The fully qualified version (i. e., all four parts) is returned.

  • Improve this Doc
  • View Source
Back to top Generated by DocFX