X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.acorn%2Fsrc%2Forg%2Fsimantics%2Facorn%2Fcluster%2FClusterBig.java;h=1de4006a72e630482a22dd5390c39b2e411fb15b;hp=f623d587f8d745907a86edf18fd1977fb5bfc894;hb=56a799c9b7d395cefb59e101cd0f7ce8d68f88e6;hpb=861a3da972d67bf5f0d246129c63f611922e03f0 diff --git a/bundles/org.simantics.acorn/src/org/simantics/acorn/cluster/ClusterBig.java b/bundles/org.simantics.acorn/src/org/simantics/acorn/cluster/ClusterBig.java index f623d587f..1de4006a7 100644 --- a/bundles/org.simantics.acorn/src/org/simantics/acorn/cluster/ClusterBig.java +++ b/bundles/org.simantics.acorn/src/org/simantics/acorn/cluster/ClusterBig.java @@ -15,7 +15,10 @@ import java.io.ByteArrayInputStream; import java.io.IOException; import java.io.InputStream; import java.util.Arrays; +import java.util.function.Consumer; +import org.simantics.acorn.exception.AcornAccessVerificationException; +import org.simantics.acorn.exception.IllegalAcornStateException; import org.simantics.acorn.internal.ClusterChange; import org.simantics.acorn.internal.ClusterStream; import org.simantics.acorn.internal.ClusterSupport2; @@ -50,7 +53,6 @@ import org.simantics.db.procore.cluster.PredicateTable; import org.simantics.db.procore.cluster.ResourceTable; import org.simantics.db.procore.cluster.ValueTable; import org.simantics.db.service.ClusterUID; -import org.simantics.utils.datastructures.Callback; final public class ClusterBig extends ClusterImpl { private static final int TABLE_HEADER_SIZE = TableHeader.HEADER_SIZE + TableHeader.EXTRA_SIZE; @@ -571,8 +573,11 @@ final public class ClusterBig extends ClusterImpl { try { return resourceTable.getValue(valueTable, resourceIndex); } catch (ExternalValueException e) { - return clusterSupport.impl.getResourceFile(clusterUID.asBytes(), resourceIndex); -// return support.getValueEx(resourceIndex, clusterUID.second); + try { + return clusterSupport.impl.getResourceFile(clusterUID.asBytes(), resourceIndex); + } catch (AcornAccessVerificationException | IllegalAcornStateException e1) { + throw new DatabaseException(e1); + } } } @Override @@ -859,7 +864,7 @@ final public class ClusterBig extends ClusterImpl { } @Override - public void load(Callback r) { + public void load(Consumer r) { throw new Error("Not supported."); }