Remote Systems
v6.4.1

com.ibm.etools.systems.dstore.core.miners.miner
Class MinerThread

java.lang.Object
  extended byjava.lang.Thread
      extended bycom.ibm.etools.systems.dstore.core.miners.miner.MinerThread
All Implemented Interfaces:
Runnable
Direct Known Subclasses:
CommandMinerThread

public abstract class MinerThread
extends Thread

MinerThread is a utility class used for doing threaded operations in a miner.


Field Summary
protected  boolean _isCancelled
           
static String Copyright
           
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
MinerThread()
          Constructor
 
Method Summary
abstract  void cleanupThread()
          Implement this method to provide any cleanup that is required after all the work is done.
abstract  boolean doThreadedWork()
          Implement this method to provide the work implementation of this thread.
abstract  void initializeThread()
          Implement this method to provide initialization of this thread.
 void run()
          runs the thread
 void stopThread()
          stops the thread
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

Copyright

public static final String Copyright
See Also:
Constant Field Values

_isCancelled

protected boolean _isCancelled
Constructor Detail

MinerThread

public MinerThread()
Constructor

Method Detail

stopThread

public void stopThread()
stops the thread


run

public void run()
runs the thread


initializeThread

public abstract void initializeThread()
Implement this method to provide initialization of this thread.


doThreadedWork

public abstract boolean doThreadedWork()
Implement this method to provide the work implementation of this thread. This method gets called periodically by the miner thread so te work done here must be atomic. Each time this is called a incremental unit of work should be done. Once all the work is done, true should be returned.

Returns:
true if all the work is done.

cleanupThread

public abstract void cleanupThread()
Implement this method to provide any cleanup that is required after all the work is done.


Remote Systems
v6.4.1

Copyright © 2005 IBM Corp. All Rights Reserved.

Note: This documentation is for part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.