public bool BeginReadSize(out EndObject endObject, out int length) { length = ReadInt(); #if DEBUG if (length < -1) { throw new Exception("Something went wrong!"); } #endif if (length == -1) { endObject = default; return(false); } endObject = (EndObject)(StreamPosition + length); return(true); }
public void EndObject(EndObject endObject) { SetPosition((long)endObject); }