X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=bundles%2Forg.simantics.graph%2Fsrc%2Forg%2Fsimantics%2Fgraph%2Frepresentation%2FExtensions.java;h=e2f0279242169d7cee97e7dd0c0f8ea653f13fda;hb=6bd970eba63ff08a122fdf819e428adaf80cfcef;hp=a8c497f59aae838113201d6d841b94ab9608ab40;hpb=969bd23cab98a79ca9101af33334000879fb60c5;p=simantics%2Fplatform.git diff --git a/bundles/org.simantics.graph/src/org/simantics/graph/representation/Extensions.java b/bundles/org.simantics.graph/src/org/simantics/graph/representation/Extensions.java index a8c497f59..e2f027924 100644 --- a/bundles/org.simantics.graph/src/org/simantics/graph/representation/Extensions.java +++ b/bundles/org.simantics.graph/src/org/simantics/graph/representation/Extensions.java @@ -1,21 +1,36 @@ -package org.simantics.graph.representation; - -import java.util.TreeMap; - -import org.simantics.databoard.binding.mutable.Variant; - -public class Extensions { - - final public static String CLUSTERING = "clustering"; - final public static String CLUSTER_SETS = "clusterSets"; - final public static int NO_CLUSTER_SET = -1; - final public static int ROOT_LIBRARY_CLUSTER_SET = -1; - final public static int INDEX_ROOT_CLUSTER_SET = -2; - - public TreeMap map = new TreeMap(); - - public Extensions(TreeMap map) { - this.map = map; - } - -} +package org.simantics.graph.representation; + +import java.util.TreeMap; + +import org.simantics.databoard.Bindings; +import org.simantics.databoard.binding.Binding; +import org.simantics.databoard.binding.mutable.Variant; + +public class Extensions { + + public static final Binding BINDING = Bindings.getBindingUnchecked(Extensions.class); + + /** + * Used for storing a cached hash code computed from a + * {@link TransferableGraph1} instance in the metadata map of the + * DataContainer containing the TG. + */ + public final static String CACHED_HASHCODE = "cached.hashcode"; + + final public static String CLUSTERING = "clustering"; + final public static String CLUSTER_SETS = "clusterSets"; + final public static int NO_CLUSTER_SET = -1; + final public static int ROOT_LIBRARY_CLUSTER_SET = -1; + final public static int INDEX_ROOT_CLUSTER_SET = -2; + + public TreeMap map; + + public Extensions() { + this.map = new TreeMap<>(); + } + + public Extensions(TreeMap map) { + this.map = map; + } + +}