C++ MonsterDoc:
UtThread

Home
Contact
Copyright
|| All Classes ||
||overview|| ||access|| ||inheritance|| ||descriptions||

Class Overview

This class extends the PowerPlant LThread class to allow a thread to be deleted by the DoForEach method. It needs to be a subclass of LThread to gain access to some of LThread's protected members.

Inheritance

This class is a subclass of PowerPlant's LThread class.

Requirements

This class requires the use of PowerPlant's LThread class.

Files

  • UtThread.h
  • UtThread.cp

||overview|| ||access|| ||inheritance|| ||descriptions||

Members by Access

public

typedef
bool (*UtThreadBoolIterator)(LThread&, void*);

This is the signature of the function that will be applied to each thread. The return value determines whether the thread is still valid. A return of false indicates that the thread should be removed from the PowerPlant's global thread queue.

static
void
DoForEach(
UtThreadBoolIterator proc,
void* arg
);

protected

static
LThread*
RemoveFromGlobalQueue(
QElemPtr inQElem,
QHdr volatile& ioQueue
);

static
void
AddToGlobalQueue(
LThread& inThread,
QHdr volatile& ioQueue
);

private

UtThread(
void
);

||overview|| ||access|| ||inheritance|| ||descriptions||

Members by Inheritance

statics

static
void
DoForEach(
UtThreadBoolIterator proc,
void* arg
);

static
LThread*
RemoveFromGlobalQueue(
QElemPtr inQElem,
QHdr volatile& ioQueue
);

static
void
AddToGlobalQueue(
LThread& inThread,
QHdr volatile& ioQueue
);

overrides

This class provides not overrides.

new virtuals

This class provides not new virtual functions.

||overview|| ||access|| ||inheritance|| ||descriptions||

Member Descriptions

DoForEach

This is a reimplementation of LThread's DoForEach. The only change is that a return value of the UtThreadBoolIterator determines whether the thread is put back on the global thread queue.

static
void
DoForEach(
UtThreadBoolIterator proc,
void* arg
);

proc
the procedure to apply to each thread
arg
passed as the second argument to the proc.

RemoveFromGloablQueue

A reimplementation of the private LThread method of the same name.

static
LThread*
RemoveFromGlobalQueue(
QElemPtr inQElem,
QHdr volatile& ioQueue
);

AddToGloablQueue

A reimplementation of the private LThread method of the same name.

static
void
AddToGlobalQueue(
LThread& inThread,
QHdr volatile& ioQueue
);

UtThread

The constructor for this class is unimplemented.

UtThread(
void
);


©1999-2004 Monsterworks

Last Modified: Monday, October 2, 2000