home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 18 REXX
/
18-REXX.zip
/
rxpmpapi.zip
/
rxpmpapi.txt
< prev
next >
Wrap
Text File
|
1997-06-20
|
3KB
|
80 lines
This file describes how to install and use RXPMPAPI.DLL. See the file
README.TXT for a brief description of RXPMPAPI.DLL, its cost (or lack
there of), redistribution instructions, and the don't-come-after-me
disclaimer.
Installation
Put RXPMPAPI.DLL in a directory listed in your LIBPATH.
Using RXPMPAPI.DLL
The Rexx API consists of six functions. Four of the Rexx functions
mirror the C API functions described in PMPATROL.INF in your PM Patrol
directory. See that file for detailed descriptions of those
functions. The remaining two functions, RxDCFLoadFuncs and
RxDCFDropFuncs, allow quick loading/dropping of the functions into/out
of the Rexx namespace.
The names of the four main Rexx functions are formed by prefixing "Rx"
to the name of the corresponding C API function. For example, the
Rexx function RxDCFGetStats corresponds to the C function
DCFGetStats(). If the return value from the C function is Boolean,
the Rexx function returns a 0 or 1, which is the standard for Boolean
values in Rexx. If the return value from the C function is a return
code, such as DCF_INACTIVE_ERROR, the Rexx function returns that code
as a string, i.e. "DCF_INACTIVE_ERROR". With the exception of
DCFGetStats(), the parameters for the C API and the Rexx API are
identical.
1. RxDCFGetStats('dcfStats.' [, 'dcfpStats.'])
Retrieves the last set of real-time statistics
collected. The Rexx version of this function takes one or two
parameters.
The first parameter is a stem variable in which
to place the contents of the dcfstats structure, with the
exception of the pstatTbl field. See the file PMPAPI.H in the
PM Patrol directory for a description of the dcfstats
structure. Each field in the C structure is a valid tail for
the stem. For example, the upTimeSecs field in the C
structure can be accessed from the Rexx stem dcfStats. as
dcfStats.upTimeSecs.
The second parameter is a stem variable in which to place the
pstatTbl field of the dcfstats structure. The pstatTbl field
is an array of dcfpstats (see PMPAPI.H) structures. If the
stem used for the second parameter in the call to
RxDCFGetStats is 'dcfpStats.', then
dcfpStats.0 = # of elements in the array
= # of processes running
dcfpStats.1.pid = PID of first process
dcfpStats.1.ppis = parent PID of first process
...
dcfpStats.2.pid = PID of second process
...
(etc.)
See the file RXPMPTST.CMD for an example of using
RxDCFGetStats.
2. RxDCFUserDefined(buffer)
Sets the user-defined field of the PM Patrol status line to
buffer.
3. RxDCFVerify()
Verify the DCF is running.
4. RxPMPShutDown()
Shutdown PM Patrol and the DCF.
Darren Abbott
abbott@hiwaay.net