Class DebugControlThread
- java.lang.Object
-
- org.apache.uima.collection.impl.cpm.engine.DebugControlThread
-
- All Implemented Interfaces:
java.lang.Runnable
public class DebugControlThread extends java.lang.Object implements java.lang.RunnableThe Class DebugControlThread.
-
-
Field Summary
Fields Modifier and Type Field Description private intcheckpointFrequencyThe checkpoint frequency.private CPMEnginecpmThe cpm.private java.lang.StringfileNameThe file name.private java.lang.ObjectlockForPauseThe lock for pause.private static java.lang.StringNOTFOUNDThe Constant NOTFOUND.private booleanpauseThe pause.private booleanstopThe stop.
-
Constructor Summary
Constructors Constructor Description DebugControlThread(CPMEngine aCpm, java.lang.String aFilename, int aCheckpointFrequency)Instantiates a new debug control thread.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddeleteCheckpoint()Delete checkpoint.java.lang.StringdoCheckpoint()Do checkpoint.booleanexists()Exists.private voidinterpretAndExecuteCommand(java.lang.String aCommand)Interpret and execute command.voidpause()Pause.voidresume()Resume.voidrun()voidstart()Start.voidstop()Stop.
-
-
-
Field Detail
-
NOTFOUND
private static final java.lang.String NOTFOUND
The Constant NOTFOUND.- See Also:
- Constant Field Values
-
fileName
private java.lang.String fileName
The file name.
-
stop
private volatile boolean stop
The stop.
-
checkpointFrequency
private int checkpointFrequency
The checkpoint frequency.
-
pause
private boolean pause
The pause.
-
lockForPause
private final java.lang.Object lockForPause
The lock for pause.
-
cpm
private CPMEngine cpm
The cpm.
-
-
Constructor Detail
-
DebugControlThread
public DebugControlThread(CPMEngine aCpm, java.lang.String aFilename, int aCheckpointFrequency)
Instantiates a new debug control thread.- Parameters:
aCpm- the a cpmaFilename- the a filenameaCheckpointFrequency- the a checkpoint frequency
-
-
Method Detail
-
start
public void start() throws java.lang.RuntimeExceptionStart.- Throws:
java.lang.RuntimeException- the runtime exception
-
stop
public void stop()
Stop.
-
run
public void run()
- Specified by:
runin interfacejava.lang.Runnable
-
interpretAndExecuteCommand
private void interpretAndExecuteCommand(java.lang.String aCommand)
Interpret and execute command.- Parameters:
aCommand- the a command
-
deleteCheckpoint
public void deleteCheckpoint()
Delete checkpoint.
-
pause
public void pause()
Pause.
-
resume
public void resume()
Resume.
-
doCheckpoint
public java.lang.String doCheckpoint()
Do checkpoint.- Returns:
- the string
-
exists
public boolean exists()
Exists.- Returns:
- true, if successful
-
-