Contenues dans
Trouver plus de documentation
Ressources d'assistance comprises
| Télécharger cet ouvrage au format PDF
NAME
- netmgt_build_report - add a statistic to a report
SYNOPSIS
-
bool_t netmgt_build_report (
-
-
Netmgt_data * data,
bool_t * event);
DESCRIPTION
-
netmgt_build_report gets the current attribute value from the data statistic data and adds it to a report. If an event has occurred for this attribute, event will be set upon return.
- You should call this function once for each attribute in the group/table. Once all statistics are added (via repeated calls to this function), the agent should call netmgt_send_report(3N) to send the report to the rendezvous process.
- There are two methods available for reporting, each with its own strengths. The recommended method is to call netmgt_send_report(3N) only after all the attributes have been checked -- the entire report has been created. This is the most efficient use of network resources. However, it will fail if the total size of the report is larger than 6KB, which can happen for large tables. The other method is to call netmgt_send_report(3N) after each row has been checked. This second method will almost always work, but is not an efficient use of network resources and is discouraged unless the agent returns large reports. This restriction applies only to event reports.
INPUT ARGUMENTS
- Pointer to a structure that gets filled in with the following fields:
-
-
name
- attribute name.
-
-
type
- attribute type code, as defined in netmgt_arglist.h.
-
-
length
- attribute value length, in bytes.
-
-
value
- pointer to the attribute value buffer. The value's internal representation is described by type.
-
-
event
- event status buffer. If an event has occurred for this attribute, this flag will be set to TRUE; otherwise, it will be set to FALSE.
RETURN VALUE
- TRUE if successful, otherwise FALSE. Additionally, event is set to indicate if an event has occurred.
DIAGNOSTICS
- If FALSE is returned, global variable netmgt_error indicates the error. The caller can get the reason for the error with netmgt_fetch_error(3N).
FILES
-
netmgt_arglist.h
SEE ALSO
-
netmgt_fetch_error(3N), netmgt_send_report(3N)
|
|