Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
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 ActivityIdFormatInvalid => GetResourceString("ActivityIdFormatInvalid");
15
16 internal static string ActivityNotRunning => GetResourceString("ActivityNotRunning");
17
18 internal static string ActivityNotStarted => GetResourceString("ActivityNotStarted");
19
20 internal static string ActivityStartAlreadyStarted => GetResourceString("ActivityStartAlreadyStarted");
21
22 internal static string EndTimeNotUtc => GetResourceString("EndTimeNotUtc");
23
24 internal static string OperationNameInvalid => GetResourceString("OperationNameInvalid");
25
26 internal static string ParentIdAlreadySet => GetResourceString("ParentIdAlreadySet");
27
28 internal static string ParentIdInvalid => GetResourceString("ParentIdInvalid");
29
30 internal static string SetFormatOnStartedActivity => GetResourceString("SetFormatOnStartedActivity");
31
32 internal static string SetParentIdOnActivityWithParent => GetResourceString("SetParentIdOnActivityWithParent");
33
34 internal static string StartTimeNotUtc => GetResourceString("StartTimeNotUtc");
35
36 internal static string KeyAlreadyExist => GetResourceString("KeyAlreadyExist");
37
38 internal static string InvalidTraceParent => GetResourceString("InvalidTraceParent");
39
40 internal static string UnsupportedType => GetResourceString("UnsupportedType");
41
42 internal static string Arg_BufferTooSmall => GetResourceString("Arg_BufferTooSmall");
43
44 private static bool UsingResourceKeys()
45 {
47 }
48
49 internal static string GetResourceString(string resourceKey)
50 {
52 {
53 return resourceKey;
54 }
55 string result = null;
56 try
57 {
58 result = ResourceManager.GetString(resourceKey);
59 }
61 {
62 }
63 return result;
64 }
65
66 internal static string Format(string resourceFormat, object p1)
67 {
69 {
70 return string.Join(", ", resourceFormat, p1);
71 }
72 return string.Format(resourceFormat, p1);
73 }
74}
static bool TryGetSwitch(string switchName, out bool isEnabled)
Definition AppContext.cs:74
virtual ? string GetString(string name)
static string ActivityNotStarted
Definition SR.cs:18
static string Arg_BufferTooSmall
Definition SR.cs:42
static string SetFormatOnStartedActivity
Definition SR.cs:30
static string ActivityStartAlreadyStarted
Definition SR.cs:20
static ResourceManager s_resourceManager
Definition SR.cs:10
static string Format(string resourceFormat, object p1)
Definition SR.cs:66
static string ActivityIdFormatInvalid
Definition SR.cs:14
static string ParentIdInvalid
Definition SR.cs:28
static string EndTimeNotUtc
Definition SR.cs:22
static string UnsupportedType
Definition SR.cs:40
static ResourceManager ResourceManager
Definition SR.cs:12
static string ActivityNotRunning
Definition SR.cs:16
static string KeyAlreadyExist
Definition SR.cs:36
static string SetParentIdOnActivityWithParent
Definition SR.cs:32
static string GetResourceString(string resourceKey)
Definition SR.cs:101
static bool UsingResourceKeys()
Definition SR.cs:44
static string ParentIdAlreadySet
Definition SR.cs:26
static string StartTimeNotUtc
Definition SR.cs:34
static readonly bool s_usingResourceKeys
Definition SR.cs:8
static string OperationNameInvalid
Definition SR.cs:24
static string InvalidTraceParent
Definition SR.cs:38