2 * Created on Oct 13, 2003
6 import isac.util.CalcChanged;
7 import isac.util.Formalization;
8 import isac.util.formulae.Assumption;
9 import isac.util.formulae.CalcHead;
10 import isac.util.formulae.CalcHeadCompoundID;
11 import isac.util.formulae.CalcFormula;
12 import isac.util.formulae.Position;
13 import isac.util.interfaces.ICalcElement;
14 import isac.util.interfaces.ICalcIterator;
15 import isac.util.tactics.Tactic;
17 import java.rmi.Remote;
18 import java.rmi.RemoteException;
19 import java.util.Vector;
22 * @author Richard Gradischnegg
24 * WN0422 here seems to be the key for simplifying the whole bridge.* drawbacks
25 * of the present implementation: # more complicated than necessary #
26 * JUnitTestCases require BridgeMain running # BridgeLogger cannot be made
27 * serializable, thus not accessible for writing by JUnitTestCases # ...
29 public interface IBridgeRMI extends Remote {
31 public int startCalculation(Formalization f) throws RemoteException;
33 public void modifyCalcHead(CalcHead calcHead) throws RemoteException;
35 public int setNextTactic(int calcTreeID, Tactic tactic)
36 throws RemoteException;
38 public Tactic fetchProposedTactic(int calcTreeID) throws RemoteException;
40 public Tactic[] fetchAppliableTactics(int calcTreeID, int scope)
41 throws RemoteException;
43 public void completeCalcHead(int calcTreeID) throws RemoteException;
45 public void completeCalcHead(int calcTreeID, CalcHead calcHead,
46 int completeItem) throws RemoteException;
48 public CalcChanged autoCalculate(int calcTreeID, int scope, int nSteps)
49 throws RemoteException;
51 public CalcChanged replaceFormula(int calcTreeID, CalcFormula f)
52 throws RemoteException;
54 public CalcChanged appendFormula(int id, CalcFormula f) throws RemoteException;
56 public Vector getElementsFromTo(int id, ICalcIterator iterator_from,
57 ICalcIterator iterator_to, Integer level,
58 boolean result_includes_tactics) throws RemoteException;
60 public int iterator(int calcTreeID) throws RemoteException;
62 public Position moveRoot(int calcTreeID, int iteratorID)
63 throws RemoteException;
65 //WN041208 late decision for 'interpretSML(moveUp 1 ([1,2,3],"Frm"))'
66 //WN041208 or 'interpretSML(moveActiveUp 1)' requires reduncancy here:
67 //WN041208 these 2 args are redundant: (1)vvvvvvvvvvv (2)vvvvvvvv
68 public Position moveUp(int calcTreeID, int iteratorID, Position p)
69 throws RemoteException;
71 public Position moveActiveFormula(int calcTreeID, Position p)
72 throws RemoteException;
74 public Position moveDown(int calcTreeID, int iteratorID, Position p)
75 throws RemoteException;
77 public Position moveLevelUp(int calcTreeID, int iteratorID, Position p)
78 throws RemoteException;
80 public Position moveLevelDown(int calcTreeID, int iteratorID, Position p)
81 throws RemoteException;
83 public Position moveCalcHead(int calcTreeID, int iteratorID, Position p)
84 throws RemoteException;
86 public boolean moveTactic(int calcTreeID, int iteratorID)
87 throws RemoteException;
89 public boolean moveFormula(int calcTreeID, int iteratorID)
90 throws RemoteException;
93 * @deprecated in favour of getFormula, getTactic, getAssumption
95 public ICalcElement getElement(int calcTreeID, Position p)
96 throws RemoteException;
98 public ICalcElement getFormula(int calcTreeID, Position p)
99 throws RemoteException;
101 public Tactic getTactic(int calcTreeID, int iteratorID)
102 throws RemoteException;
104 public Assumption getAssumption(int calcTreeID, int iteratorID)
105 throws RemoteException;
107 public void tryRefine(int calcTreeID, CalcHeadCompoundID problemID)
108 throws RemoteException;
110 public void tryMatch(int calcTreeID, CalcHeadCompoundID problemID)
111 throws RemoteException;
113 public boolean destruct(int calcTreeID) throws RemoteException;
115 public Vector saveCalcTree(int calcTreeID) throws RemoteException;
117 public int loadCalcTree(Vector v) throws RemoteException;