173 * calcHead.fillValuesfrom(newCalcHead); //TODO: Remove the following |
173 * calcHead.fillValuesfrom(newCalcHead); //TODO: Remove the following |
174 * line!! calcHead.setCalcHeadStatus(CalcHead.MODEL_ITEM_CORRECT); } |
174 * line!! calcHead.setCalcHeadStatus(CalcHead.MODEL_ITEM_CORRECT); } |
175 * catch (RemoteException e) { e.printStackTrace(); } } |
175 * catch (RemoteException e) { e.printStackTrace(); } } |
176 */ |
176 */ |
177 |
177 |
178 /** |
178 // /** |
179 * Refine a given problem for this CalcTree |
179 // * Refine a given problem for this CalcTree |
180 * |
180 // * |
181 * @param problemID |
181 // * @param problemID |
182 * @return CalcHead, if the operation was successful, else null |
182 // * @return CalcHead, if the operation was successful, else null |
183 */ |
183 // */ |
184 public void tryRefine(CalcHead calcHead, CalcHeadCompoundID problemID) |
184 // public void tryRefine(CalcHead calcHead, CalcHeadCompoundID problemID) |
185 throws NotInSpecificationPhaseException { |
185 // throws NotInSpecificationPhaseException { |
186 CalcHead newCalcHead = null; |
186 // CalcHead newCalcHead = null; |
187 try { |
187 // try { |
188 //WN040924 newCalcHead = |
188 // //WN040924 newCalcHead = |
189 // bridgeRMI.tryRefine(calcHead.getCalcTreeID(), problemID); |
189 // // bridgeRMI.tryRefine(calcHead.getCalcTreeID(), problemID); |
190 bridgeRMI.tryRefine(calcHead.getCalcTreeID(), problemID); |
190 // bridgeRMI.tryRefine(calcHead.getCalcTreeID(), problemID); |
191 if (newCalcHead == null) { |
191 // if (newCalcHead == null) { |
192 throw new NotInSpecificationPhaseException(); |
192 // throw new NotInSpecificationPhaseException(); |
193 } |
193 // } |
194 calcHead.fillValuesfrom(newCalcHead); |
194 // calcHead.fillValuesfrom(newCalcHead); |
195 } catch (RemoteException e) { |
195 // } catch (RemoteException e) { |
196 // TODO Auto-generated catch block |
196 // // TODO Auto-generated catch block |
197 e.printStackTrace(); |
197 // e.printStackTrace(); |
198 } |
198 // } |
199 } |
199 // } |
200 |
200 |
201 /** |
201 //WN050610 transferred toCalcTree |
202 * Match a given problem for this CalcTree |
202 // /** |
203 * |
203 // * Match a given problem for this CalcTree |
204 * @param problemID |
204 // * |
205 * @return CalcHead, if the operation was successful, else null |
205 // * @param problemID |
206 */ |
206 // * @return CalcHead, if the operation was successful, else null |
207 public void tryMatch(CalcHead calcHead, CalcHeadCompoundID problemID) |
207 // */ |
208 throws NotInSpecificationPhaseException { |
208 // public void tryMatch(CalcHead calcHead, CalcHeadCompoundID problemID) |
209 CalcHead newCalcHead = null; |
209 // throws NotInSpecificationPhaseException { |
210 try { |
210 // CalcHead newCalcHead = null; |
211 //WN040924 newCalcHead = |
211 // try { |
212 // bridgeRMI.tryMatch(calcHead.getCalcTreeID(), problemID); |
212 // //WN040924 newCalcHead = |
213 bridgeRMI.tryMatch(calcHead.getCalcTreeID(), problemID); |
213 // // bridgeRMI.tryMatch(calcHead.getCalcTreeID(), problemID); |
214 if (newCalcHead == null) { |
214 // bridgeRMI.tryMatch(calcHead.getCalcTreeID(), problemID); |
215 throw new NotInSpecificationPhaseException(); |
215 // if (newCalcHead == null) { |
216 } |
216 // throw new NotInSpecificationPhaseException(); |
217 calcHead.fillValuesfrom(newCalcHead); |
217 // } |
218 } catch (RemoteException e) { |
218 // calcHead.fillValuesfrom(newCalcHead); |
219 // TODO Auto-generated catch block |
219 // } catch (RemoteException e) { |
220 e.printStackTrace(); |
220 // // TODO Auto-generated catch block |
221 } |
221 // e.printStackTrace(); |
222 } |
222 // } |
|
223 // } |
223 |
224 |
224 // Delegated methods from CalcTree/Iterator |
225 // Delegated methods from CalcTree/Iterator |
225 int setNextTactic(int id, Tactic tactic) throws RemoteException { |
226 int setNextTactic(int id, Tactic tactic) throws RemoteException { |
226 return bridgeRMI.setNextTactic(id, tactic); |
227 return bridgeRMI.setNextTactic(id, tactic); |
227 } |
228 } |