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 Argument_AddingDuplicate => GetResourceString("Argument_AddingDuplicate");
15
16 internal static string Argument_InvalidValue_TooSmall => GetResourceString("Argument_InvalidValue_TooSmall");
17
18 internal static string ArgumentOutOfRange_NeedNonNegNum_Index => GetResourceString("ArgumentOutOfRange_NeedNonNegNum_Index");
19
20 internal static string InvalidOperation_EnumFailedVersion => GetResourceString("InvalidOperation_EnumFailedVersion");
21
22 internal static string InvalidOperation_EnumOpCantHappen => GetResourceString("InvalidOperation_EnumOpCantHappen");
23
24 internal static string Arg_MultiRank => GetResourceString("Arg_MultiRank");
25
26 internal static string Arg_InsufficientSpace => GetResourceString("Arg_InsufficientSpace");
27
28 internal static string CollectionReadOnly => GetResourceString("CollectionReadOnly");
29
30 internal static string BitVectorFull => GetResourceString("BitVectorFull");
31
32 internal static string OrderedDictionary_ReadOnly => GetResourceString("OrderedDictionary_ReadOnly");
33
34 internal static string Argument_ImplementIComparable => GetResourceString("Argument_ImplementIComparable");
35
36 internal static string OrderedDictionary_SerializationMismatch => GetResourceString("OrderedDictionary_SerializationMismatch");
37
38 internal static string Serialization_InvalidOnDeser => GetResourceString("Serialization_InvalidOnDeser");
39
40 private static bool UsingResourceKeys()
41 {
43 }
44
45 internal static string GetResourceString(string resourceKey)
46 {
48 {
49 return resourceKey;
50 }
51 string result = null;
52 try
53 {
54 result = ResourceManager.GetString(resourceKey);
55 }
57 {
58 }
59 return result;
60 }
61
62 internal static string Format(string resourceFormat, object p1)
63 {
65 {
66 return string.Join(", ", resourceFormat, p1);
67 }
68 return string.Format(resourceFormat, p1);
69 }
70
71 internal static string Format(string resourceFormat, object p1, object p2)
72 {
74 {
75 return string.Join(", ", resourceFormat, p1, p2);
76 }
77 return string.Format(resourceFormat, p1, p2);
78 }
79}
static bool TryGetSwitch(string switchName, out bool isEnabled)
Definition AppContext.cs:74
virtual ? string GetString(string name)
static string Argument_InvalidValue_TooSmall
Definition SR.cs:16
static string CollectionReadOnly
Definition SR.cs:28
static ResourceManager s_resourceManager
Definition SR.cs:10
static string Argument_ImplementIComparable
Definition SR.cs:34
static string Arg_MultiRank
Definition SR.cs:24
static string Format(string resourceFormat, object p1)
Definition SR.cs:62
static string ArgumentOutOfRange_NeedNonNegNum_Index
Definition SR.cs:18
static string Format(string resourceFormat, object p1, object p2)
Definition SR.cs:71
static string Argument_AddingDuplicate
Definition SR.cs:14
static string Serialization_InvalidOnDeser
Definition SR.cs:38
static string InvalidOperation_EnumFailedVersion
Definition SR.cs:44
static ResourceManager ResourceManager
Definition SR.cs:12
static string OrderedDictionary_SerializationMismatch
Definition SR.cs:36
static string BitVectorFull
Definition SR.cs:30
static string GetResourceString(string resourceKey)
Definition SR.cs:101
static bool UsingResourceKeys()
Definition SR.cs:40
static readonly bool s_usingResourceKeys
Definition SR.cs:8
static string InvalidOperation_EnumOpCantHappen
Definition SR.cs:48
static string Arg_InsufficientSpace
Definition SR.cs:26
static string OrderedDictionary_ReadOnly
Definition SR.cs:32