src/java/isac/wsdialog/IUIElement.java
author wneuper
Sat, 11 Dec 2004 10:50:12 +0100
changeset 2003 e14cb86a1777
parent 1997 d250305b99c6
child 2009 b81731d6fe71
permissions -rw-r--r--
little code polished
     1 /*
     2  * Created on Dec 12, 2003
     3  */
     4 package isac.wsdialog;
     5 
     6 /**
     7  * @author Alan Krempler
     8  *
     9  * Constants describing interactions or request from the user
    10  */
    11 public interface IUIElement {
    12 	
    13 	/******************* NOTIFICATIONS: SPECIFYING PHASE ***********************/
    14 	
    15 	public static final int UI_DUMMY_FIRST_SPECIFY = 1;
    16 	/**
    17 	 * During the specifying phase,
    18 	 * try to match a problem type to the data entered so far
    19 	 * WN                     ////    ?items of the model entered so far
    20 	 */
    21 	public static final int UI_SPECIFY_TRY_MATCH = 1;
    22 
    23 	/**
    24 	 * During the specifying phase,
    25 	 * try to refine the problem type.
    26 	 * WN                        //// 
    27 	 */
    28 	public static final int UI_SPECIFY_TRY_REFINE = 2;
    29 	
    30 	/**
    31 	 * During the specifying phase,
    32 	 * change the view on the CalcHead.  
    33 	 */
    34 	public static final int UI_SPECIFY_CHANGE_VIEW = 3;
    35 
    36 	/**
    37 	 * During the specifying phase,
    38 	 * have the CalcHead completed by the math engine.   
    39 	 */
    40 	public static final int UI_SPECIFY_COMPLETE_CALCHEAD = 4;
    41 
    42 	/**
    43 	 * During the specifying phase,
    44 	 * have the Method field of the CalcHead completed by the math engine.   
    45 	 */
    46 	public static final int UI_SPECIFY_COMPLETE_METHOD = 5;
    47 
    48 	/**
    49 	 * During the specifying phase,
    50 	 * have the Theory field of the CalcHead completed by the math engine.   
    51 	 */
    52 	public static final int UI_SPECIFY_COMPLETE_THEORY = 6;
    53 
    54 	/**
    55 	 * During the specifying phase,
    56 	 * have the Problem field of the CalcHead completed by the math engine.   
    57 	 */
    58 	public static final int UI_SPECIFY_COMPLETE_PROBLEM = 7;
    59 
    60 	/**
    61 	 * During the specifying phase,
    62 	 * have the Given field of the CalcHead completed by the math engine.   
    63 	 */
    64 	public static final int UI_SPECIFY_COMPLETE_GIVEN = 8;
    65 
    66 	/**
    67 	 * During the specifying phase,
    68 	 * have the Find field of the CalcHead completed by the math engine.   
    69 	 */
    70 	public static final int UI_SPECIFY_COMPLETE_FIND = 9;
    71 	
    72 	/**
    73 	 * During the specifying phase,
    74 	 * have the Relate field of the CalcHead completed by the math engine.   
    75 	 */
    76 	public static final int UI_SPECIFY_COMPLETE_RELATE = 10;
    77 
    78 	/**
    79 	 * During the specifying phase,
    80 	 * have the CalcHead checked for completeness and consistency.   
    81 	 */
    82 	public static final int UI_SPECIFY_CHECK_CALCHEAD = 11;
    83 	
    84 	/**
    85 	 * Leave the specifying phase, enter the solving phase
    86 	 * and calculate the first step of the mathod.   
    87 	 */
    88 	public static final int UI_SPECIFY_CALCULATE_1 = 12;
    89 	
    90 	/**
    91 	 * Leave the specifying phase, enter the solving phase
    92 	 * and calculate until a final result is reached.   
    93 	 */
    94 	public static final int UI_SPECIFY_CALCULATE_ALL = 13;
    95 
    96 	public static final int UI_DUMMY_LAST_SPECIFY = 13;
    97 	
    98 	/******************* NOTIFICATIONS: SOLVING PHASE ***********************/
    99 
   100 	public static final int UI_DUMMY_FIRST_SOLVE = 21;
   101 
   102 	/**
   103 	 * During the solving phase,
   104 	 * calculate one more step.   
   105 	 */
   106 	public static final int UI_SOLVE_CALCULATE_1 = 21;
   107 	
   108 	/**
   109 	 * During the solving phase,
   110 	 * calculate until a final result is reached.   
   111 	 */
   112 	public static final int UI_SOLVE_CALCULATE_ALL = 22;
   113 
   114 	/**
   115 	 * During the solving phase,
   116 	 * calculate until the current subproblem is solved.   
   117 	 */
   118 	public static final int UI_SOLVE_CALCULATE_SUBPROBLEM = 23;
   119 
   120 	/**
   121 	 * During the solving phase,
   122 	 * request editing the currently active formula.
   123 	 * 
   124 	 * WN0412 If request is conceded, do @see UI_SOLVE_EDIT_ACTIVE_FORMULA_COMPLETE   
   125 	 */
   126 	public static final int UI_SOLVE_EDIT_ACTIVE_FORMULA = 24;
   127 
   128 	/**
   129 	 * During the solving phase,
   130 	 * notify that editing the currently active formula is finished.
   131 	 * This implies a request for updating the CalcTree. 
   132 	 */	
   133 	public static final int UI_SOLVE_EDIT_ACTIVE_FORMULA_COMPLETE = 25;
   134 	
   135 	/**
   136 	 * During the solving phase,
   137 	 * request inserting a new formula _after_ the currently active
   138 	 * formula, making the new formula the currently active formula.
   139 	 * WN0412: ???...
   140 	 * At present, this does not imply editing the formula and must
   141 	 * be requested in a separate step.  
   142 	 */	
   143 	public static final int UI_SOLVE_APPEND_USER_FORMULA = 26;
   144 	
   145 	/**
   146 	 * During the solving phase,
   147 	 * request making the referened formula the currently active
   148 	 * formula.
   149 	 */		
   150 	public static final int UI_SOLVE_MOVE_ACTIVE_FORMULA = 27;
   151 
   152 	/**
   153 	 * During the solving phase,
   154 	 * ask for the tactic the math engine would apply to the current formula.
   155 	 */	
   156 	public static final int UI_SOLVE_GET_PROPOSED_TACTIC = 30;
   157 
   158 	/**
   159 	 * During the solving phase,
   160 	 * ask for a list of tactics to the current formula.
   161 	 */	
   162 	public static final int UI_SOLVE_GET_APPLICABLE_TACTICS = 31;
   163 	
   164 	/**
   165 	 * During the solving phase,
   166 	 * set the tactic to be applied to the current formula.
   167 	 */	
   168 	public static final int UI_SOLVE_SET_NEXT_TACTIC = 32;
   169 	
   170 	/**
   171 	 * When entering a formula during the solving phase,
   172 	 * request help on entering the formula.
   173 	 */		
   174 	public static final int UI_SOLVE_HELP_ENTERING_FORMULA = 33;
   175 
   176 	/**
   177 	 * During the solving phase,
   178 	 * show which assumptions hold at the current point of calculation.
   179 	 */	
   180 	public static final int UI_SOLVE_SHOW_ASSUMPTIONS = 40;
   181 	
   182 	/**
   183 	 * During the solving phase,
   184 	 * request more detail about the currently referenced element.
   185 	 */		
   186 	public static final int UI_SOLVE_SHOW_DETAILS = 41;
   187 	
   188 	public static final int UI_DUMMY_LAST_SOLVE = 41;
   189 	
   190 	/******************* ACTIVE REQUESTS TO THE UI ***********************/
   191 
   192 	/**
   193 	 * Request editing the currently active formula.
   194 	 * DG distinguishes between SPECIFY and SOLVE;
   195 	 * thus could drop UI_SOLVE_EDIT_ACTIVE_FORMULA : int
   196 	 */
   197 	public static final int UI_DO_EDIT_FORMULA = 129;
   198 
   199 	/**
   200 	 * Request appending a new, empty formula.
   201 	 */	
   202 	public static final int UI_DO_APPEND_FORMULA = 130;
   203 	
   204 	/**
   205 	 * Activate an UI element.
   206 	 */
   207 	public static final int UI_DO_ACTIVATE = 131;
   208 	
   209 	/**
   210 	 * Deactivate an UI element.
   211 	 */
   212 	public static final int UI_DO_DEACTIVATE = 132;
   213 	
   214 	/**
   215 	 * The Dialog Guide has detached the listener and will
   216 	 * not send any more control requests.
   217 	 * If registered as a Data Change Listener, update notifications
   218 	 * will still arrive!
   219 	 */
   220 	public static final int UI_DO_DETACH = 133; //WN ??? Design ???
   221 }