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

◆ Dispose()

void System.Text.Json.JsonDocument.Dispose ( )
inline

Implements System.IDisposable.

Definition at line 320 of file JsonDocument.cs.

321 {
322 int length = _utf8Json.Length;
323 if (length == 0 || !IsDisposable)
324 {
325 return;
326 }
328 _utf8Json = ReadOnlyMemory<byte>.Empty;
330 {
332 if (array != null)
333 {
334 array.AsSpan(0, length).Clear();
336 }
337 }
339 {
341 }
342 }
static ArrayPool< T > Shared
Definition ArrayPool.cs:7
ReadOnlyMemory< byte > _utf8Json
PooledByteBufferWriter _extraPooledByteBufferWriter
static int Exchange(ref int location1, int value)
static ReadOnlyMemory< T > Empty

References System.Text.Json.JsonDocument._extraPooledByteBufferWriter, System.Text.Json.JsonDocument._extraRentedArrayPoolBytes, System.Text.Json.JsonDocument._hasExtraPooledByteBufferWriter, System.Text.Json.JsonDocument._hasExtraRentedArrayPoolBytes, System.Text.Json.JsonDocument._parsedData, System.Text.Json.JsonDocument._utf8Json, System.array, System.Text.Json.Dictionary, System.Text.Json.JsonDocument.MetadataDb.Dispose(), System.ReadOnlyMemory< T >.Empty, System.Threading.Interlocked.Exchange(), System.Text.Json.JsonDocument.IsDisposable, System.length, System.ReadOnlyMemory< T >.Length, and System.Buffers.ArrayPool< T >.Shared.