12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879 |
- package processor;
- import codeline.CodeLine.BackwardAction;
- public class ControlFlow {
- public static final int STEP_INTO = 0;
- public static final int STEP_OVER = 1;
- public static final int CALL = 2;
-
- private int status;
- private PseudoCodeNode function;
- private PseudoCodeNode jumpBack;
- private BackwardAction reverse;
-
-
- public ControlFlow( int status )
- {
- this.status = status;
- function = null;
- jumpBack = null;
- reverse = null;
- }
-
-
- public ControlFlow( PseudoCodeNode functionNode )
- {
- status = CALL;
- function = functionNode;
- jumpBack = null;
- reverse = null;
- }
-
-
-
- void setJumpBack( PseudoCodeNode jB )
- {
- jumpBack = jB;
- }
-
- void setBackwardAction( BackwardAction bka )
- {
- reverse = bka;
- }
-
- void backward( Memory m )
- {
- if( reverse != null )
- reverse.backward( m );
- }
-
- PseudoCodeNode getJumpBack()
- {
- return jumpBack;
- }
-
- PseudoCodeNode getFunction()
- {
- return function;
- }
-
- int getStatus()
- {
- return status;
- }
- }
|