Terraria
v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
◆
this[object key]
object? System.Collections.Specialized.HybridDictionary.this[object
key
]
get
set
Implements
System.Collections.IDictionary
.
Definition at line
15
of file
HybridDictionary.cs
.
16
{
17
get
18
{
19
ListDictionary listDictionary =
list
;
20
if
(
hashtable
!=
null
)
21
{
22
return
hashtable
[
key
];
23
}
24
if
(listDictionary !=
null
)
25
{
26
return
listDictionary[
key
];
27
}
28
if
(
key
==
null
)
29
{
30
throw
new
ArgumentNullException(
"key"
);
31
}
32
return
null
;
33
}
34
set
35
{
36
if
(
hashtable
!=
null
)
37
{
38
hashtable
[
key
] =
value
;
39
}
40
else
if
(
list
!=
null
)
41
{
42
if
(
list
.
Count
>= 8)
43
{
44
ChangeOver
();
45
hashtable
[
key
] =
value
;
46
}
47
else
48
{
49
list
[
key
] =
value
;
50
}
51
}
52
else
53
{
54
list
=
new
ListDictionary(
caseInsensitive
? StringComparer.OrdinalIgnoreCase : null);
55
list
[
key
] =
value
;
56
}
57
}
58
}
System.Collections.Specialized.HybridDictionary.ChangeOver
void ChangeOver()
Definition
HybridDictionary.cs:147
System.Collections.Specialized.HybridDictionary.list
ListDictionary list
Definition
HybridDictionary.cs:9
System.Collections.Specialized.HybridDictionary.caseInsensitive
readonly bool caseInsensitive
Definition
HybridDictionary.cs:13
System.Collections.Specialized.HybridDictionary.hashtable
Hashtable hashtable
Definition
HybridDictionary.cs:11
System.Collections.Specialized.ListDictionary.Count
int Count
Definition
ListDictionary.cs:304
System.ExceptionArgument.value
@ value
System.ExceptionArgument.key
@ key
System
Collections
Specialized
HybridDictionary
Generated by
1.10.0