2011-09-29 18:14:46 +00:00
|
|
|
NUTSCAN_ADD_OPTION_TO_DEVICE(3)
|
|
|
|
===============================
|
|
|
|
|
|
|
|
NAME
|
|
|
|
----
|
|
|
|
|
|
|
|
nutscan_add_option_to_device - Add option data to the specified device.
|
|
|
|
|
|
|
|
SYNOPSIS
|
|
|
|
--------
|
|
|
|
|
|
|
|
#include <nut-scan.h>
|
|
|
|
|
2022-06-29 10:37:36 +00:00
|
|
|
void nutscan_add_option_to_device(
|
|
|
|
nutscan_device_t * device,
|
|
|
|
char * option_name,
|
|
|
|
char * value);
|
2011-09-29 18:14:46 +00:00
|
|
|
|
|
|
|
|
|
|
|
DESCRIPTION
|
|
|
|
-----------
|
|
|
|
|
|
|
|
The `nutscan_device_t` contains the following variables:
|
|
|
|
|
|
|
|
nutscan_device_type_t type;
|
2022-06-29 10:37:36 +00:00
|
|
|
char * driver;
|
|
|
|
char * port;
|
|
|
|
nutscan_options_t opt;
|
|
|
|
struct nutscan_device * prev;
|
|
|
|
struct nutscan_device * next;
|
2011-09-29 18:14:46 +00:00
|
|
|
|
2022-06-29 10:37:36 +00:00
|
|
|
This is a double linked list of device. Each device is described by
|
|
|
|
its `type`, its `driver` name, its `port` and any number of optional data.
|
2011-09-29 18:14:46 +00:00
|
|
|
|
2022-06-29 10:37:36 +00:00
|
|
|
The *nutscan_add_option_to_device()* adds an optional data in the
|
|
|
|
given device. Optional data are made of an 'option_name' and an
|
|
|
|
associated 'value'. Copies of 'option_name' and 'value' are stored
|
|
|
|
in the device, so the caller can safely free both of the original
|
|
|
|
strings used as arguments.
|
|
|
|
|
|
|
|
NOTES
|
|
|
|
-----
|
|
|
|
|
|
|
|
Technically, the function is currently defined in 'nutscan-device.h' file.
|
2011-09-29 18:14:46 +00:00
|
|
|
|
|
|
|
SEE ALSO
|
|
|
|
--------
|
2022-06-29 10:37:36 +00:00
|
|
|
|
|
|
|
linkman:nutscan_scan_usb[3], linkman:nutscan_scan_xml_http_range[3],
|
|
|
|
linkman:nutscan_scan_nut[3], linkman:nutscan_scan_avahi[3],
|
2011-09-29 18:14:46 +00:00
|
|
|
linkman:nutscan_scan_ipmi[3], linkman:nutscan_scan_snmp[3],
|
|
|
|
linkman:nutscan_display_ups_conf[3], linkman:nutscan_display_parsable[3],
|
|
|
|
linkman:nutscan_new_device[3], linkman:nutscan_free_device[3],
|
|
|
|
linkman:nutscan_add_device_to_device[3]
|