Terraria v1.4.4.9
Terraria source code documentation
All Classes Namespaces Files Functions Variables Enumerations Enumerator Properties Events Macros
SR.cs
Go to the documentation of this file.
3
4namespace System;
5
6internal static class SR
7{
8 private static readonly bool s_usingResourceKeys = AppContext.TryGetSwitch("System.Resources.UseSystemResourceKeys", out var isEnabled) && isEnabled;
9
11
13
14 internal static string Arg_MustBeDriveLetterOrRootDir => GetResourceString("Arg_MustBeDriveLetterOrRootDir");
15
16 internal static string InvalidOperation_SetVolumeLabelFailed => GetResourceString("InvalidOperation_SetVolumeLabelFailed");
17
18 internal static string IO_AlreadyExists_Name => GetResourceString("IO_AlreadyExists_Name");
19
20 internal static string IO_DriveNotFound => GetResourceString("IO_DriveNotFound");
21
22 internal static string IO_DriveNotFound_Drive => GetResourceString("IO_DriveNotFound_Drive");
23
24 internal static string IO_FileExists_Name => GetResourceString("IO_FileExists_Name");
25
26 internal static string IO_FileNotFound => GetResourceString("IO_FileNotFound");
27
28 internal static string IO_FileNotFound_FileName => GetResourceString("IO_FileNotFound_FileName");
29
30 internal static string IO_PathNotFound_NoPathName => GetResourceString("IO_PathNotFound_NoPathName");
31
32 internal static string IO_PathNotFound_Path => GetResourceString("IO_PathNotFound_Path");
33
34 internal static string IO_PathTooLong => GetResourceString("IO_PathTooLong");
35
36 internal static string IO_SharingViolation_File => GetResourceString("IO_SharingViolation_File");
37
38 internal static string IO_SharingViolation_NoFileName => GetResourceString("IO_SharingViolation_NoFileName");
39
40 internal static string UnauthorizedAccess_IODenied_NoPathName => GetResourceString("UnauthorizedAccess_IODenied_NoPathName");
41
42 internal static string UnauthorizedAccess_IODenied_Path => GetResourceString("UnauthorizedAccess_IODenied_Path");
43
44 internal static string IO_PathTooLong_Path => GetResourceString("IO_PathTooLong_Path");
45
46 private static bool UsingResourceKeys()
47 {
49 }
50
51 internal static string GetResourceString(string resourceKey)
52 {
54 {
55 return resourceKey;
56 }
57 string result = null;
58 try
59 {
60 result = ResourceManager.GetString(resourceKey);
61 }
63 {
64 }
65 return result;
66 }
67
68 internal static string Format(string resourceFormat, object p1)
69 {
71 {
72 return string.Join(", ", resourceFormat, p1);
73 }
74 return string.Format(resourceFormat, p1);
75 }
76}
static bool TryGetSwitch(string switchName, out bool isEnabled)
Definition AppContext.cs:74
virtual ? string GetString(string name)
static string IO_FileExists_Name
Definition SR.cs:36
static string IO_PathTooLong
Definition SR.cs:46
static string IO_AlreadyExists_Name
Definition SR.cs:34
static ResourceManager s_resourceManager
Definition SR.cs:10
static string IO_DriveNotFound
Definition SR.cs:20
static string Format(string resourceFormat, object p1)
Definition SR.cs:68
static string Arg_MustBeDriveLetterOrRootDir
Definition SR.cs:14
static string InvalidOperation_SetVolumeLabelFailed
Definition SR.cs:16
static ResourceManager ResourceManager
Definition SR.cs:12
static string IO_SharingViolation_File
Definition SR.cs:52
static string UnauthorizedAccess_IODenied_Path
Definition SR.cs:50
static string IO_DriveNotFound_Drive
Definition SR.cs:22
static string IO_SharingViolation_NoFileName
Definition SR.cs:54
static string IO_PathNotFound_NoPathName
Definition SR.cs:42
static string IO_FileNotFound
Definition SR.cs:38
static string IO_FileNotFound_FileName
Definition SR.cs:40
static string GetResourceString(string resourceKey)
Definition SR.cs:101
static bool UsingResourceKeys()
Definition SR.cs:46
static readonly bool s_usingResourceKeys
Definition SR.cs:8
static string IO_PathTooLong_Path
Definition SR.cs:94
static string IO_PathNotFound_Path
Definition SR.cs:44
static string UnauthorizedAccess_IODenied_NoPathName
Definition SR.cs:48