Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
TrackingValidationObjectDictionary.cs
Go to the documentation of this file.
3
4namespace System.Net;
5
7{
9
11
13
14 internal bool IsChanged { get; set; }
15
16 public override string this[string key]
17 {
18 get
19 {
20 return base[key];
21 }
22 set
23 {
25 }
26 }
27
33
34 private void PersistValue(string key, string value, bool addValue)
35 {
36 key = key.ToLowerInvariant();
37 if (string.IsNullOrEmpty(value))
38 {
39 return;
40 }
42 {
43 object obj = value2(value);
44 if (_internalObjects == null)
45 {
47 }
48 if (addValue)
49 {
51 base.Add(key, obj.ToString());
52 }
53 else
54 {
56 base[key] = obj.ToString();
57 }
58 }
59 else if (addValue)
60 {
61 base.Add(key, value);
62 }
63 else
64 {
65 base[key] = value;
66 }
67 IsChanged = true;
68 }
69
70 internal object InternalGet(string key)
71 {
73 {
74 return value;
75 }
76 return base[key];
77 }
78
79 internal void InternalSet(string key, object value)
80 {
81 if (_internalObjects == null)
82 {
84 }
86 base[key] = value.ToString();
87 IsChanged = true;
88 }
89
90 public override void Add(string key, string value)
91 {
93 }
94
95 public override void Clear()
96 {
97 if (_internalObjects != null)
98 {
100 }
101 base.Clear();
102 IsChanged = true;
103 }
104
105 public override void Remove(string key)
106 {
107 if (_internalObjects != null)
108 {
110 }
111 base.Remove(key);
112 IsChanged = true;
113 }
114}
bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
bool ICollection< KeyValuePair< TKey, TValue > >. Remove(KeyValuePair< TKey, TValue > keyValuePair)
void Add(TKey key, TValue value)
void PersistValue(string key, string value, bool addValue)
TrackingValidationObjectDictionary(Dictionary< string, ValidateAndParseValue > validators)
delegate object ValidateAndParseValue(object valueToValidate)
readonly Dictionary< string, ValidateAndParseValue > _validators