]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.spreadsheet/src/org/simantics/spreadsheet/Transaction.java
Adopt spreadsheet changes made in Balas development
[simantics/platform.git] / bundles / org.simantics.spreadsheet / src / org / simantics / spreadsheet / Transaction.java
diff --git a/bundles/org.simantics.spreadsheet/src/org/simantics/spreadsheet/Transaction.java b/bundles/org.simantics.spreadsheet/src/org/simantics/spreadsheet/Transaction.java
new file mode 100644 (file)
index 0000000..3702a22
--- /dev/null
@@ -0,0 +1,24 @@
+package org.simantics.spreadsheet;
+
+import java.util.List;
+
+public interface Transaction<O> {
+
+    void setContext(Object context);
+
+    Object getContext();
+
+    void add(O operation);
+
+    /*
+     * Applies the operations collected with this transaction
+     * 
+     */
+    void commit();
+
+    boolean isOperationMode();
+
+    List<Object> needSynchronization();
+
+    void needSynchronization(Object synchronizable);
+}
\ No newline at end of file