Class BitWriter
This class provides functionally to write bit-wide values, tracking bitOffset (in opposite to byte-wide values for regular MemoryStream).
Inheritance
System.Object
BitWriter
Assembly: Eco.Shared.dll
Syntax
public static class BitWriter : Object
Methods
Write(MemoryStream, Boolean, ref Int32)
Declaration
public static void Write(MemoryStream stream, bool value, ref int bitOffset)
Parameters
Type |
Name |
Description |
System.IO.MemoryStream |
stream |
|
System.Boolean |
value |
|
System.Int32 |
bitOffset |
|
Write(MemoryStream, Byte, ref Int32)
Declaration
public static void Write(MemoryStream stream, byte value, ref int bitOffset)
Parameters
Type |
Name |
Description |
System.IO.MemoryStream |
stream |
|
System.Byte |
value |
|
System.Int32 |
bitOffset |
|
Write(MemoryStream, Byte[], Int32, Int32, ref Int32)
Declaration
public static void Write(MemoryStream stream, byte[] value, int offset, int length, ref int bitOffset)
Parameters
Type |
Name |
Description |
System.IO.MemoryStream |
stream |
|
System.Byte[] |
value |
|
System.Int32 |
offset |
|
System.Int32 |
length |
|
System.Int32 |
bitOffset |
|
Write(MemoryStream, IPEndPoint, ref Int32)
Declaration
public static void Write(MemoryStream stream, IPEndPoint value, ref int bitOffset)
Parameters
Type |
Name |
Description |
System.IO.MemoryStream |
stream |
|
System.Net.IPEndPoint |
value |
|
System.Int32 |
bitOffset |
|
Write(MemoryStream, UInt16, ref Int32)
Declaration
public static void Write(MemoryStream stream, ushort value, ref int bitOffset)
Parameters
Type |
Name |
Description |
System.IO.MemoryStream |
stream |
|
System.UInt16 |
value |
|
System.Int32 |
bitOffset |
|