Synesis Software

Resource Usage API
[Synesis Software UNIX Emulation for Win32]


Detailed Description

Resource usage functions and types.


Classes

struct  rusage
 Resource usage information structure. More...

Defines

#define RUSAGE_SELF   (0)
 Requests that rusage() provide information about the calling process.
#define RUSAGE_CHILDREN   (-1)
 Requests that rusage() provide information about child processes of the calling process.

Functions

int getrusage (int who, struct rusage *r_usage)
 Provide resource usage information.


Define Documentation

#define RUSAGE_CHILDREN   (-1)

Requests that rusage() provide information about child processes of the calling process.

Note:
This flag is not supported

#define RUSAGE_SELF   (0)

Requests that rusage() provide information about the calling process.

Referenced by getrusage().


Function Documentation

int getrusage ( int  who,
struct rusage r_usage 
)

Provide resource usage information.

Retrieves resource usage information about the given process(es).

Parameters:
who The process(es) about which the usage information is to be retrieved. One of RUSAGE_SELF or RUSAGE_CHILDREN.
r_usage Pointer to an rusage structure to receive the rusage information.
Note:
This implementation only supports the RUSAGE_SELF flag for the who parameter.

References errno_from_Win32(), rusage::ru_stime, rusage::ru_utime, RUSAGE_SELF, timeval::tv_sec, and timeval::tv_usec.


UNIX Emulation for Win32 Libraries documentation © Synesis Software Pty Ltd, 2002-2010