--- /dev/null
+package org.simantics.graph.db;\r
+\r
+import java.util.Collection;\r
+\r
+import org.simantics.db.Resource;\r
+import org.simantics.db.WriteOnlyGraph;\r
+import org.simantics.db.exception.DatabaseException;\r
+import org.simantics.graph.representation.Root;\r
+\r
+public interface IImportAdvisor2 extends IImportAdvisor {\r
+\r
+ public static class RootInfo {\r
+ public Root root;\r
+ public String name;\r
+ public Resource resource;\r
+ public RootInfo(Root root, String name, Resource resource) {\r
+ this.root = root;\r
+ this.name = name;\r
+ this.resource = resource;\r
+ }\r
+ }\r
+ \r
+ /*\r
+ * This switches target to another location\r
+ */\r
+ void redirect(Resource temp);\r
+ \r
+ Resource getTarget();\r
+ \r
+ @Deprecated\r
+ Collection<Resource> getRoots();\r
+ @Deprecated\r
+ Collection<RootInfo> getRootInfo();\r
+ \r
+ void beforeWrite(WriteOnlyGraph graph, TransferableGraphImporter process) throws DatabaseException;\r
+ void afterWrite(WriteOnlyGraph graph, TransferableGraphImporter process) throws DatabaseException;\r
+ boolean allowImmutableModifications();\r
+ Resource createChild(WriteOnlyGraph graph, TransferableGraphImporter process, Resource parent, String name) throws DatabaseException;\r
+ Resource createChild(WriteOnlyGraph graph, TransferableGraphImporter process, Resource parent, Resource child, String name) throws DatabaseException;\r
+ Resource createRoot(WriteOnlyGraph graph, Root root, Resource resource) throws DatabaseException;\r
+\r
+}\r