1PMTYPESTR(3)               Library Functions Manual               PMTYPESTR(3)
2
3
4

NAME

6       pmTypeStr,  pmTypeStr_r  -  convert  a  performance  metric type into a
7       string
8

C SYNOPSIS

10       #include <pcp/pmapi.h>
11
12       const char *pmTypeStr(int type);
13       char *pmTypeStr_r(int type, char *buf, int buflen);
14
15       cc ... -lpcp
16

DESCRIPTION

18       Given a performance metric  type,  pmTypeStr  produces  a  terse  ASCII
19       equivalent,  appropriate for use in error and diagnostic messages.  The
20       pmTypeStr_r function does the same, but stores the result  in  a  user-
21       supplied  buffer  buf  of  length buflen, which should have room for at
22       least 20 bytes.
23
24       The value for type is typically extracted from a pmDesc structure, fol‐
25       lowing a call to pmLookupDesc(3) for a particular performance metric.
26
27       Examples  are  32  (for  type  equals PM_TYPE_32), U64 (for type equals
28       PM_TYPE_U64), STRING (for type equals PM_TYPE_STRING), etc.
29

NOTES

31       Both of these functions are safe to call from threaded contexts.
32

SEE ALSO

34       PMAPI(3),     pmAtomStr(3),     pmConvScale(3),      pmExtractValue(3),
35       pmLookupDesc(3),  pmPrintValue(3),  pmIDStr(3),  pmInDomStr(3),  pmSem‐
36       Str(3) and pmUnitsStr(3).
37
38
39
40Performance Co-Pilot                  PCP                         PMTYPESTR(3)
Impressum