class PosixThread


Full nameost::PosixThread
Definition#include <thread.h>
Inheritsost::Thread [public ]
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods

Protected Methods


Detailed Description

inline void  SignalParent (signo_t signo)

SignalParent

[protected]

In the Posix version of Common C++, this can be used to send a signal into the parent thread of the current object.

Parameters:
signoa posix signal id.

inline void  SignalMain (signo_t signo)

SignalMain

[protected]

In the Posix version of Common C++, this can be used to send a signal into the main application thread.

Parameters:
signoa posix signal id.

void  OnTimer (void)

OnTimer

[protected virtual]

A derivable method to call when a SIGALRM is being delivered to a specific thread.

void  OnHangup (void)

OnHangup

[protected virtual]

A derived method to handle hangup events being delivered to a specific thread.

void  OnException (void)

OnException

[protected virtual]

A derived method to call when a SIGABRT is being delivered to a specific thread.

void  OnDisconnect (void)

OnDisconnect

[protected virtual]

A derived method to call when a SIGPIPE is being delivered to a specific thread.

void  OnPolling (void)

OnPolling

[protected virtual]

A derived method to handle asynchronous I/O requests delivered to the specified thread.

void  OnSignal (int signo)

OnSignal

[protected virtual]

A derivable method to call for delivering a signal event to a specified thread.

Parameters:
signoposix signal id.

void  setTimer (timeout_t timer)

setTimer

[protected]

Used to specify a timeout event that can be delivered to the current thread via SIGALRM. When the timer expires, the OnTimer() method is called for the thread. At present, only one thread timer can be active at any given time. On some operating systems (including Linux) a timer can be active on each thread.

Parameters:
timertimeout in milliseconds.

timeout_t  getTimer (void)

getTimer

[protected]

Gets the time remaining for the current threads timer before it expires.

Returns: time remaining before timer expires in milliseconds.

void  endTimer (void)

endTimer

[protected]

Terminates the timer before the timeout period has expired. This prevents the timer from sending it's SIGALRM and makes the timer available to other threads.

void  WaitSignal (signo_t signo)

WaitSignal

[protected]

Used to wait on a Posix signal from another thread. This can be used as a crude rondevious/synchronization method between threads.

Parameters:
signoa posix signal id.

void  setSignal (int signo, bool mode)

setSignal

[protected]

Used to enable or disable a signal within the current thread.

Parameters:
signoposix signal id.
activeset to true to enable.

inline void  SignalThread (int signo)

SignalThread

Delivers a Posix signal to the current thread.

Parameters:
signoa posix signal id.

friend void  siginstall (int signo)

siginstall

Install a signal handler for use by threads and the OnSignal() event notification handler.

Parameters:
signoposix signal id.


Generated by: dyfet on home on Thu Jan 24 11:06:29 2002, using kdoc 2.0a53.