public CustomedTransition newTransition(String type) { String packageName = "processEngine.ptnetCustom."; CustomedTransition ct = null; try { ct = (CustomedTransition) Class.forName(packageName + type).newInstance(); ct.setId(pTNetMem.getTransitionCount()); } catch (InstantiationException e) { Log.getLogger(Config.FLOW).fatal("fail to reflect the class", e); } catch (IllegalAccessException e) { Log.getLogger(Config.FLOW).fatal("fail to reflect the class", e); } catch (ClassNotFoundException e) { Log.getLogger(Config.FLOW).fatal("fail to reflect the class", e); } return ct; }
private Transition lookupTransition(int transitionId) { if (null == pTNetMem) return null; else return pTNetMem.getTransition(transitionId); }
private Place lookupPlace(int placeId) { if (null == pTNetMem) return null; else return pTNetMem.getPlace(placeId); }
public void addTransition(CustomedTransition ft) { if (ptnet.addTransition(ft)) { if (null == pTNetMem) return; else pTNetMem.addTransition(ft); } }
public void addPlace(CustomedPlace fp) { if (ptnet.addPlace(fp)) { if (null == pTNetMem) return; else pTNetMem.addPlace(fp); } }