src/java/isac/wsdialog/DialogGuide.java
author wneuper
Thu, 12 May 2005 16:30:54 +0200
changeset 2295 5a203bae4633
parent 2274 297a87552244
child 2352 4073488bfc57
permissions -rw-r--r--
java intermediate: Worksheets gets DialogIterator instead CalcIterator
     1 package isac.wsdialog;
     2 
     3 import isac.bridge.*;
     4 import isac.session.SDialog;
     5 import isac.util.*;
     6 import isac.util.formulae.*;
     7 import isac.util.interfaces.*;
     8 import isac.util.tactics.*;
     9 import isac.util.users.IUserSettings;
    10 import isac.util.users.User;
    11 import isac.util.users.UserSettings;
    12 
    13 import java.io.Serializable;
    14 import java.net.MalformedURLException;
    15 import java.rmi.*;
    16 import java.rmi.registry.LocateRegistry;
    17 import java.rmi.server.UnicastRemoteObject;
    18 import java.util.Vector;
    19 
    20 import org.apache.log4j.Logger;
    21 
    22 /**
    23  * The DialogGuide moderates the communication between two instances working on
    24  * the same CalcTree object. One of these instances is the user, the other a
    25  * math engine. Most probably, the user's GUI, the DialogGuide and the math
    26  * engine reside on different machines and communicate with each other by means
    27  * of RMI.
    28  * 
    29  * @author Alan Krempler
    30  */
    31 public class DialogGuide extends UnicastRemoteObject implements DGuide,
    32 		IToUser, Serializable {
    33 
    34 	static Logger logger_ = Logger.getLogger(BridgeRMI.class.getName());
    35 
    36 	protected MathEngine math_engine_;
    37 
    38 	//the DialogGuide knowing the CalcTree is the price for closing off
    39 	//the CalcTree from the Worksheet (before DGuide implemented IToCalc!)
    40 	protected CalcTree calc_tree_;
    41 
    42 	//protected CalcHead calc_head_;
    43 
    44 	//protected CalcHead calc_head_sub_;
    45 
    46 	protected int phase_;
    47 
    48 	private Vector datachange_listeners_;
    49 
    50 	private IToWorksheet ui_control_listener_;
    51 
    52 	//protected String session_id_;WN0503
    53 
    54 	protected UserSettings user_settings_;//hold whole hashmap locally
    55 
    56 	/**
    57 	 * @param ME_path
    58 	 *            URL of the math engine to be used
    59 	 * @param user_path
    60 	 *            path(without URL) to UserSettings, UserModel
    61 	 * @param session_dialog
    62 	 * @param session_id
    63 	 *            which create the DialogGuide and Worksheet
    64 	 * @throws RemoteException
    65 	 */
    66 	public DialogGuide(String ME_path, String user_path,
    67 			SDialog session_dialog, String session_id) throws RemoteException {
    68 		super();
    69 		this.rmiBind();
    70 		datachange_listeners_ = new Vector();
    71 		MathEngine.init(ME_path);
    72 		math_engine_ = MathEngine.getMathEngine();
    73 		phase_ = DIALOGPHASE_IDLE;
    74 
    75 		User user = null;
    76 		try {
    77 			user = session_dialog.getUser(session_id);
    78 		} catch (RemoteException e1) {
    79 			e1.printStackTrace();
    80 		}
    81 		user_settings_ = new UserSettings(user_path, user.getUsername());
    82 	}
    83 
    84 	/**
    85 	 * start a calculation
    86 	 */
    87 	public CalcTree startCalculation(int user_id, Formalization f,
    88 			int start_from/* WN050421 , int requested_calchead_view */) {
    89 
    90 		phase_ = DIALOGPHASE_SOLVE;
    91 		calc_tree_ = math_engine_.startCalculation(f);
    92 		calc_tree_.addDataChangeListener(this);
    93 		return calc_tree_;
    94 	}
    95 
    96 	/**
    97 	 * at the beginning of a calculation as well as of a subproblem;
    98 	 * 
    99 	 * @return CalcHead eg. for providing CalcHead#VIEWSTYLE_*
   100 	 * 
   101 	 * @see isac.wsdialog.DGuide#startSpecifying()
   102 	 */
   103 	public CalcHead startSpecifying() {
   104 		ICalcIterator it = null;
   105 		CalcHead calc_head = null;
   106 		int calchead_view;
   107 		try {
   108 			it = calc_tree_.iterator();
   109 			//			WN0504DI it = this.iterator();//WN050421 NEW...
   110 			it.moveRoot();
   111 			//WN0504DI ...error DialogGuide_Stub.startSpecifying(Unknown
   112 			//WN0504DI Source) with ...NEW
   113 			calc_head = (CalcHead) it.getFormula();
   114 		} catch (RemoteException e) {
   115 			e.printStackTrace();
   116 		}
   117 
   118 		//AK set viewstyle according to user settings
   119 		switch (user_settings_.getValue(IUserSettings.KEY1_START_SPECIFY)) {
   120 		//________________________________________________________
   121 		case IUserSettings.VAL1_SKIP_SPECIFY_TO_START_SOLVE:
   122 			calc_tree_.completeCalcHead();
   123 			calchead_view = CalcHead.VIEWSTYLE_SINGLELINE;
   124 			phase_ = DIALOGPHASE_SOLVE;
   125 			break;
   126 		//________________________________________________________
   127 		case IUserSettings.VAL1_POP_CALCHEAD_WITH_DESCRIPTIONS:
   128 			calc_tree_.autoCalculate(IToCalc.SCOPE_CALCULATION, 1);
   129 			//...applies the Tactic Model_Problem which generates descriptions
   130 			calchead_view = CalcHead.VIEWSTYLE_FULL;
   131 			phase_ = DIALOGPHASE_SPECIFY;
   132 			break;
   133 		//________________________________________________________
   134 		default:
   135 			//=case IUserSettings.VAL1_SKIP_SPECIFY_TO_START_SOLVE:
   136 			calc_tree_.completeCalcHead();
   137 			calchead_view = CalcHead.VIEWSTYLE_SINGLELINE;
   138 			phase_ = DIALOGPHASE_SOLVE;
   139 			break;
   140 		}
   141 		calc_head.setViewStyle(calchead_view);
   142 		return calc_head;
   143 	}
   144 
   145 	//	/**
   146 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   147 	//	 */
   148 	//	public void modifyCalcHead(CalcHead calc_head) {
   149 	//		// MathEngine.getMathEngine().modifyCalcHead(calc_head);
   150 	//		calc_tree_.modifyCalcHead(calc_head);
   151 	//	}
   152 
   153 	/**
   154 	 * dismiss the CalcHeadPanel and start DGuide#DIALOGPHASE_SOLVE
   155 	 * 
   156 	 * @see isac.util.interfaces.IToCalc#startSolving()
   157 	 */
   158 	public void startSolving() throws Exception {
   159 		calc_tree_.startSolving();
   160 
   161 	}
   162 
   163 	private CalcChangedEvent toDialogIterators(CalcChangedEvent event) {
   164 		event.getLastUnchangedFormula();
   165 		return event;
   166 	}
   167 
   168 	/**
   169 	 * accept the changes in a calculation reported by the bridge ..............
   170 	 * TODO handle these changes according to UserSettings and UserModel
   171 	 * 
   172 	 * ... and pass them to the WorkSheet
   173 	 * 
   174 	 * @see isac.wsdialog.IToUser#calcChanged(isac.wsdialog.CalcChangedEvent)
   175 	 */
   176 	public void calcChanged(CalcChangedEvent event) throws RemoteException {
   177 		logger_.fatal(" WS<-. . : calcChanged (unc="
   178 				+ event.getLastUnchangedFormula().toSMLString() + ", del="
   179 				+ event.getLastDeletedFormula().toSMLString() + ", gen="
   180 				+ event.getLastGeneratedFormula().toSMLString());
   181 		try {
   182 			for (int i = 0; i < datachange_listeners_.size(); i++) {
   183 				((IToUser) datachange_listeners_.elementAt(i))
   184 						.calcChanged(event);
   185 				//WN050511->AK?LK? ^^^^^^^^^ cast to DialogIterators ?
   186 			}
   187 		} catch (Exception e) {
   188 			e.printStackTrace();
   189 		}
   190 	}
   191 
   192 	/**
   193 	 * the <code>Dialog#iterator</code> calls methods upon the
   194 	 * <code>CalcTree#iterator</code> eg. in <code>getFormula</code>.
   195 	 * 
   196 	 * @param CalcIterator
   197 	 *            which causes the construction
   198 	 * 
   199 	 * @see isac.wsdialog.IToCalc#iterator()
   200 	 */
   201 	public ICalcIterator iterator(ICalcIterator it) {
   202 		//WN050512
   203 		//		try {
   204 		//			return new DialogIterator((CalcIterator) calc_tree_.iterator(),
   205 		//			//.......................(it, this);
   206 		//					this);
   207 		//		} catch (Exception e) {
   208 		//			e.printStackTrace();
   209 		//		}
   210 		//		return null;
   211 		try {
   212 			return new DialogIterator((CalcIterator) it, (DGuide) this);
   213 		} catch (RemoteException e) {
   214 			// TODO Auto-generated catch block
   215 			e.printStackTrace();
   216 		}
   217 		return null;
   218 	}
   219 
   220 	/**
   221 	 * @see isac.wsdialog.IToCalc#addListener(isac.wsdialog.IToUser)
   222 	 */
   223 	public boolean addDataChangeListener(IToUser listener)
   224 			throws RemoteException {
   225 		if (datachange_listeners_.contains(listener)) {
   226 			return false;
   227 		} else {
   228 			datachange_listeners_.add(listener);
   229 		}
   230 		return true;
   231 	}
   232 
   233 	public boolean registerUIControlListener(IToWorksheet listener)
   234 			throws RemoteException {
   235 		//WN0504 ???
   236 		//		if (ui_control_listener_ != null) {
   237 		//			ui_control_listener_.doUIAction(new UserAction(UI_DO_DETACH));
   238 		//		}
   239 		ui_control_listener_ = listener;
   240 		return true;
   241 	}
   242 
   243 	//	/**
   244 	//	 * @see isac.wsdialog.IToCalc#fetchProposedTactic
   245 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   246 	//	 */
   247 	//	public Tactic fetchProposedTactic() {
   248 	//		return calc_tree_.fetchProposedTactic();
   249 	//	}
   250 	//
   251 	//
   252 	//	/**
   253 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   254 	//	 */
   255 	//	public int setNextTactic(Tactic tactic) {
   256 	//		return calc_tree_.setNextTactic(tactic);
   257 	//	}
   258 	//
   259 	//	/**
   260 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   261 	//	 */
   262 	//	public int autoCalculate(int scope, int nSteps) {
   263 	//		return calc_tree_.autoCalculate(scope, nSteps);
   264 	//	}
   265 	//
   266 	//	/**
   267 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   268 	//	 */
   269 	//	public void tryMatch(CalcHead ch, CalcHeadCompoundID problemID)
   270 	//			throws NotInSpecificationPhaseException {
   271 	//
   272 	//		// MathEngine.getMathEngine().tryMatch(ch, problemID);
   273 	//		math_engine_.tryMatch(ch, problemID);
   274 	//	}
   275 	//
   276 	//	/**
   277 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   278 	//	 */
   279 	//	public void tryRefine(CalcHead ch, CalcHeadCompoundID problemID)
   280 	//			throws NotInSpecificationPhaseException {
   281 	//
   282 	//		// MathEngine.getMathEngine().tryRefine(ch , problemID);
   283 	//		math_engine_.tryRefine(ch, problemID);
   284 	//	}
   285 	//
   286 	//	/**
   287 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   288 	//	 */
   289 	//	public ICalcIterator getActiveFormula() {
   290 	//		return calc_tree_.getActiveFormula();
   291 	//	}
   292 	//
   293 	//	/**
   294 	//	 * @throws RemoteException
   295 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   296 	//	 */
   297 	//	public int replaceFormula(CalcFormula newFormula) throws RemoteException
   298 	// {
   299 	//		return calc_tree_.replaceFormula(newFormula);
   300 	//	}
   301 	//
   302 	//	/**
   303 	//	 * @throws RemoteException
   304 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   305 	//	 */
   306 	//	public int appendFormula(CalcFormula newFormula) throws RemoteException {
   307 	//		return calc_tree_.appendFormula(newFormula);
   308 	//	}
   309 	//
   310 	//	/**
   311 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   312 	//	 */
   313 	//	public void moveActiveFormula(ICalcIterator newActiveFormula) {
   314 	//		calc_tree_.moveActiveFormula(newActiveFormula);
   315 	//	}
   316 	//
   317 	/**
   318 	 * Notify the Dialog Guide about interaction from the User
   319 	 * 
   320 	 * @param action
   321 	 * @return true, if the action has been processed, false if the processing
   322 	 *         the action has been denied
   323 	 * @throws RemoteException
   324 	 *  
   325 	 */
   326 	public boolean notifyUserAction(IUserAction action)
   327 			throws DialogProtocolException, RemoteException {
   328 		int request = action.getActionID();
   329 		logger_.fatal(" WS->DG: notifyUserAction request= " + request);
   330 
   331 		// two userActions dont care about the dialogphase
   332 		//WN050420 would be nicer, if DialogGuide would set the Buttons
   333 		switch (request) {
   334 		case (UI_CALCULATE_1):
   335 			if (phase_ == DIALOGPHASE_SPECIFY)
   336 				request = UI_SPECIFY_TO_SOLVE;//WN#####################
   337 			else
   338 				request = UI_SOLVE_CALCULATE_1;
   339 			break;
   340 		case (UI_CALCULATE_ALL):
   341 			if (phase_ == DIALOGPHASE_SPECIFY)
   342 				request = UI_SPECIFY_CALCULATE_ALL;
   343 			else
   344 				request = UI_SOLVE_CALCULATE_ALL;
   345 		}
   346 		// all other userActions belong to a certain dialogphase
   347 
   348 		switch (phase_) {
   349 		case DIALOGPHASE_IDLE:
   350 			throw new DialogProtocolException(request, phase_);
   351 		case DIALOGPHASE_SPECIFY:
   352 			if (request < UI_DUMMY_FIRST_SPECIFY
   353 					|| request > UI_DUMMY_LAST_SPECIFY)
   354 				throw new DialogProtocolException(request, phase_);
   355 			break;
   356 		case DIALOGPHASE_SOLVE:
   357 			if (request < UI_DUMMY_FIRST_SOLVE || request > UI_DUMMY_LAST_SOLVE)
   358 				throw new DialogProtocolException(request, phase_);
   359 			break;
   360 		}
   361 
   362 		//*********** handle IUserAction's **********************
   363 		CalcHead calc_head = new CalcHead();//WN0502023?????????
   364 		try {
   365 			calc_head = (CalcHead) calc_tree_.iterator().getFormula();
   366 		} catch (Exception e) {
   367 			e.printStackTrace();
   368 		}
   369 		switch (request) {
   370 		case UI_SPECIFY_TRY_MATCH:
   371 			throw new DialogNotImplementedException(request, phase_);
   372 		//			try {
   373 		//				tryMatch(calc_head, ((UserActionOnCalcHeadCompoundID) action)
   374 		//						.getObjectID());
   375 		//			} catch (NotInSpecificationPhaseException e) {
   376 		//				throw new DialogMathException(request, phase_, e);
   377 		//			}
   378 		//			break;
   379 
   380 		case UI_SPECIFY_TRY_REFINE:
   381 			throw new DialogNotImplementedException(request, phase_);
   382 		//			try {
   383 		//				tryRefine(calc_head, ((UserActionOnCalcHeadCompoundID) action)
   384 		//						.getObjectID());
   385 		//			} catch (NotInSpecificationPhaseException e) {
   386 		//				throw new DialogMathException(request, phase_, e);
   387 		//			}
   388 		//			break;
   389 
   390 		case UI_SPECIFY_CHANGE_VIEW:
   391 			calc_head.setViewStyle(((UserActionOnInt) action).getInt());
   392 			break;
   393 
   394 		case UI_SPECIFY_COMPLETE_CALCHEAD:
   395 			calc_tree_.completeCalcHead();
   396 			// old-style filling the fields of the calc-head by setting
   397 			// the HELP_ME flag
   398 			// calc_head_.setCalcHeadStatus(CalcHead.MODEL_ITEM_HELP_ME);
   399 			// modifyCalcHead(calc_head_);
   400 			break;
   401 		case UI_SPECIFY_COMPLETE_METHOD:
   402 		case UI_SPECIFY_COMPLETE_THEORY:
   403 		case UI_SPECIFY_COMPLETE_PROBLEM:
   404 		case UI_SPECIFY_COMPLETE_GIVEN:
   405 		case UI_SPECIFY_COMPLETE_FIND:
   406 		case UI_SPECIFY_COMPLETE_RELATE:
   407 			throw new DialogNotImplementedException(request, phase_);
   408 
   409 		case UI_SPECIFY_CHECK_CALCHEAD:
   410 			calc_tree_.modifyCalcHead(calc_head);
   411 			break;
   412 
   413 		// was: startCalculation() WN050428 ? really ?
   414 		case UI_SPECIFY_TO_SOLVE:
   415 		case UI_SPECIFY_CALCULATE_ALL:
   416 			//if (user_settings_.getValue(""))
   417 			if (true)
   418 				calc_tree_.completeCalcHead();
   419 			else
   420 				calc_tree_.modifyCalcHead(calc_head);
   421 
   422 			if (calc_head.getCalcHeadStatus() != CalcHead.MODEL_ITEM_CORRECT)
   423 				return false;
   424 
   425 			try {
   426 				calc_tree_.startSolving();
   427 			} catch (Exception e) {
   428 				// TODO Auto-generated catch block
   429 				e.printStackTrace();
   430 			}
   431 			// calc_tree_ = MathEngine.getMathEngine().startSolving(calcHead);
   432 			// FIXME: AK020224: do not register with the calc_tree_ if finished
   433 			// specifying a SUBPROBLEM
   434 			//calc_tree_.addDataChangeListener(this);//WN050420-->startCalculation
   435 
   436 			phase_ = DIALOGPHASE_SOLVE;//FIXXXME.WN050428
   437 		// fall through to calculate
   438 
   439 		case UI_SOLVE_CALCULATE_1:
   440 		//WN050420 why not at (*) here ?
   441 		case UI_SOLVE_CALCULATE_ALL:
   442 			switch (request) {
   443 			case UI_SPECIFY_CALCULATE_ALL:
   444 			case UI_SOLVE_CALCULATE_ALL:
   445 				calc_tree_.autoCalculate(IToCalc.SCOPE_CALCULATION, 0);
   446 				break;
   447 			case UI_SPECIFY_TO_SOLVE://WN050420 ???
   448 			// break;
   449 			default:
   450 				calc_tree_.autoCalculate(IToCalc.SCOPE_CALCULATION, 1);
   451 				//why not at (*) above ?
   452 				break;
   453 			}
   454 			break;
   455 
   456 		case UI_SOLVE_CALCULATE_SUBPROBLEM:
   457 			calc_tree_.autoCalculate(IToCalc.SCOPE_SUBPROBLEM, 0);
   458 			break;
   459 
   460 		case UI_SOLVE_EDIT_ACTIVE_FORMULA:
   461 			ui_control_listener_.doUIAction(new UserAction(UI_DO_EDIT_FORMULA));
   462 			break;
   463 
   464 		case UI_SOLVE_EDIT_ACTIVE_FORMULA_COMPLETE:
   465 			CalcFormula formula = (CalcFormula) ((UserActionOnCalcElement) action)
   466 					.getCalcElement();
   467 			// if the position is null, the formula did not exist, so we try to
   468 			// append a new formula
   469 			if (formula.getPosition() == null) {
   470 				calc_tree_.appendFormula(formula);
   471 			} else {
   472 				calc_tree_.replaceFormula(formula);
   473 			}
   474 			break;
   475 
   476 		case UI_SOLVE_APPEND_USER_FORMULA:
   477 			// appendFormula((Formula) ((UserActionOnCalcElement)
   478 			// action).getCalcElement());
   479 			ui_control_listener_
   480 					.doUIAction(new UserAction(UI_DO_APPEND_FORMULA));
   481 			break;
   482 
   483 		case UI_SOLVE_MOVE_ACTIVE_FORMULA:
   484 			calc_tree_.moveActiveFormula(((UserActionOnIterator) action)
   485 					.getPosition());
   486 			break;
   487 
   488 		case UI_SOLVE_GET_PROPOSED_TACTIC:
   489 			throw new DialogNotImplementedException(request, phase_);
   490 
   491 		case UI_SOLVE_GET_APPLICABLE_TACTICS:
   492 			throw new DialogNotImplementedException(request, phase_);
   493 
   494 		case UI_SOLVE_SET_NEXT_TACTIC:
   495 			calc_tree_
   496 					.setNextTactic((Tactic) ((UserActionOnCalcElement) action)
   497 							.getCalcElement());
   498 			//WN041126 extracted from isac.bridge.CalcTree#setNextTactic @@@
   499 			//autoCalculate(SCOPE_CALCULATION, 1);
   500 			break;
   501 
   502 		case UI_SOLVE_HELP_ENTERING_FORMULA:
   503 			throw new DialogNotImplementedException(request, phase_);
   504 
   505 		case UI_SOLVE_SHOW_ASSUMPTIONS:
   506 			throw new DialogNotImplementedException(request, phase_);
   507 
   508 		case UI_SOLVE_SHOW_DETAILS:
   509 			throw new DialogNotImplementedException(request, phase_);
   510 
   511 		default:
   512 			throw new DialogUnknownActionException(request, phase_);
   513 		}
   514 		return true;
   515 	}
   516 
   517 	private void rmiBind() {
   518 		if (System.getSecurityManager() == null) {
   519 			System.setSecurityManager(new RMISecurityManager());
   520 		}
   521 
   522 		try {
   523 			LocateRegistry.createRegistry(1099);
   524 		} catch (java.rmi.RemoteException exc2) {
   525 			System.err.println("can not create registry: " + exc2.getMessage());
   526 		}
   527 
   528 		String name = "//localhost/isac-DialogGuide";
   529 		try {
   530 			System.out.println("try to bind as " + name);
   531 			Naming.rebind(name, this);
   532 			System.out.println("Dialog Guide bound to " + name);
   533 			//WN040906 was Object Manager ...
   534 		} catch (java.rmi.ConnectException e) {
   535 			System.err.println("failed to contact as " + name
   536 					+ " (creating RMI-Server on localhost: 1099)");
   537 		} catch (RemoteException e) {
   538 			// TODO Auto-generated catch block
   539 			e.printStackTrace();
   540 		} catch (MalformedURLException e) {
   541 			// TODO Auto-generated catch block
   542 			e.printStackTrace();
   543 		}
   544 	}
   545 
   546 	//	public static void main(String[] args) {
   547 	//		try {
   548 	//			new DialogGuide(args[0]);
   549 	//
   550 	//		} catch (RemoteException e) {
   551 	//			e.printStackTrace();
   552 	//		}
   553 	//	}
   554 
   555 	//	/**
   556 	//	 * @see
   557 	// isac.util.interfaces.IToCalc#completeCalcHead(isac.util.formulae.CalcHead)
   558 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   559 	//	 */
   560 	//	public void completeCalcHead(CalcHead calcHead) {
   561 	//		// TODO Auto-generated method stub
   562 	//
   563 	//	}
   564 	//
   565 	//	/**
   566 	//	 * @see
   567 	// isac.util.interfaces.IToCalc#completeCalcHead(isac.util.formulae.CalcHead,
   568 	//	 * int)
   569 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   570 	//	 */
   571 	//	public void completeCalcHead(CalcHead calcHead, int completeItem) {
   572 	//		// TODO Auto-generated method stub
   573 	//
   574 	//	}
   575 	//
   576 	//	/**
   577 	//	 * (non-Javadoc)
   578 	//	 *
   579 	//	 * @see isac.util.interfaces.IToCalc#completeCalcHead()
   580 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   581 	//	 */
   582 	//	public void completeCalcHead() throws RemoteException {
   583 	//		// TODO Auto-generated method stub WN050223
   584 	//
   585 	//	}
   586 	//
   587 	//	/**
   588 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   589 	//	 *
   590 	//	 * @see
   591 	// isac.util.interfaces.IToCalc#intermediateSteps(isac.util.interfaces.ICalcIterator)
   592 	//	 */
   593 	//	public int intermediateSteps(ICalcIterator i) throws RemoteException {
   594 	//		// TODO Auto-generated method stub
   595 	//		return 0;
   596 	//	}
   597 	//
   598 	//	/**
   599 	//	 * @see
   600 	// isac.util.interfaces.IToCalc#getElementsFromTo(isac.util.interfaces.ICalcIterator,
   601 	//	 * isac.util.interfaces.ICalcIterator, java.lang.Integer, boolean)
   602 	//	 * @deprecated Use {@link #notifyUserAction(IUserAction)}instead
   603 	//	 */
   604 	//	public Vector getElementsFromTo(ICalcIterator iterator_from,
   605 	//			ICalcIterator iterator_to, Integer level,
   606 	//			boolean result_includes_tactics) throws RemoteException {
   607 	//		// TODO Auto-generated method stub
   608 	//		return null;
   609 	//	}
   610 
   611 }