Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

marf.util
Class ExpandedThreadGroup  view ExpandedThreadGroup download ExpandedThreadGroup.java

java.lang.Object
  extended byjava.lang.ThreadGroup
      extended bymarf.util.ExpandedThreadGroup
All Implemented Interfaces:
java.lang.Thread.UncaughtExceptionHandler

public class ExpandedThreadGroup
extends java.lang.ThreadGroup

Provides some useful extensions to java.lang.ThreadGroup one would normally expect to be in a "group".

Maintains local references to the group-belonging threads for extra group control in a form of a Vector.

$Id: ExpandedThreadGroup.java,v 1.10 2005/06/20 05:34:32 mokhov Exp $

Since:
0.3.0
Version:
$Revision: 1.10 $

Field Summary
protected  java.util.Vector oGroup
          Local refernces to the threads belonging to this group.
 
Fields inherited from class java.lang.ThreadGroup
 
Constructor Summary
ExpandedThreadGroup(ExpandedThreadGroup poParent, java.lang.String pstrName)
          Mimics parent's constructor.
ExpandedThreadGroup(java.lang.String pstrName)
          Mimics parent's constructor.
ExpandedThreadGroup(java.lang.ThreadGroup poParent, java.lang.String pstrName)
          ThreadGroup and name constructor inherited from the parent.
 
Method Summary
 void addThread(java.lang.Thread poThread)
          Adds specified thread to the local reference list.
 java.lang.Thread[] enumerate(boolean pbActiveThreads)
          Provides an enumeration that allocates a new array and populates it with currently active threads with ThreadGroup's enumerate().
static java.lang.String getMARFSourceCodeRevision()
          Retrieves class' revision.
 void join()
          Wait for all the threads in the group to terminate.
 void start()
          Starts all non-started threads in this group.
 
Methods inherited from class java.lang.ThreadGroup
activeCount, activeGroupCount, allowThreadSuspension, checkAccess, destroy, enumerate, enumerate, enumerate, enumerate, getMaxPriority, getName, getParent, interrupt, isDaemon, isDestroyed, list, parentOf, resume, setDaemon, setMaxPriority, stop, suspend, toString, uncaughtException
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

oGroup

protected java.util.Vector oGroup
Local refernces to the threads belonging to this group.

Constructor Detail

ExpandedThreadGroup

public ExpandedThreadGroup(java.lang.ThreadGroup poParent,
                           java.lang.String pstrName)
ThreadGroup and name constructor inherited from the parent.


ExpandedThreadGroup

public ExpandedThreadGroup(java.lang.String pstrName)
Mimics parent's constructor.


ExpandedThreadGroup

public ExpandedThreadGroup(ExpandedThreadGroup poParent,
                           java.lang.String pstrName)
Mimics parent's constructor.

Method Detail

start

public void start()
Starts all non-started threads in this group.


join

public void join()
          throws java.lang.InterruptedException
Wait for all the threads in the group to terminate.


enumerate

public java.lang.Thread[] enumerate(boolean pbActiveThreads)
Provides an enumeration that allocates a new array and populates it with currently active threads with ThreadGroup's enumerate().


addThread

public void addThread(java.lang.Thread poThread)
Adds specified thread to the local reference list.


getMARFSourceCodeRevision

public static java.lang.String getMARFSourceCodeRevision()
Retrieves class' revision.