|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Object | +--TEDTM
| Constructor Summary | |
TEDTM()
|
|
TEDTM(boolean setInMiddle,
java.lang.StringBuffer alphabet,
java.lang.StringBuffer finalTape,
java.util.Vector finalRules,
TEDController controller)
Constructor This makes a new Turing Machine. |
|
| Method Summary | |
TEDTM |
copy()
copy() This method copies the TM object. |
java.lang.String |
getTapeCel(int x)
getTapeCel |
int |
getTapeHeadPos()
getTapeHeadPos Returns the current position of the tapehead. |
void |
halt()
halt Makes the Turing Machine halt. |
void |
initializeRules(java.util.Vector finalRules)
initializeRules Sets up the rules for a new Turing Machine. |
void |
initializeTape(java.lang.StringBuffer startingTape)
initializeTape Sets up the tape for a new Turing Machine. |
void |
ludicrousSpeed(java.io.PrintWriter printOut)
ludicrousSpeed Runs the Turing Machine at ludicrous speed. |
java.lang.StringBuffer |
makeSerialNumber()
makeSerialNumber() This method creates a serial number for this turing machine |
void |
run()
run Runs the Turing Machine at run speed, about 1 transition per second until we halt, or the user pushes the halt button. |
void |
runTransition()
runTransition This will execute one transition on the current Turing Machine and set itself up to run the next transition. |
void |
stepSpeed()
stepSpeed Runs the Turing Machine at step speed, only one transition. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public TEDTM(boolean setInMiddle,
java.lang.StringBuffer alphabet,
java.lang.StringBuffer finalTape,
java.util.Vector finalRules,
TEDController controller)
setInMiddle - whether or not the tape should start in the middle of the tape.finalTape - the parsed and validated input that was given to be the tape.finalRules - public TEDTM()
| Method Detail |
public void initializeTape(java.lang.StringBuffer startingTape)
startingTape - the input that was given to us in the constructorpublic void initializeRules(java.util.Vector finalRules)
startingTape - the input that was given to us in the constructorpublic int getTapeHeadPos()
public void stepSpeed()
public void run()
run in interface java.lang.Runnable
public void ludicrousSpeed(java.io.PrintWriter printOut)
throws java.io.IOException
public void runTransition()
public void halt()
public java.lang.String getTapeCel(int x)
x: - the cell of the tape which we want to getpublic java.lang.StringBuffer makeSerialNumber()
public TEDTM copy()
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||