compareRecords static method
Compare two records
Initial record to compare with
Next record to compare with the initial
DistributedConnection is required in case a structure holds items at the other end
Implementation
static int compareRecords(IRecord? initial, IRecord? next) {
if (next == null) return RecordComparisonResult.Null;
if (initial == null) return RecordComparisonResult.Record;
if (next == initial) return RecordComparisonResult.Same;
if (next.runtimeType == initial.runtimeType)
return RecordComparisonResult.RecordSameType;
return RecordComparisonResult.Record;
}