Arci.Networking
|
Byffer to store byte stream More...
Public Member Functions | |
ByteBuffer () | |
Creates new instance of writable ByteBuffer More... | |
void | WriteGuidByteStreamInOrder (PacketGuid guid, params int[] indexes) |
Writes packet guid byte stream in specified order More... | |
void | WriteGuidBitStreamInOrder (PacketGuid guid, params int[] indexes) |
Writes packet guid bit stream in specified order More... | |
void | Write (PacketGuid guid) |
Writes packet guid into data stream More... | |
void | Write (Guid guid) |
Writes guid into data stream More... | |
void | Write (Guid guid, string format) |
Writes guid into data stream More... | |
void | Write (DateTime dateTime) |
Writes datetime data into stream More... | |
void | WriteBit (bool bit) |
Writes bit value to stream More... | |
void | FlushBits () |
Flushes bits from memory to stream More... | |
void | ClearUnflushedBits () |
Clears unflushed bits More... | |
bool | ReadBit () |
Reads 1 bit More... | |
UInt64 | ReadBits (byte bitsCount) |
Reads exact number of bits and return result as a value More... | |
void | Write (string val) |
Writes string value with ASCII encoding More... | |
void | Write (string val, Encoding encoding) |
Writes string value More... | |
void | Write (ByteBuffer buffer) |
Appends the whole storage of bytebuffer to this one More... | |
byte [] | ReadBytes () |
Reads multiple bytes based on length written in stream More... | |
byte [] | ReadBytes (int length) |
Reads multiple bytes More... | |
string | ReadString () |
Reads string with ASCII encoding More... | |
string | ReadString (Encoding encoding) |
Reads string More... | |
void | ReadGuidByteStreamInOrder (PacketGuid guid, params int[] indexes) |
Reads guid byte stream in specified order More... | |
void | ReadGuidBitStreamInOrder (PacketGuid guid, params int[] indexes) |
Reads guid bit stream in specified order More... | |
PacketGuid | ReadPacketGuid () |
Reads packet guid from data stream More... | |
Guid | ReadGuid () |
Reads guid from data stream More... | |
Guid | ReadGuid (string format) |
Reads guid from data stream More... | |
DateTime | ReadDateTime () |
Reads datetime from data stream More... | |
void | Write (byte[] val) |
Writes byte[] value to stream More... | |
void | Dispose () |
Disposes object More... | |
SByte | ReadSByte () |
Reads SByte value from stream More... | |
void | Write (SByte val) |
Writes SByte value to stream More... | |
Int16 | ReadInt16 () |
Reads Int16 value from stream More... | |
void | Write (Int16 val) |
Writes Int16 value to stream More... | |
Int32 | ReadInt32 () |
Reads Int32 value from stream More... | |
void | Write (Int32 val) |
Writes Int32 value to stream More... | |
Int64 | ReadInt64 () |
Reads Int64 value from stream More... | |
void | Write (Int64 val) |
Writes Int64 value to stream More... | |
Byte | ReadByte () |
Reads Byte value from stream More... | |
void | Write (Byte val) |
Writes Byte value to stream More... | |
UInt16 | ReadUInt16 () |
Reads UInt16 value from stream More... | |
void | Write (UInt16 val) |
Writes UInt16 value to stream More... | |
UInt32 | ReadUInt32 () |
Reads UInt32 value from stream More... | |
void | Write (UInt32 val) |
Writes UInt32 value to stream More... | |
UInt64 | ReadUInt64 () |
Reads UInt64 value from stream More... | |
void | Write (UInt64 val) |
Writes UInt64 value to stream More... | |
Single | ReadSingle () |
Reads Single value from stream More... | |
void | Write (Single val) |
Writes Single value to stream More... | |
Double | ReadDouble () |
Reads Double value from stream More... | |
void | Write (Double val) |
Writes Double value to stream More... | |
Decimal | ReadDecimal () |
Reads Decimal value from stream More... | |
void | Write (Decimal val) |
Writes Decimal value to stream More... | |
void | WriteBit (SByte bit) |
Writes 1 if SByte value is different from 0, otherwise writes 0 More... | |
void | WriteBits (SByte value, byte bitsCount) |
Writes value with specified number of bits More... | |
void | WriteBit (Int16 bit) |
Writes 1 if Int16 value is different from 0, otherwise writes 0 More... | |
void | WriteBits (Int16 value, byte bitsCount) |
Writes value with specified number of bits More... | |
void | WriteBit (Int32 bit) |
Writes 1 if Int32 value is different from 0, otherwise writes 0 More... | |
void | WriteBits (Int32 value, byte bitsCount) |
Writes value with specified number of bits More... | |
void | WriteBit (Int64 bit) |
Writes 1 if Int64 value is different from 0, otherwise writes 0 More... | |
void | WriteBits (Int64 value, byte bitsCount) |
Writes value with specified number of bits More... | |
void | WriteBit (Byte bit) |
Writes 1 if Byte value is different from 0, otherwise writes 0 More... | |
void | WriteBits (Byte value, byte bitsCount) |
Writes value with specified number of bits More... | |
void | WriteBit (UInt16 bit) |
Writes 1 if UInt16 value is different from 0, otherwise writes 0 More... | |
void | WriteBits (UInt16 value, byte bitsCount) |
Writes value with specified number of bits More... | |
void | WriteBit (UInt32 bit) |
Writes 1 if UInt32 value is different from 0, otherwise writes 0 More... | |
void | WriteBits (UInt32 value, byte bitsCount) |
Writes value with specified number of bits More... | |
void | WriteBit (UInt64 bit) |
Writes 1 if UInt64 value is different from 0, otherwise writes 0 More... | |
void | WriteBits (UInt64 value, byte bitsCount) |
Writes value with specified number of bits More... | |
Public Attributes | |
byte [] | Data => memoryStream.ToArray() |
Data in packet More... | |
Protected Member Functions | |
ByteBuffer (byte[] data) | |
Creates new instance of readable ByteBuffer More... | |
void | Initialize () |
Inicializes data in ByteBuffer More... | |
Byffer to store byte stream
|
inlineprotected |
Creates new instance of readable ByteBuffer
data | Data to form ByteBuffer from |
|
inline |
Creates new instance of writable ByteBuffer
|
inline |
Clears unflushed bits
|
inline |
Disposes object
|
inline |
Flushes bits from memory to stream
|
inlineprotected |
Inicializes data in ByteBuffer
|
inline |
Reads 1 bit
|
inline |
Reads exact number of bits and return result as a value
bitsCount | Bits to be read |
|
inline |
Reads Byte value from stream
|
inline |
Reads multiple bytes based on length written in stream
|
inline |
Reads multiple bytes
length | Bytes to be read |
|
inline |
Reads datetime from data stream
|
inline |
Reads Decimal value from stream
|
inline |
Reads Double value from stream
Guid Arci.Networking.Data.ByteBuffer.ReadGuid | ( | ) |
Reads guid from data stream
|
inline |
Reads guid from data stream
format | Guid format |
|
inline |
Reads guid bit stream in specified order
guid | Guid to store value from stream |
indexes | Order |
|
inline |
Reads guid byte stream in specified order
guid | Guid to store value from stream |
indexes | Order |
|
inline |
Reads Int16 value from stream
|
inline |
Reads Int32 value from stream
|
inline |
Reads Int64 value from stream
|
inline |
Reads packet guid from data stream
|
inline |
Reads SByte value from stream
|
inline |
Reads Single value from stream
string Arci.Networking.Data.ByteBuffer.ReadString | ( | ) |
Reads string with ASCII encoding
|
inline |
Reads string
encoding | Encoding type of string. If null provided then ASCII will be used |
|
inline |
Reads UInt16 value from stream
|
inline |
Reads UInt32 value from stream
|
inline |
Reads UInt64 value from stream
|
inline |
Writes SByte value to stream
val | Value to be written |
|
inline |
Writes Int16 value to stream
val | Value to be written |
|
inline |
Writes Int32 value to stream
val | Value to be written |
|
inline |
Writes packet guid into data stream
guid | Guid to be written |
|
inline |
Writes Int64 value to stream
val | Value to be written |
void Arci.Networking.Data.ByteBuffer.Write | ( | Guid | guid | ) |
Writes guid into data stream
guid | Guid to be written |
|
inline |
Writes guid into data stream
guid | Guid to be written |
format | Guid format |
|
inline |
Writes Byte value to stream
val | Value to be written |
|
inline |
Writes datetime data into stream
dateTime | DateTime to be written |
|
inline |
Writes UInt16 value to stream
val | Value to be written |
|
inline |
Writes UInt32 value to stream
val | Value to be written |
|
inline |
Writes UInt64 value to stream
val | Value to be written |
|
inline |
Writes Single value to stream
val | Value to be written |
void Arci.Networking.Data.ByteBuffer.Write | ( | string | val | ) |
Writes string value with ASCII encoding
val | Value to be written |
|
inline |
Writes Double value to stream
val | Value to be written |
|
inline |
Writes string value
val | Value to be written |
encoding | Encoding type of string. If null provided then ASCII will be used |
|
inline |
Appends the whole storage of bytebuffer to this one
buffer | Buffer to be written |
|
inline |
Writes Decimal value to stream
val | Value to be written |
|
inline |
Writes byte[] value to stream
val | Value to be written |
|
inline |
Writes bit value to stream
bit | Value to be written |
|
inline |
Writes 1 if SByte value is different from 0, otherwise writes 0
bit | Value to be written |
|
inline |
Writes 1 if Int16 value is different from 0, otherwise writes 0
bit | Value to be written |
|
inline |
Writes 1 if Int32 value is different from 0, otherwise writes 0
bit | Value to be written |
|
inline |
Writes 1 if Int64 value is different from 0, otherwise writes 0
bit | Value to be written |
|
inline |
Writes 1 if Byte value is different from 0, otherwise writes 0
bit | Value to be written |
|
inline |
Writes 1 if UInt16 value is different from 0, otherwise writes 0
bit | Value to be written |
|
inline |
Writes 1 if UInt32 value is different from 0, otherwise writes 0
bit | Value to be written |
|
inline |
Writes 1 if UInt64 value is different from 0, otherwise writes 0
bit | Value to be written |
|
inline |
Writes value with specified number of bits
value | Value to be written |
bitsCount | Number of bits that value should written with |
|
inline |
Writes value with specified number of bits
value | Value to be written |
bitsCount | Number of bits that value should written with |
|
inline |
Writes value with specified number of bits
value | Value to be written |
bitsCount | Number of bits that value should written with |
|
inline |
Writes value with specified number of bits
value | Value to be written |
bitsCount | Number of bits that value should written with |
|
inline |
Writes value with specified number of bits
value | Value to be written |
bitsCount | Number of bits that value should written with |
|
inline |
Writes value with specified number of bits
value | Value to be written |
bitsCount | Number of bits that value should written with |
|
inline |
Writes value with specified number of bits
value | Value to be written |
bitsCount | Number of bits that value should written with |
|
inline |
Writes value with specified number of bits
value | Value to be written |
bitsCount | Number of bits that value should written with |
|
inline |
Writes packet guid bit stream in specified order
guid | Guid to be written |
indexes | Order |
|
inline |
Writes packet guid byte stream in specified order
guid | Guid to be written |
indexes | Order |
byte [] Arci.Networking.Data.ByteBuffer.Data => memoryStream.ToArray() |
Data in packet