Struct PackedBinaryStream
Output stream for deserialization. This stream is used to retain relevant data parsed during deserialization.
Inherited Members
Namespace: Unity.Serialization.Json
Syntax
public struct PackedBinaryStream : IDisposable, IEquatable<PackedBinaryStream>
Remarks
The contents of the stream are not actualized and instead remain as a string of characters.
Constructors
PackedBinaryStream(Int32, Int32, Allocator)
Constructs a new instance of PackedBinaryStream using the given capacities.
Declaration
public PackedBinaryStream(int initialTokensCapacity, int initialBufferCapacity, Allocator label)
Parameters
Type | Name | Description |
---|---|---|
Int32 | initialTokensCapacity | Initial number of tokens to allocate. |
Int32 | initialBufferCapacity | Initial buffer size to allocate. |
Allocator | label | Allocator to use for internal buffers. |
PackedBinaryStream(Allocator)
Constructs a new instance of PackedBinaryStream using default capacities.
Declaration
public PackedBinaryStream(Allocator label)
Parameters
Type | Name | Description |
---|---|---|
Allocator | label | The memory allocator label to use. |
Methods
Clear()
Clears all token and buffer data.
Declaration
public void Clear()
Dispose()
Releases all resources used by the PackedBinaryStream.
Declaration
public void Dispose()
Implements
Equals(Object)
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
Object | obj |
Returns
Type | Description |
---|---|
Boolean |
Overrides
Equals(PackedBinaryStream)
Declaration
public bool Equals(PackedBinaryStream other)
Parameters
Type | Name | Description |
---|---|---|
PackedBinaryStream | other |
Returns
Type | Description |
---|---|
Boolean |
Implements
GetHashCode()
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
Int32 |