aboutsummaryrefslogtreecommitdiffstats
path: root/Solvers
diff options
context:
space:
mode:
authorLibravatar OszkarSemerath <oszkar.semerath@gmail.com>2018-07-05 14:51:12 +0200
committerLibravatar OszkarSemerath <oszkar.semerath@gmail.com>2018-07-05 14:51:12 +0200
commit35d887b2b0a2fcaf480019f070bd6c58b325d23f (patch)
tree1ed8a0dbd26959b243e7afd997fa800d958b4f9d /Solvers
parentFixing multiple true/false + bug preventing generation without PS (diff)
downloadVIATRA-Generator-35d887b2b0a2fcaf480019f070bd6c58b325d23f.tar.gz
VIATRA-Generator-35d887b2b0a2fcaf480019f070bd6c58b325d23f.tar.zst
VIATRA-Generator-35d887b2b0a2fcaf480019f070bd6c58b325d23f.zip
Added support for running application in plain java.
(However, I might added several unnecessary dependencies to the visualisation package.)
Diffstat (limited to 'Solvers')
-rw-r--r--Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/META-INF/MANIFEST.MF29
-rw-r--r--Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/src/hu/bme/mit/inf/dslreasoner/visualisation/pi2graphviz/VisualisationQueque.xtend8
2 files changed, 33 insertions, 4 deletions
diff --git a/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/META-INF/MANIFEST.MF b/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/META-INF/MANIFEST.MF
index 18331278..699c9308 100644
--- a/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/META-INF/MANIFEST.MF
+++ b/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/META-INF/MANIFEST.MF
@@ -12,8 +12,33 @@ Require-Bundle: com.google.guava,
12 hu.bme.mit.inf.dslreasoner.viatra2logic;bundle-version="1.0.0", 12 hu.bme.mit.inf.dslreasoner.viatra2logic;bundle-version="1.0.0",
13 hu.bme.mit.inf.dslreasoner.logic.model.validation;bundle-version="0.0.1", 13 hu.bme.mit.inf.dslreasoner.logic.model.validation;bundle-version="0.0.1",
14 org.eclipse.emf.ecore.xmi;bundle-version="2.12.0", 14 org.eclipse.emf.ecore.xmi;bundle-version="2.12.0",
15 guru.nidi.graphviz-java;bundle-version="0.2.1" 15 guru.nidi.graphviz-java;bundle-version="0.2.1";visibility:=reexport,
16Import-Package: org.apache.log4j;version="1.2.15" 16 org.apache.batik.transcoder;bundle-version="1.6.0",
17 org.apache.batik.dom;bundle-version="[1.6.1,1.6.2]",
18 org.apache.batik.bridge;bundle-version="[1.6.0,1.6.1]",
19 org.apache.batik.dom.svg;bundle-version="[1.6.0,1.6.1]",
20 org.apache.batik.util;bundle-version="[1.6.0,1.6.1]",
21 org.apache.batik.css;bundle-version="[1.6.0,1.6.1]",
22 org.apache.batik.parser;bundle-version="[1.6.0,1.6.1]",
23 org.apache.batik.pdf;bundle-version="[1.6.0,1.6.1]",
24 org.apache.batik.svggen;bundle-version="[1.6.0,1.6.1]",
25 org.apache.batik.xml;bundle-version="[1.6.0,1.6.1]",
26 org.apache.batik.ext.awt;bundle-version="[1.6.0,1.6.1]",
27 org.apache.batik.util.gui;bundle-version="[1.6.0,1.6.1]",
28 org.apache.xerces;bundle-version="2.9.0",
29 org.w3c.dom.svg;bundle-version="1.1.0",
30 org.w3c.css.sac;bundle-version="1.3.1"
31Import-Package: com.eclipsesource.v8;version="4.6.0",
32 com.eclipsesource.v8.debug;version="4.6.0",
33 com.eclipsesource.v8.utils;version="4.6.0",
34 com.eclipsesource.v8.utils.typedarrays;version="4.6.0",
35 javax.imageio,
36 javax.xml.parsers,
37 org.apache.log4j;version="1.2.15",
38 org.slf4j;version="1.7.2",
39 org.w3c.dom,
40 org.xml.sax,
41 org.xml.sax.helpers
17Export-Package: hu.bme.mit.inf.dslreasoner.visualisation.pi2graphviz 42Export-Package: hu.bme.mit.inf.dslreasoner.visualisation.pi2graphviz
18Automatic-Module-Name: hu.bme.mit.inf.dslreasoner.visualisation 43Automatic-Module-Name: hu.bme.mit.inf.dslreasoner.visualisation
19 44
diff --git a/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/src/hu/bme/mit/inf/dslreasoner/visualisation/pi2graphviz/VisualisationQueque.xtend b/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/src/hu/bme/mit/inf/dslreasoner/visualisation/pi2graphviz/VisualisationQueque.xtend
index 79074bfc..b067ba7d 100644
--- a/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/src/hu/bme/mit/inf/dslreasoner/visualisation/pi2graphviz/VisualisationQueque.xtend
+++ b/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/src/hu/bme/mit/inf/dslreasoner/visualisation/pi2graphviz/VisualisationQueque.xtend
@@ -11,6 +11,7 @@ import java.util.concurrent.BlockingQueue
11import java.util.concurrent.CompletableFuture 11import java.util.concurrent.CompletableFuture
12import java.util.concurrent.LinkedBlockingQueue 12import java.util.concurrent.LinkedBlockingQueue
13import org.eclipse.xtend.lib.annotations.Data 13import org.eclipse.xtend.lib.annotations.Data
14import java.util.function.Consumer
14 15
15class VisualisationQueque { 16class VisualisationQueque {
16 val BlockingQueue<VisualisationQueueEntry> taskQueue = new LinkedBlockingQueue 17 val BlockingQueue<VisualisationQueueEntry> taskQueue = new LinkedBlockingQueue
@@ -43,9 +44,12 @@ class VisualisationQueque {
43 // do nothing 44 // do nothing
44 } else { 45 } else {
45 runnerThread = new Thread(new Runnable() { 46 runnerThread = new Thread(new Runnable() {
46 val engine = new GraphvizV8Engine()
47
48 override run() { 47 override run() {
48 val engine = new GraphvizV8Engine()
49 val nullConsumer = new Consumer<GraphvizEngine>() {
50 override accept(GraphvizEngine t) {}
51 }
52 engine.init(nullConsumer,nullConsumer)
49 //println("Visualisation thread started") 53 //println("Visualisation thread started")
50 while(true) { 54 while(true) {
51 val head = taskQueue.take 55 val head = taskQueue.take