MsgPackWriter
public class MsgPackWriter : IMsgPackWriter, IDisposable
Rudimentary Msgpack implementation that will be used for sending RPC to the server.
Constructors#
Static Methods#
Name | Description |
---|
Create | Create writer with a prefilled stream buffer |
WriteByte | Append value with MsgPackToken token to bytes |
WriteSByte | Append value with MsgPackToken token to bytes |
WriteShort | Append value with MsgPackToken token to bytes |
WriteUShort | Append value with MsgPackToken token to bytes |
WriteInt | Append value with MsgPackToken token to bytes |
WriteUInt | Append value with MsgPackToken token to bytes |
WriteLong | Append value with MsgPackToken token to bytes |
WriteULong | Append value with MsgPackToken token to bytes |
WriteFloat | Append value with MsgPackToken token to bytes |
WriteDouble | Append value with MsgPackToken token to bytes |
WriteBool | Append fixedbool with either MsgPackToken to bytes |
WriteString | Append string value with size based token to bytes |
WriteBinary | Append values with size based token to bytes |
Properties#
Name | Description |
---|
Encoding | Used Encoding defaults to UTF8 |
Public Methods#
Name | Description |
---|
Clear | Clear stream buffer |
Write | Set MsgPackToken based on the unsigend value size |
WriteByte | Write value with token MsgPackToken |
WriteSByte | Write value with token MsgPackToken |
WriteShort | Write value with token MsgPackToken |
WriteUShort | Write value with token MsgPackToken |
WriteInt | Write value with token MsgPackToken |
WriteUInt | Write value with token MsgPackToken |
WriteLong | Write value with token MsgPackToken |
WriteULong | Write value with token MsgPackToken |
WriteFloat | Write value with token MsgPackToken |
WriteDouble | Write value with token MsgPackToken |
WriteBool | Write fixedbool of either MsgPackToken |
WriteString | Write string with writer encoding (default UTF8) |
WriteBinary | MessagePack header is big-endian, value binarywriter default little-endian |
WriteArrayHeader | MessagePack header is big-endian, value binarywriter default little-endian |
WriteMapHeader | MessagePack header is big-endian value binarywriter default little-endian |
GetBytes | Get raw bytes from the stream buffer |
GetLength | Get raw bytes from the stream buffer |
GetBuffer | Get raw bytes from the underlying stream buffer |
Append | Append bytes to the stream at the currrent stream position |
ToString | String representation of the stream based on encoding (default UTF8) |
ToHex | String representation of the stream in hex |
Dispose | dispose |