Back to index

lightning-sunbird  0.9+nobinonly
Defines | Typedefs | Enumerations | Functions | Variables
prthread.h File Reference
#include "prtypes.h"
#include "prinrval.h"

Go to the source code of this file.

Defines

#define PR_CurrentThread()   PR_GetCurrentThread() /* for nspr1.0 compat. */

Typedefs

typedef
typedefPR_BEGIN_EXTERN_C
struct 
PRThread
typedef struct PRThreadStack
typedef enum PRThreadType PRThreadType
typedef enum PRThreadScope PRThreadScope
typedef enum PRThreadState PRThreadState
typedef enum PRThreadPriority PRThreadPriority
typedef void(PR_CALLBACKPRThreadPrivateDTOR )(void *priv)

Enumerations

enum  PRThreadType { PR_USER_THREAD, PR_SYSTEM_THREAD }
enum  PRThreadScope { PR_LOCAL_THREAD, PR_GLOBAL_THREAD, PR_GLOBAL_BOUND_THREAD }
enum  PRThreadState { PR_JOINABLE_THREAD, PR_UNJOINABLE_THREAD }
enum  PRThreadPriority {
  PR_PRIORITY_FIRST = 0, PR_PRIORITY_LOW = 0, PR_PRIORITY_NORMAL = 1, PR_PRIORITY_HIGH = 2,
  PR_PRIORITY_URGENT = 3, PR_PRIORITY_LAST = 3
}

Functions

 NSPR_API (PRThread *) PR_CreateThread(PRThreadType type
 void (PR_CALLBACK *start)(void *arg)
 nsModuleDestructorProc
 NSPR_API (PRStatus) PR_JoinThread(PRThread *thread)
 NSPR_API (PRThreadPriority) PR_GetThreadPriority(const PRThread *thread)
 NSPR_API (void) PR_SetThreadPriority(PRThread *thread
 Prototypes for machine dependent function implementations.
 NSPR_API (void *) PR_GetThreadPrivate(PRUintn tpdIndex)
 NSPR_API (PRThreadScope) PR_GetThreadScope(const PRThread *thread)
 NSPR_API (PRThreadType) PR_GetThreadType(const PRThread *thread)
 NSPR_API (PRThreadState) PR_GetThreadState(const PRThread *thread)

Variables

voidarg
void PRThreadPriority priority
void PRThreadPriority PRThreadScope scope
void PRThreadPriority
PRThreadScope PRThreadState 
state
void PRThreadPriority
PRThreadScope PRThreadState
PRUint32 
stackSize
PRThreadPrivateDTOR destructor
voidpriv

Define Documentation

#define PR_CurrentThread ( )    PR_GetCurrentThread() /* for nspr1.0 compat. */

Definition at line 166 of file prthread.h.


Typedef Documentation

typedef typedefPR_BEGIN_EXTERN_C struct PRThread

Definition at line 83 of file prthread.h.

Definition at line 203 of file prthread.h.

typedef struct PRThreadStack

Definition at line 84 of file prthread.h.

typedef enum PRThreadType PRThreadType

Enumeration Type Documentation

Enumerator:
PR_PRIORITY_FIRST 
PR_PRIORITY_LOW 
PR_PRIORITY_NORMAL 
PR_PRIORITY_HIGH 
PR_PRIORITY_URGENT 
PR_PRIORITY_LAST 

Definition at line 102 of file prthread.h.

{
    PR_PRIORITY_FIRST = 0,      /* just a placeholder */
    PR_PRIORITY_LOW = 0,        /* the lowest possible priority */
    PR_PRIORITY_NORMAL = 1,     /* most common expected priority */
    PR_PRIORITY_HIGH = 2,       /* slightly more aggressive scheduling */
    PR_PRIORITY_URGENT = 3,     /* it does little good to have more than one */
    PR_PRIORITY_LAST = 3        /* this is just a placeholder */
} PRThreadPriority;
Enumerator:
PR_LOCAL_THREAD 
PR_GLOBAL_THREAD 
PR_GLOBAL_BOUND_THREAD 

Definition at line 91 of file prthread.h.

Enumerator:
PR_JOINABLE_THREAD 
PR_UNJOINABLE_THREAD 

Definition at line 97 of file prthread.h.

Enumerator:
PR_USER_THREAD 
PR_SYSTEM_THREAD 

Definition at line 86 of file prthread.h.


Function Documentation

NSPR_API ( PRThread )
NSPR_API ( void  )

Prototypes for machine dependent function implementations.

(Too bad NSPR's MD system blows so much that we have to reiterate every stinking thing we implement here in our MD header file.)

NSPR_API ( void )
NSPR_API ( PRThreadScope  ) const
NSPR_API ( PRThreadType  ) const
NSPR_API ( PRThreadState  ) const
void ( PR_CALLBACK nsModuleDestructorProc)

nsModuleDestructorProc

This function is called when the module is being destroyed.

Parameters:
selfmodule which is being destroyed.

Variable Documentation

Definition at line 139 of file prthread.h.

Definition at line 206 of file prthread.h.

Definition at line 139 of file prthread.h.

Definition at line 219 of file prthread.h.

Definition at line 139 of file prthread.h.

Definition at line 139 of file prthread.h.

Definition at line 139 of file prthread.h.