Created
October 28, 2017 18:31
-
-
Save HurricanKai/fea58a5d6af9a0cb952dfa26fbc4f3b4 to your computer and use it in GitHub Desktop.
The IMinecraftStream Interface
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
namespace Lib | |
{ | |
public interface IMinecraftStream | |
{ | |
Stream BaseStream { get; } | |
byte ReadUInt8(); | |
sbyte ReadInt8(); | |
void WriteUInt8(byte value); | |
void WriteInt8(sbyte value); | |
ushort ReadUInt16(); | |
short ReadInt16(); | |
void WriteUInt16(ushort value); | |
void WriteInt16(short value); | |
uint ReadUInt32(); | |
int ReadInt32(); | |
void WriteUInt32(uint value); | |
void WriteInt32(int value); | |
ulong ReadUInt64(); | |
long ReadInt64(); | |
void WriteUInt64(ulong value); | |
void WriteInt64(long value); | |
float ReadSingle(); | |
void WriteSingle(float value); | |
double ReadDouble(); | |
void WriteDouble(double value); | |
string ReadString(); | |
void WriteString(string value); | |
string ReadString8(); | |
void WriteString8(string value); | |
bool ReadBoolean(); | |
void WriteBoolean(bool value); | |
byte[] ReadUInt8Array(int length); | |
void WriteUInt8Array(byte[] value); | |
sbyte[] ReadInt8Array(int length); | |
void WriteInt8Array(sbyte[] value); | |
ushort[] ReadUInt16Array(int length); | |
void WriteUInt16Array(ushort[] value); | |
short[] ReadInt16Array(int length); | |
void WriteInt16Array(short[] value); | |
uint[] ReadUInt32Array(int length); | |
void WriteUInt32Array(uint[] value); | |
int[] ReadInt32Array(int length); | |
void WriteInt32Array(int[] value); | |
ulong[] ReadUInt64Array(int length); | |
void WriteUInt64Array(ulong[] value); | |
long[] ReadInt64Array(int length); | |
void WriteInt64Array(long[] value); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment