public byte GetByte() { if (ReadBytes + sizeof(byte) > WrittenBytes) throw new AegisException(AegisResult.BufferUnderflow, "No more readable buffer."); var val = (byte)Buffer[ReadBytes]; ReadBytes += sizeof(byte); return val; }