| @@ 143-157 (lines=15) @@ | ||
| 140 | } |
|
| 141 | ||
| 142 | // Resets the local clocks of uncontrollable events that took place in the tic |
|
| 143 | private void resetClocks(String timeline,String from, String to) { |
|
| 144 | //this.timelineClocks.put(timeline+"."+timeline+"_clock",0); |
|
| 145 | //System.out.println(" RESET CLOCK : " + timeline + " " + token + "<<<<<<<<<<<<<<<<<<<\n"); |
|
| 146 | Map<String,String> condToken = this.uPostConditions.get(new Transition(timeline,from,to)); |
|
| 147 | //System.out.println("CONDTOKEN : " + condToken + "\n"); |
|
| 148 | if(condToken!=null) { |
|
| 149 | for(String cond : condToken.keySet()) { |
|
| 150 | if(condToken.get(cond).contains("0")) { |
|
| 151 | this.timelineClocks.put(cond, 0l); |
|
| 152 | } |
|
| 153 | if(condToken.get(cond).contains("H")) { |
|
| 154 | this.timelineClocks.put(cond, this.horizon*2); |
|
| 155 | } |
|
| 156 | } |
|
| 157 | this.timelineClocks.put(timeline, 0l); |
|
| 158 | }} |
|
| 159 | ||
| 160 | //updates, after a winning transition, the next expected state |
|
| @@ 137-151 (lines=15) @@ | ||
| 134 | } |
|
| 135 | ||
| 136 | // Resets the local clocks of uncontrollable events that took place in the tic |
|
| 137 | private void resetClocks(String timeline,Transition token) { |
|
| 138 | //this.timelineClocks.put(timeline+"."+timeline+"_clock",0); |
|
| 139 | //System.out.println(" RESET CLOCK : " + timeline + " " + token + "<<<<<<<<<<<<<<<<<<<\n"); |
|
| 140 | Map<String,String> condToken = this.uPostConditions.get(token); |
|
| 141 | //System.out.println("CONDTOKEN : " + condToken + "\n"); |
|
| 142 | if(condToken!=null) { |
|
| 143 | for(String cond : condToken.keySet()) { |
|
| 144 | if(condToken.get(cond).contains("0")) { |
|
| 145 | this.timelineClocks.put(cond, 0l); |
|
| 146 | } |
|
| 147 | if(condToken.get(cond).contains("H")) { |
|
| 148 | this.timelineClocks.put(cond, this.horizon*2); |
|
| 149 | } |
|
| 150 | } |
|
| 151 | this.timelineClocks.put(timeline, 0l); |
|
| 152 | }} |
|
| 153 | ||
| 154 | //updates, after a winning transition, the next expected state |
|