de.uni.freiburg.iig.telematik.sepia.mg.abstr.AbstractMarkingGraph Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of SEPIA Show documentation
Show all versions of SEPIA Show documentation
SEPIA provides implementations for various types of Petri nets. Along Place/Transition-nets, it supports Petri nets with distinguishable token colors and defines coloured workflow nets, where coloured tokens are interpreted as data elements used during process execution. To support information flow analysis of processes, SEPIA defines so-called IF-Nets, tailored for security-oriented workflow modeling which enable users to assign security-levels (HIGH, LOW) to transitions, data elements and persons/agents participating in the process execution.
The newest version!
package de.uni.freiburg.iig.telematik.sepia.mg.abstr;
import java.util.Collection;
import de.uni.freiburg.iig.telematik.jagal.ts.Event;
import de.uni.freiburg.iig.telematik.jagal.ts.labeled.abstr.AbstractLabeledTransitionRelation;
import de.uni.freiburg.iig.telematik.jagal.ts.labeled.abstr.AbstractLabeledTransitionSystem;
import de.uni.freiburg.iig.telematik.sepia.petrinet.abstr.AbstractMarking;
public abstract class AbstractMarkingGraph, O extends Object, S extends AbstractMarkingGraphState, R extends AbstractLabeledTransitionRelation> extends AbstractLabeledTransitionSystem {
private static final long serialVersionUID = 5262052130079149612L;
private S initialState = null;
public AbstractMarkingGraph() {
super();
}
public AbstractMarkingGraph(String name) {
super(name);
}
public AbstractMarkingGraph(Collection states) {
super(states);
}
public AbstractMarkingGraph(String name, Collection states) {
super(name, states);
}
public AbstractMarkingGraph(Collection states, Collection events) {
super(states, events);
}
public AbstractMarkingGraph(String name, Collection states, Collection events) {
super(name, states, events);
}
public S getInitialState() {
return initialState;
}
public void setInitialState(String name) {
this.initialState = getState(name);
}
@Override
public String toString(){
StringBuilder relations = new StringBuilder();
boolean firstEntry = true;
for(R relation: getRelations()){
if(!firstEntry){
relations.append(" ");
}
relations.append(relation.toString());
relations.append('\n');
firstEntry = false;
}
return String.format(toStrFormat, getVertices(), startStates.keySet(), endStates.keySet(), events.keySet(), relations.toString());
}
@Override
protected abstract R createNewTransitionRelation(String sourceStateName, String targetStateName, String eventName) throws Exception;
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy