Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ CreateNodes()

void System.Text.Json.Nodes.JsonArray.CreateNodes ( )
inlineprivate

Definition at line 196 of file JsonArray.cs.

197 {
198 if (_list != null)
199 {
200 return;
201 }
203 if (!_jsonElement.HasValue)
204 {
205 list = new List<JsonNode>();
206 }
207 else
208 {
210 list = new List<JsonNode>(value.GetArrayLength());
211 foreach (JsonElement item in value.EnumerateArray())
212 {
214 jsonNode?.AssignParent(this);
216 }
217 _jsonElement = null;
218 }
219 _list = list;
220 }
void Add(TKey key, TValue value)
JsonNode(JsonNodeOptions? options=null)
Definition JsonNode.cs:78
static JsonNode Create(JsonElement element, JsonNodeOptions? options)

References System.Text.Json.Nodes.JsonArray._jsonElement, System.Text.Json.Nodes.JsonArray._list, System.Collections.Generic.Dictionary< TKey, TValue >.Add(), System.Text.Json.Serialization.Converters.JsonNodeConverter.Create(), System.Text.Json.Dictionary, System.Text.Json.JsonElement.EnumerateArray(), System.item, System.list, and System.value.

Referenced by System.Text.Json.Nodes.JsonArray.WriteTo().