]> gerrit.simantics Code Review - simantics/interop.git/blobdiff - org.simantics.interop.mapping/src/org/simantics/interop/mapping/SplittingWriteGraph.java
Fixed interop WriteGraph implementations after changes to ReadGraph.
[simantics/interop.git] / org.simantics.interop.mapping / src / org / simantics / interop / mapping / SplittingWriteGraph.java
index c3b02988b5809da26fb5c2840d0f0a14371bcf5f..fb2cbb56ff3e7bb1dae6274e0c4b97288e0a49e8 100644 (file)
@@ -6240,4 +6240,60 @@ public class SplittingWriteGraph implements WriteGraph {
            }\r
        }\r
 \r
+    @Override\r
+    public <T> T getValue2(final Resource subject, final Object context) throws DatabaseException {\r
+        try {\r
+            return (T) session.syncRequest(new Read<T>() {\r
+                @Override\r
+                public T perform(ReadGraph graph) throws DatabaseException {\r
+                    return graph.getValue2(subject, context);\r
+                }\r
+            });\r
+        } catch (DatabaseException e) {\r
+            throw new ServiceException(e);\r
+        }\r
+    }\r
+\r
+    @Override\r
+    public <T> T getPossibleValue2(final Resource subject, final Object context) throws DatabaseException {\r
+        try {\r
+            return (T) session.syncRequest(new Read<T>() {\r
+                @Override\r
+                public T perform(ReadGraph graph) throws DatabaseException {\r
+                    return graph.getPossibleValue2(subject, context);\r
+                }\r
+            });\r
+        } catch (DatabaseException e) {\r
+            throw new ServiceException(e);\r
+        }\r
+    }\r
+\r
+    @Override\r
+    public <T> T getValue2(final Resource subject, final Object context, final Binding binding) throws DatabaseException {\r
+        try {\r
+            return (T) session.syncRequest(new Read<T>() {\r
+                @Override\r
+                public T perform(ReadGraph graph) throws DatabaseException {\r
+                    return graph.getValue2(subject, context, binding);\r
+                }\r
+            });\r
+        } catch (DatabaseException e) {\r
+            throw new ServiceException(e);\r
+        }\r
+    }\r
+\r
+    @Override\r
+    public <T> T getPossibleValue2(final Resource subject, final Object context, final Binding binding) throws DatabaseException {\r
+        try {\r
+            return (T) session.syncRequest(new Read<T>() {\r
+                @Override\r
+                public T perform(ReadGraph graph) throws DatabaseException {\r
+                    return graph.getPossibleValue2(subject, context, binding);\r
+                }\r
+            });\r
+        } catch (DatabaseException e) {\r
+            throw new ServiceException(e);\r
+        }\r
+    }\r
+\r
 }\r