/** Add to the probability for a transition. */ public void addToProbability( int i, int j, double prob, double delay, int module, int fdIndex, String label) { if (fdIndex < 0) addToProbability(i, j, prob); else { FDEvent fdEvent = getFDEvent(module, fdIndex); if (fdEvent == null) { fdEvent = new FDEvent(label, numStates, delay, module, fdIndex); addFDEvent(fdEvent); } fdEvent.addToProbability(i, j, prob); } }
public FDEvent getFDEvent(int module, int index) { for (FDEvent fdEvent : fdEvents) { if (fdEvent.getModule() == module && fdEvent.getIndex() == index) return fdEvent; } return null; }
@Override public void addStates(int numToAdd) { super.addStates(numToAdd); for (FDEvent fdEvent : fdEvents) fdEvent.addStates(numToAdd); }