Terraria
v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
SR.cs
Go to the documentation of this file.
1
using
System.Resources
;
2
using
FxResources.System.Threading.Tasks.Parallel
;
3
4
namespace
System
;
5
6
internal
static
class
SR
7
{
8
private
static
readonly
bool
s_usingResourceKeys
=
AppContext
.
TryGetSwitch
(
"System.Resources.UseSystemResourceKeys"
, out var isEnabled) && isEnabled;
9
10
private
static
ResourceManager
s_resourceManager
;
11
12
internal
static
ResourceManager
ResourceManager
=>
s_resourceManager
?? (
s_resourceManager
=
new
ResourceManager
(typeof(
SR
)));
13
14
internal
static
string
Parallel_Invoke_ActionNull
=>
GetResourceString
(
"Parallel_Invoke_ActionNull"
);
15
16
internal
static
string
Parallel_ForEach_OrderedPartitionerKeysNotNormalized
=>
GetResourceString
(
"Parallel_ForEach_OrderedPartitionerKeysNotNormalized"
);
17
18
internal
static
string
Parallel_ForEach_PartitionerNotDynamic
=>
GetResourceString
(
"Parallel_ForEach_PartitionerNotDynamic"
);
19
20
internal
static
string
Parallel_ForEach_PartitionerReturnedNull
=>
GetResourceString
(
"Parallel_ForEach_PartitionerReturnedNull"
);
21
22
internal
static
string
Parallel_ForEach_NullEnumerator
=>
GetResourceString
(
"Parallel_ForEach_NullEnumerator"
);
23
24
internal
static
string
ParallelState_Break_InvalidOperationException_BreakAfterStop
=>
GetResourceString
(
"ParallelState_Break_InvalidOperationException_BreakAfterStop"
);
25
26
internal
static
string
ParallelState_Stop_InvalidOperationException_StopAfterBreak
=>
GetResourceString
(
"ParallelState_Stop_InvalidOperationException_StopAfterBreak"
);
27
28
internal
static
string
ParallelState_NotSupportedException_UnsupportedMethod
=>
GetResourceString
(
"ParallelState_NotSupportedException_UnsupportedMethod"
);
29
30
private
static
bool
UsingResourceKeys
()
31
{
32
return
s_usingResourceKeys
;
33
}
34
35
internal
static
string
GetResourceString
(
string
resourceKey)
36
{
37
if
(
UsingResourceKeys
())
38
{
39
return
resourceKey;
40
}
41
string
result =
null
;
42
try
43
{
44
result =
ResourceManager
.
GetString
(resourceKey);
45
}
46
catch
(
MissingManifestResourceException
)
47
{
48
}
49
return
result;
50
}
51
}
FxResources.System.Threading.Tasks.Parallel.SR
Definition
SR.cs:4
System.AppContext.TryGetSwitch
static bool TryGetSwitch(string switchName, out bool isEnabled)
Definition
AppContext.cs:74
System.AppContext
Definition
AppContext.cs:14
System.Resources.MissingManifestResourceException
Definition
MissingManifestResourceException.cs:9
System.Resources.ResourceManager.GetString
virtual ? string GetString(string name)
Definition
ResourceManager.cs:459
System.Resources.ResourceManager
Definition
ResourceManager.cs:10
System.SR.Parallel_Invoke_ActionNull
static string Parallel_Invoke_ActionNull
Definition
SR.cs:14
System.SR.Parallel_ForEach_NullEnumerator
static string Parallel_ForEach_NullEnumerator
Definition
SR.cs:22
System.SR.Parallel_ForEach_PartitionerNotDynamic
static string Parallel_ForEach_PartitionerNotDynamic
Definition
SR.cs:18
System.SR.s_resourceManager
static ResourceManager s_resourceManager
Definition
SR.cs:10
System.SR.ResourceManager
static ResourceManager ResourceManager
Definition
SR.cs:12
System.SR.ParallelState_Break_InvalidOperationException_BreakAfterStop
static string ParallelState_Break_InvalidOperationException_BreakAfterStop
Definition
SR.cs:24
System.SR.ParallelState_Stop_InvalidOperationException_StopAfterBreak
static string ParallelState_Stop_InvalidOperationException_StopAfterBreak
Definition
SR.cs:26
System.SR.GetResourceString
static string GetResourceString(string resourceKey)
Definition
SR.cs:101
System.SR.UsingResourceKeys
static bool UsingResourceKeys()
Definition
SR.cs:30
System.SR.Parallel_ForEach_OrderedPartitionerKeysNotNormalized
static string Parallel_ForEach_OrderedPartitionerKeysNotNormalized
Definition
SR.cs:16
System.SR.ParallelState_NotSupportedException_UnsupportedMethod
static string ParallelState_NotSupportedException_UnsupportedMethod
Definition
SR.cs:28
System.SR.s_usingResourceKeys
static readonly bool s_usingResourceKeys
Definition
SR.cs:8
System.SR.Parallel_ForEach_PartitionerReturnedNull
static string Parallel_ForEach_PartitionerReturnedNull
Definition
SR.cs:20
FxResources.System.Threading.Tasks.Parallel
Definition
SR.cs:1
System.Resources
Definition
FastResourceComparer.cs:5
System
Definition
BlockingCollection.cs:8
source
System.Threading.Tasks.Parallel
System
SR.cs
Generated by
1.10.0