private static void Download_VM(Session session, List <ObjectChange> changes) { Dictionary <XenRef <VM>, VM> records = VM.get_all_records(session); foreach (KeyValuePair <XenRef <VM>, VM> entry in records) { changes.Add(new ObjectChange(typeof(VM), entry.Key.opaque_ref, entry.Value)); } }