<PackageReference Include="Microsoft.Win32.Registry" Version="5.0.0-preview.8.20407.11" />

SR

static class SR
using FxResources.Microsoft.Win32.Registry; using System.Resources; namespace System { internal static class SR { private static readonly bool s_usingResourceKeys = AppContext.TryGetSwitch("System.Resources.UseSystemResourceKeys", out bool isEnabled) && isEnabled; private static ResourceManager s_resourceManager; internal static ResourceManager ResourceManager => s_resourceManager ?? (s_resourceManager = new ResourceManager(typeof(FxResources.Microsoft.Win32.Registry.SR))); internal static string AccessControl_InvalidHandle => GetResourceString("AccessControl_InvalidHandle", null); internal static string Arg_RegSubKeyAbsent => GetResourceString("Arg_RegSubKeyAbsent", null); internal static string Arg_RegKeyDelHive => GetResourceString("Arg_RegKeyDelHive", null); internal static string Arg_RegKeyNoRemoteConnect => GetResourceString("Arg_RegKeyNoRemoteConnect", null); internal static string Arg_RegKeyOutOfRange => GetResourceString("Arg_RegKeyOutOfRange", null); internal static string Arg_RegKeyNotFound => GetResourceString("Arg_RegKeyNotFound", null); internal static string Arg_RegKeyStrLenBug => GetResourceString("Arg_RegKeyStrLenBug", null); internal static string Arg_RegValStrLenBug => GetResourceString("Arg_RegValStrLenBug", null); internal static string Arg_RegBadKeyKind => GetResourceString("Arg_RegBadKeyKind", null); internal static string Arg_RegGetOverflowBug => GetResourceString("Arg_RegGetOverflowBug", null); internal static string Arg_RegSetMismatchedKind => GetResourceString("Arg_RegSetMismatchedKind", null); internal static string Arg_RegSetBadArrType => GetResourceString("Arg_RegSetBadArrType", null); internal static string Arg_RegSetStrArrNull => GetResourceString("Arg_RegSetStrArrNull", null); internal static string Arg_RegInvalidKeyName => GetResourceString("Arg_RegInvalidKeyName", null); internal static string Arg_DllInitFailure => GetResourceString("Arg_DllInitFailure", null); internal static string Arg_EnumIllegalVal => GetResourceString("Arg_EnumIllegalVal", null); internal static string Arg_RegSubKeyValueAbsent => GetResourceString("Arg_RegSubKeyValueAbsent", null); internal static string Argument_InvalidRegistryOptionsCheck => GetResourceString("Argument_InvalidRegistryOptionsCheck", null); internal static string Argument_InvalidRegistryViewCheck => GetResourceString("Argument_InvalidRegistryViewCheck", null); internal static string Argument_InvalidRegistryKeyPermissionCheck => GetResourceString("Argument_InvalidRegistryKeyPermissionCheck", null); internal static string InvalidOperation_RegRemoveSubKey => GetResourceString("InvalidOperation_RegRemoveSubKey", null); internal static string ObjectDisposed_RegKeyClosed => GetResourceString("ObjectDisposed_RegKeyClosed", null); internal static string PlatformNotSupported_Registry => GetResourceString("PlatformNotSupported_Registry", null); internal static string Security_RegistryPermission => GetResourceString("Security_RegistryPermission", null); internal static string UnauthorizedAccess_RegistryKeyGeneric_Key => GetResourceString("UnauthorizedAccess_RegistryKeyGeneric_Key", null); internal static string UnauthorizedAccess_RegistryNoWrite => GetResourceString("UnauthorizedAccess_RegistryNoWrite", null); private static bool UsingResourceKeys() { return s_usingResourceKeys; } internal static string GetResourceString(string resourceKey, string defaultString = null) { if (UsingResourceKeys()) return defaultString ?? resourceKey; string text = null; try { text = ResourceManager.GetString(resourceKey); } catch (MissingManifestResourceException) { } if (defaultString != null && resourceKey.Equals(text)) return defaultString; return text; } internal static string Format(string resourceFormat, object p1) { if (UsingResourceKeys()) return string.Join(", ", resourceFormat, p1); return string.Format(resourceFormat, p1); } internal static string Format(string resourceFormat, object p1, object p2) { if (UsingResourceKeys()) return string.Join(", ", resourceFormat, p1, p2); return string.Format(resourceFormat, p1, p2); } internal static string Format(string resourceFormat, object p1, object p2, object p3) { if (UsingResourceKeys()) return string.Join(", ", resourceFormat, p1, p2, p3); return string.Format(resourceFormat, p1, p2, p3); } internal static string Format(string resourceFormat, params object[] args) { if (args != null) { if (UsingResourceKeys()) return resourceFormat + ", " + string.Join(", ", args); return string.Format(resourceFormat, args); } return resourceFormat; } internal static string Format(IFormatProvider provider, string resourceFormat, object p1) { if (UsingResourceKeys()) return string.Join(", ", resourceFormat, p1); return string.Format(provider, resourceFormat, p1); } internal static string Format(IFormatProvider provider, string resourceFormat, object p1, object p2) { if (UsingResourceKeys()) return string.Join(", ", resourceFormat, p1, p2); return string.Format(provider, resourceFormat, p1, p2); } internal static string Format(IFormatProvider provider, string resourceFormat, object p1, object p2, object p3) { if (UsingResourceKeys()) return string.Join(", ", resourceFormat, p1, p2, p3); return string.Format(provider, resourceFormat, p1, p2, p3); } internal static string Format(IFormatProvider provider, string resourceFormat, params object[] args) { if (args != null) { if (UsingResourceKeys()) return resourceFormat + ", " + string.Join(", ", args); return string.Format(provider, resourceFormat, args); } return resourceFormat; } } }