Package arcommon
Class MyThread
- java.lang.Object
-
- java.lang.Thread
-
- arcommon.MyThread
-
- All Implemented Interfaces:
java.lang.Runnable
- Direct Known Subclasses:
LineConnectionThread,LineServerThread,MyTimer
public abstract class MyThread extends java.lang.Thread
-
-
Field Summary
Fields Modifier and Type Field Description static intDEFAULT_TIMEOUT
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidafterLoop()protected voidbeforeLoop()voidblockUntilStopped()voidblockUntilStoppedWithTimeout()voidblockUntilStoppedWithTimeout(int timeoutTimeInMilliseconds)protected voiddoLoop()booleanisRequestedToStop()voidrequestToStop()voidrun()voidsetRequestedToStop(boolean prequestedToStop)-
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yield
-
-
-
-
Field Detail
-
DEFAULT_TIMEOUT
public static final int DEFAULT_TIMEOUT
- See Also:
- Constant Field Values
-
-
Method Detail
-
run
public void run()
- Specified by:
runin interfacejava.lang.Runnable- Overrides:
runin classjava.lang.Thread
-
beforeLoop
protected void beforeLoop()
-
doLoop
protected void doLoop()
-
afterLoop
protected void afterLoop()
-
blockUntilStoppedWithTimeout
public void blockUntilStoppedWithTimeout()
-
blockUntilStoppedWithTimeout
public void blockUntilStoppedWithTimeout(int timeoutTimeInMilliseconds)
-
blockUntilStopped
public void blockUntilStopped()
-
requestToStop
public void requestToStop()
-
isRequestedToStop
public boolean isRequestedToStop()
-
setRequestedToStop
public void setRequestedToStop(boolean prequestedToStop)
-
-