синхронизация с солана
This commit is contained in:
@@ -0,0 +1,44 @@
|
||||
package sync.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public record RecoveryResult(
|
||||
boolean complete,
|
||||
long fromSlot,
|
||||
long toSlot,
|
||||
List<ProgramAccountUpdate> updates,
|
||||
List<String> missingAddresses,
|
||||
String fallbackReason
|
||||
) {
|
||||
|
||||
public static RecoveryResult complete(
|
||||
long fromSlot,
|
||||
long toSlot,
|
||||
List<ProgramAccountUpdate> updates,
|
||||
List<String> missingAddresses
|
||||
) {
|
||||
return new RecoveryResult(
|
||||
true,
|
||||
fromSlot,
|
||||
toSlot,
|
||||
updates,
|
||||
missingAddresses,
|
||||
null
|
||||
);
|
||||
}
|
||||
|
||||
public static RecoveryResult incomplete(
|
||||
long fromSlot,
|
||||
long toSlot,
|
||||
String fallbackReason
|
||||
) {
|
||||
return new RecoveryResult(
|
||||
false,
|
||||
fromSlot,
|
||||
toSlot,
|
||||
List.of(),
|
||||
List.of(),
|
||||
fallbackReason
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user