bug4006: started to introduce a ReplicationStartingListener on ReplicationService

This commit is contained in:
Axel Uhl
2020-03-06 16:11:55 +01:00
parent a18d9de352
commit 4747c8f331
11 changed files with 109 additions and 36 deletions
@@ -113,7 +113,20 @@ public interface ReplicationService {
*/
ReplicationReceiver getReplicator();
/**
* An update to this attribute can be observed by registering a {@link ReplicationStartingListener} using
* the {@link #addReplicationStartingListener} method.
*/
void setReplicationStarting(boolean b);
@FunctionalInterface
public static interface ReplicationStartingListener {
void onReplicationStartingChanged(boolean newReplicationStartingValue);
}
void addReplicationStartingListener(ReplicationStartingListener listener);
void removeReplicationStartingListener(ReplicationStartingListener listener);
/**
* @return {@code true} if replication is starting; during this phase it is clear that the replicables managed by