Skip to content
Snippets Groups Projects
Commit 2c596476 authored by Sebastian Ebert's avatar Sebastian Ebert
Browse files

added debugging methods in nav

parent 369e34d8
Branches
No related tags found
No related merge requests found
...@@ -251,6 +251,37 @@ aspect Navigation { ...@@ -251,6 +251,37 @@ aspect Navigation {
return null; return null;
} }
syn String PetriNet.PlaceStringExport() {
String res = "";
for (Place p : this.allPlaces()) {
res += p.getId() + ", ";
}
return res;
}
syn RefPlace PetriNet.getRefPlaceById(String id) {
for (RefPlace rp : this.allRefPlaces()) {
if (rp.getId().equals(id)) {
return rp;
}
}
return null;
}
syn List<Place> PetriNet.getPlacesWithContainingString(String s) {
List<Place> res = new ArrayList<>();
for (Place p : this.allPlaces()) {
if (p.getId().contains(s)) {
res.add(p);
}
}
return res;
}
syn RefTransition PetriNet.getRefTransitionFromTransitionNode(TransitionNode tNode) { syn RefTransition PetriNet.getRefTransitionFromTransitionNode(TransitionNode tNode) {
if (tNode.isRefTransition()) { if (tNode.isRefTransition()) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment