-
Notifications
You must be signed in to change notification settings - Fork 5
/
IDifferential.java
34 lines (22 loc) · 1009 Bytes
/
IDifferential.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
package org.genericsystem.common;
import java.util.Map;
import org.genericsystem.api.core.Snapshot;
import org.genericsystem.api.core.exceptions.ConcurrencyControlException;
import org.genericsystem.api.core.exceptions.OptimisticLockConstraintViolationException;
import org.genericsystem.defaults.DefaultGeneric;
import javafx.beans.Observable;
import javafx.beans.property.ObjectProperty;
import javafx.collections.ObservableList;
/**
* @author Nicolas Feybesse
*
*/
public interface IDifferential<T extends DefaultGeneric<T>> {
long getTs();
Snapshot<T> getDependencies(T generic);
ObjectProperty<IDifferential<T>> getDifferentialProperty();
void apply(Snapshot<T> removes, Snapshot<T> adds) throws ConcurrencyControlException, OptimisticLockConstraintViolationException;
public Observable getObservable(Generic generic);
Map<Generic, ObservableList<Generic>> getDependenciesAsOservableListCacheMap();
// CompletableFuture<Snapshot<Generic>> getDependenciesPromise(Generic generic);
}