diff options
author | 2023-07-25 17:17:17 +0200 | |
---|---|---|
committer | 2023-07-26 12:06:04 +0200 | |
commit | dd2d8a1517f3f198fe005ebf91a4f8e912609c1b (patch) | |
tree | c93cf59896c6959b588325315cd045714948dae5 /subprojects/store/src/main/java/tools | |
parent | Add best first strategy (diff) | |
download | refinery-dd2d8a1517f3f198fe005ebf91a4f8e912609c1b.tar.gz refinery-dd2d8a1517f3f198fe005ebf91a4f8e912609c1b.tar.zst refinery-dd2d8a1517f3f198fe005ebf91a4f8e912609c1b.zip |
Add visualization adapter
Uses Graphviz to create a visualization of the models and can save them to disk as an image or various textual representations
Diffstat (limited to 'subprojects/store/src/main/java/tools')
-rw-r--r-- | subprojects/store/src/main/java/tools/refinery/store/model/Model.java | 4 | ||||
-rw-r--r-- | subprojects/store/src/main/java/tools/refinery/store/model/internal/ModelImpl.java | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/subprojects/store/src/main/java/tools/refinery/store/model/Model.java b/subprojects/store/src/main/java/tools/refinery/store/model/Model.java index d58d91c3..703a0720 100644 --- a/subprojects/store/src/main/java/tools/refinery/store/model/Model.java +++ b/subprojects/store/src/main/java/tools/refinery/store/model/Model.java | |||
@@ -7,9 +7,11 @@ package tools.refinery.store.model; | |||
7 | 7 | ||
8 | import tools.refinery.store.adapter.ModelAdapter; | 8 | import tools.refinery.store.adapter.ModelAdapter; |
9 | import tools.refinery.store.map.Versioned; | 9 | import tools.refinery.store.map.Versioned; |
10 | import tools.refinery.store.model.internal.VersionedInterpretation; | ||
10 | import tools.refinery.store.representation.AnySymbol; | 11 | import tools.refinery.store.representation.AnySymbol; |
11 | import tools.refinery.store.representation.Symbol; | 12 | import tools.refinery.store.representation.Symbol; |
12 | 13 | ||
14 | import java.util.Map; | ||
13 | import java.util.Optional; | 15 | import java.util.Optional; |
14 | 16 | ||
15 | public interface Model extends Versioned { | 17 | public interface Model extends Versioned { |
@@ -27,6 +29,8 @@ public interface Model extends Versioned { | |||
27 | 29 | ||
28 | <T> Interpretation<T> getInterpretation(Symbol<T> symbol); | 30 | <T> Interpretation<T> getInterpretation(Symbol<T> symbol); |
29 | 31 | ||
32 | public Map<? extends AnySymbol, ? extends Interpretation<?>> getInterpretations(); | ||
33 | |||
30 | ModelDiffCursor getDiffCursor(long to); | 34 | ModelDiffCursor getDiffCursor(long to); |
31 | 35 | ||
32 | <T extends ModelAdapter> Optional<T> tryGetAdapter(Class<? extends T> adapterType); | 36 | <T extends ModelAdapter> Optional<T> tryGetAdapter(Class<? extends T> adapterType); |
diff --git a/subprojects/store/src/main/java/tools/refinery/store/model/internal/ModelImpl.java b/subprojects/store/src/main/java/tools/refinery/store/model/internal/ModelImpl.java index c5475a1a..bf6987d6 100644 --- a/subprojects/store/src/main/java/tools/refinery/store/model/internal/ModelImpl.java +++ b/subprojects/store/src/main/java/tools/refinery/store/model/internal/ModelImpl.java | |||
@@ -187,4 +187,8 @@ public class ModelImpl implements Model { | |||
187 | public void removeListener(ModelListener listener) { | 187 | public void removeListener(ModelListener listener) { |
188 | listeners.remove(listener); | 188 | listeners.remove(listener); |
189 | } | 189 | } |
190 | |||
191 | public Map<? extends AnySymbol, ? extends Interpretation<?>> getInterpretations() { | ||
192 | return interpretations; | ||
193 | } | ||
190 | } | 194 | } |