refactor: Replace DataPacket w/ IDataPacket in many places
This commit is contained in:
1 parent
49a952fb32
commit
03a8f4e9c0
64 files changed
+191
-200
No files matched your search
@@ -25,7 +25,7 @@ public class FilterStreamTests {
|
||||
filterStream.onChange += onFilterStreamChange;
|
||||
|
||||
void onFilterStreamChange(object newValue) {
|
||||
var dp = (DataPacket)newValue;
|
||||
var dp = (IDataPacket)newValue;
|
||||
actual.Add(new(new BlueTable(dp.newRows), new BlueTable(dp.addedRows), new BlueTable(dp.deletedRows)));
|
||||
}
|
||||
|
||||
@@ -115,9 +115,9 @@ public class FilterStreamTests {
|
||||
/// <summary>
|
||||
/// Test outcome, represented as a sequence of DataPackets.
|
||||
/// </summary>
|
||||
class Outcome : IReadOnlyList<DataPacket?> {
|
||||
class Outcome : IReadOnlyList<IDataPacket?> {
|
||||
readonly IBlueTableSchema schema;
|
||||
readonly List<DataPacket?> history = new();
|
||||
readonly List<IDataPacket?> history = new();
|
||||
BlueTable? currBlueRows;
|
||||
|
||||
public Outcome(IBlueTableSchema schema) =>
|
||||
@@ -125,9 +125,9 @@ public class FilterStreamTests {
|
||||
|
||||
public int Count => history.Count;
|
||||
|
||||
public DataPacket? this[int index] => history[index];
|
||||
public IDataPacket? this[int index] => history[index];
|
||||
|
||||
public DataPacket? Add(
|
||||
public IDataPacket? Add(
|
||||
IEnumerable<(int Id, int Value)>? addedRows = null,
|
||||
IEnumerable<(int Id, int Value)>? removedRows = null
|
||||
) {
|
||||
@@ -151,7 +151,7 @@ public class FilterStreamTests {
|
||||
return rv;
|
||||
}
|
||||
|
||||
public IEnumerator<DataPacket> GetEnumerator() =>
|
||||
public IEnumerator<IDataPacket> GetEnumerator() =>
|
||||
history.GetEnumerator();
|
||||
|
||||
IEnumerator IEnumerable.GetEnumerator() =>
|
||||
|
||||
Reference in new issue
Block a user