public static void WriteVLong(long i, FastOutputStream stream) { while ((i & ~0x7F) != 0) { stream.WriteByte((byte)((i & 0x7f) | 0x80)); i >>= 7; } stream.WriteByte((byte)i); }
public void Marshal(Object nl, Stream os) { daos = new FastOutputStream(os); try { daos.WriteByte(VERSION); WriteVal(nl); } finally { daos.Flush(); daos.Close(); } }