7.9 KiB
source_files, generated_at, model, schema_version, sha256
| source_files | generated_at | model | schema_version | sha256 | |
|---|---|---|---|---|---|
|
2026-04-16T04:45:05.933790+00:00 | Qwen/Qwen3-Coder-Next-FP8 | 1 | 99758cb5d382b63b |
Resources
Documentation: StringResources Class (DataPRO/Modules/InstallerCustomActions/MigrateConfiguration/Resources/StringResources.Designer.cs)
1. Purpose
This module provides a strongly-typed, localized string resource accessor for the MigrateConfiguration installer custom action. It centralizes all user-facing messages related to configuration migration (e.g., status updates, warnings, errors) to support localization and maintain consistency across installer logic. The class is auto-generated from .resx resources and is not intended for manual modification.
2. Public Interface
All members are internal (not public), but are exposed as static properties for use within the same assembly. The class is named StringResources in the MigrateConfiguration.Resources namespace.
| Property | Type | Description |
|---|---|---|
ResourceManager |
System.Resources.ResourceManager |
Returns a cached ResourceManager instance for the MigrateConfiguration.Resources.StringResources resource set. Thread-safe after first access. |
Culture |
System.Globalization.CultureInfo |
Gets or sets the UI culture used for resource lookups. Overrides the current thread's CurrentUICulture for this class. |
ApplicationSettings |
string |
Returns "applicationSettings" — likely the config section name for application-level settings. |
ConfigDidNotNeedToBeUpdated |
string |
Returns "DataPRO.exe.config did not need to be updated." |
ConfigMigrationStatus |
string |
Returns "Config migration status." — likely a log header. |
ConfigWasUpdated |
string |
Returns "DataPRO.exe.config was updated from the {0} installation." — format expects one argument (e.g., source version). |
DataPROWin7PropertiesSettings |
string |
Returns "DataPROWin7.Properties.Settings." — likely the user settings section name. |
DataUpOneLevel |
string |
Returns "..\Data" — relative path to data directory. |
DataUpTwoLevels |
string |
Returns "..\..\Data" — relative path to data directory (two levels up). |
DownloadFolder |
string |
Returns "DownloadFolder" — likely a config key name. |
DTSCommonCorePluginLibConfig |
string |
Returns "DTS.Common.Core.PluginLib.Config" — likely a config section name. |
DTSPlugins |
string |
Returns "DTSPlugins" — likely a config key name. |
DTSPluginsNeedsModification |
string |
Returns "The 'DTSPlugins' key in DataPRO.exe.config must be manually changed to '..//RunTimeModules'." |
DTSViewerModules |
string |
Returns "DTSViewerModules" — likely a config key name. |
FailedToCopyLicense |
string |
Returns "Failed to copy license." |
ImportArchiveFolder |
string |
Returns "ImportArchiveFolder" — likely a config key name. |
ImportArchiveUpTwoLevels |
string |
Returns "..\..\ImportArchive" — relative path. |
InstallerLicenseFileFoundCopied |
string |
Returns "Installer license file found and copied." |
KeyNotFound |
string |
Returns "DTSPlugins key not found: {0}." — format expects one argument (e.g., key name). |
NewSettingsCouldNotBeFound |
string |
Returns "Warning: DataPRO.exe.config was not updated because config settings from new version of DataPRO could not be found: {0}; {1}." — two arguments expected. |
NewSettingsCouldNotBeProcessed |
string |
Returns "Warning: DataPRO.exe.config was not updated because config settings from new version of DataPRO could not be processed.." |
NoLicenseFound |
string |
Returns "No license found to copy." |
OldLicenseFoundCopied |
string |
Returns "Old license found and copied." |
OldSettingsCouldNotBeFound |
string |
Returns "Warning: DataPRO.exe.config was not updated because config settings from previously-installed version of DataPRO could not be found: {0}; {1}." — two arguments expected. |
OldSettingsCouldNotBeProcessed |
string |
Returns "Warning: DataPRO.exe.config was not updated because config settings from previously-installed version of DataPRO could not be processed.." |
RegistryDataPROExe |
string |
Returns "DataPRO.exe" — likely a registry key name. |
RunTimeModules |
string |
Returns "RunTimeModules" — likely a config key name (target value for DTSPlugins). |
SectionNotFound |
string |
Returns "DTS.Common.Core.PluginLib.Config section not found." |
SettingNotFound |
string |
Returns "Configuration setting not found: {0}." — format expects one argument (e.g., setting name). |
ThisSettingNeedsModification |
string |
Returns "The {0} setting in DataPRO.exe.config was not changed to {1}.." — two arguments expected (old value, new value). |
UserSettings |
string |
Returns "userSettings" — likely the config section name for user-level settings. |
Note
: All string properties are read-only and perform a lookup via
ResourceManager.GetString(...). None accept parameters directly; formatting is done by the caller.
3. Invariants
- The class is thread-safe for read-only access to
ResourceManager(due to null-check-and-assign pattern in the getter), butCultureis not thread-safe when set concurrently. - Resource keys (e.g.,
"ApplicationSettings","DTSPlugins") are assumed to exist in the underlying.resxfile; missing keys would cause aMissingManifestResourceExceptionat runtime (not caught in this class). - The class is not meant to be instantiated; the constructor is
internaland only used by the runtime. - All string values are static after first access; no runtime mutation of the returned strings occurs.
4. Dependencies
- Depends on:
System.Resources.ResourceManagerSystem.Globalization.CultureInfoSystem.CodeDom.Compiler,System.Diagnostics,System.Runtime.CompilerServices,System.ComponentModel(for attributes)- The compiled assembly containing the
.resxresources (same assembly asStringResourcestype).
- Used by:
- The
MigrateConfigurationinstaller custom action module (inferred from namespace and file path). - Likely consumed by other classes in
MigrateConfiguration(e.g., custom action logic that logs or displays messages during config migration).
- The
- Not used by:
- Runtime application code (outside installer context), as the namespace and path suggest installer-specific usage.
5. Gotchas
- Auto-generated: Manual edits will be overwritten. Changes must be made in the source
.resxfile. - No error handling: Resource lookup failures (e.g., missing key) will throw exceptions at runtime; callers must handle or expect crashes.
- Hardcoded paths: Paths like
..\Dataand..\..\Dataare hardcoded strings — their correctness depends on the installer’s working directory and deployment layout. - Inconsistent formatting: Some messages include trailing periods (
.), others do not (e.g.,ConfigDidNotNeedToBeUpdatedvsConfigMigrationStatus). - Typo in path separator:
DTSPluginsNeedsModificationuses'..//RunTimeModules'(double slash), which may be unintentional. - Ambiguous keys: Several keys (e.g.,
DownloadFolder,ImportArchiveFolder) are likely config keys, not values — but the class provides no distinction. Callers must know the context. - No localization fallback logic: If
Cultureis set to a language without resources,ResourceManagermay fall back to invariant culture — behavior is standard but not explicit here.
None identified from source alone beyond the above — no evidence of deprecated APIs, legacy workarounds, or known bugs beyond the noted inconsistencies.