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

NAME

6       QmcMetric - container for a metric and all its values
7

C++ SYNOPSIS

9       #include <pcp/pmc/Metric.h>
10
11       CC ... -lpcp_pmc -lpcp
12

DESCRIPTION

14       A  QmcMetric object is a container for a single metric and all its val‐
15       ues.
16
17       The QmcMetricValue structure is used to hold the instance index, values
18       and  errors of each instance.  In the case of a singular metric, a sin‐
19       gle QmcMetricValue object is used.
20
21       A QmcMetric object consists of a list of  QmcMetricValue  objects,  in‐
22       dexes  to  the  descriptors in the metric's QmcGroup and QmcContext and
23       flags to indicate if the instances are explicit  or  implicit,  and  if
24       only  active  metrics  are  required  after  QmcMetric::updateIndom  is
25       called.
26

CONSTRUCTORS

28       Metrics should be constructed through the  QmcGroup::addMetric  methods
29       as  this  will  ensure that the references to the metric's context, de‐
30       scriptor and instance domain are correctly initialized.
31

INSTANCES

33       For metrics with an instance domain it is possible to  add  and  remove
34       any instance, and also update the instance list to reflect changes in a
35       dynamic instance domain.
36
37       bool updateIndom();
38           Update the metric to include new instances.  This method will first
39           call  QmcContext::update to update the instance domain.  If the ac‐
40           tive flag is set in the QmcGroup::addMetric  call,  only  instances
41           will  exported  by the metric, otherwise the metric will export all
42           instances listed in the domain.
43
44           The ordering of instances may change as a result of this call.  In‐
45           stances  that  already existed will keep their current and previous
46           values and errors, even if they are in a different order.
47
48       int addInst(QString const& name);
49           Add the instance name to the metric.  If the instance does not  ex‐
50           ist  in  the  instance  domain,  a PMAPI(3) error will be returned.
51           This method ignores the value of the active flag set in the QmcMet‐
52           ric constructor.
53
54       void removeInst(uint_t index);
55           Remove the instance at position index from the metric.
56

DIAGNOSTICS

58       Error  messages are generated using pmprintf(3) but are not flushed. It
59       is the responsibility of the user to call pmflush(3) to output any mes‐
60       sages.
61
62       Additional diagnostics may be activated by adding the option pmc to the
63       global debugging specification, as described in pmSetDebug(3).
64

SEE ALSO

66       PMAPI(3), QMC(3),  QMC_Context(3),  QMC_Group(3),  pmflush(3)  and  pm‐
67       printf(3).
68
69
70
71Performance Co-Pilot                  SGI                         QMCMETRIC(3)
Impressum