/// <summary> /// Writes this database into a binary stream. /// </summary> /// <param name="w">The writer to use.</param> public void Write(ICKBinaryWriter w) { var ctx = new SerializerContext(w, 0); _instances.Write(ctx); ctx.Writer.WriteNonNegativeSmallInt32(_feeds.Count); foreach (var kv in _feeds) { kv.Value.Write(_instances, ctx); } ctx.Writer.Write(_lastUpdate); }