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

◆ WriteTo()

override void System.Text.Json.Nodes.JsonObject.WriteTo ( Utf8JsonWriter writer,
JsonSerializerOptions? options = null )
inline

Definition at line 148 of file JsonObject.cs.

149 {
150 if (writer == null)
151 {
152 throw new ArgumentNullException("writer");
153 }
154 if (_jsonElement.HasValue)
155 {
157 return;
158 }
159 if (options == null)
160 {
161 options = JsonSerializerOptions.s_defaultOptions;
162 }
163 writer.WriteStartObject();
165 {
166 while (enumerator.MoveNext())
167 {
169 writer.WritePropertyName(current.Key);
170 JsonNodeConverter.Instance.Write(writer, current.Value, options);
171 }
172 }
173 writer.WriteEndObject();
174 }
IEnumerator< KeyValuePair< string, JsonNode?> > GetEnumerator()
void WriteTo(Utf8JsonWriter writer)

References System.Text.Json.Nodes.JsonObject._jsonElement, System.Text.Json.Nodes.JsonObject.GetEnumerator(), System.Text.Json.Serialization.Converters.JsonNodeConverter.Instance, System.options, System.Text.Json.JsonSerializerOptions.s_defaultOptions, System.writer, and System.Text.Json.JsonElement.WriteTo().