]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.graph/src/org/simantics/graph/representation/old/OldTransferableGraph1.java
(refs #7216) Removed OldTransferableGraph1 and all referring code
[simantics/platform.git] / bundles / org.simantics.graph / src / org / simantics / graph / representation / old / OldTransferableGraph1.java
diff --git a/bundles/org.simantics.graph/src/org/simantics/graph/representation/old/OldTransferableGraph1.java b/bundles/org.simantics.graph/src/org/simantics/graph/representation/old/OldTransferableGraph1.java
deleted file mode 100644 (file)
index b68bea3..0000000
+++ /dev/null
@@ -1,88 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2007, 2010 Association for Decentralized Information Management
- * in Industry THTH ry.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- *     VTT Technical Research Centre of Finland - initial API and implementation
- *******************************************************************************/
-package org.simantics.graph.representation.old;
-
-import java.util.TreeMap;
-
-import org.simantics.databoard.Bindings;
-import org.simantics.databoard.binding.Binding;
-import org.simantics.databoard.binding.mutable.Variant;
-import org.simantics.databoard.serialization.Serializer;
-import org.simantics.graph.representation.External;
-import org.simantics.graph.representation.Identity;
-import org.simantics.graph.representation.Internal;
-import org.simantics.graph.representation.Root;
-import org.simantics.graph.tests.conversion.TransferableGraph0;
-
-
-/**
- * Transferable graph datatype. 
- * See <a href="https://www.simantics.org/wiki/index.php/Graph_exchange_format">specification</a>. 
- * @author Hannu Niemist�
- * 
- * @deprecated superceded by {@link TransferableGraph0}
- */
-@Deprecated
-public class OldTransferableGraph1 {
-       public static Binding BINDING = Bindings.getBindingUnchecked(OldTransferableGraph1.class);
-       public static Serializer SERIALIZER = Bindings.getSerializerUnchecked(BINDING);
-       
-       public int resourceCount;
-       public Identity[] identities;   
-       public int[] statements;
-       public OldValue1[] values;
-       public TreeMap<String, Variant> extensions;
-       
-       public OldTransferableGraph1() {}
-       
-       public OldTransferableGraph1(int resourceCount, Identity[] identities,
-                       int[] statements, OldValue1[] values) {
-               this(resourceCount, identities, statements, values,
-                               new TreeMap<String, Variant>());
-       }
-       
-       public OldTransferableGraph1(int resourceCount, Identity[] identities,
-                       int[] statements, OldValue1[] values, TreeMap<String, Variant> extensions) {
-               this.resourceCount = resourceCount;
-               this.identities = identities;
-               this.statements = statements;
-               this.values = values;
-               this.extensions = extensions;
-       }
-
-       public void print() {
-               System.out.println("Identities");
-               for(Identity id : identities) {
-                       System.out.print("    " + id.resource + " = ");
-                       if(id.definition instanceof Root) {
-                               Root def = (Root)id.definition;
-                               System.out.println("ROOT(" + def.name + ")");
-                       }
-                       else if(id.definition instanceof External) {
-                               External def = (External)id.definition;
-                               System.out.println("EXTERNAL(" + def.parent + ", " + def.name + ")");
-                       }
-                       else if(id.definition instanceof Internal) {
-                               Internal def = (Internal)id.definition;
-                               System.out.println("INTERNAL(" + def.parent + ", " + def.name + ")");
-                       }
-               }
-               System.out.println("Statements:");
-               for(int i=0;i<statements.length;i+=4)
-                       System.out.println("    " + 
-                                       statements[i] + " " +
-                                       statements[i+1] + " " +
-                                       statements[i+2] + " " +
-                                       statements[i+3]
-                                       );
-       }
-}