4 .BI "int netsnmp_ds_set_boolean(int " store ", int " which ", int " val ");"
11 into the bool_storage[store][which] slot. Returns
14 .IR store " and " which
15 parameters do not correspond to a valid slot, or
19 .BI "int netsnmp_ds_get_boolean(int " store ", int " which ");"
20 Returns 1 if bool_storage[store][which] is
22 or 0 if not. May also return
25 .IR store " and " which
26 parameters do not correspond to a valid slot.
28 .BI "int netsnmp_ds_set_string(int " store ", int " which ", const char *" val ");"
31 into the string_storage[store][which] slot. Returns
36 .IR store " and " which
37 parameters do not correspond to a valid slot.
39 .BI "char *netsnmp_ds_get_string(int " store ", int " which ");"
40 Returns the string which has been stored in the
41 string_storage[store][which] slot, or
44 .IR store " and " which
45 parameters do not correspond to a valid slot.
47 .BI "netsnmp_ds_set_int(int " store ", int " which ", int " val ");"
50 into the int_storage[store][which] slot. Returns
53 .IR store " and " which
54 parameters do not correspond to a valid slot, or
58 .BI "int netsnmp_ds_get_int(int " store ", int " which ");"
59 Returns the integer which has been stored in the
60 int_storage[store][which] slot, or
63 .IR store " and " which
64 parameters do not correspond to a valid slot.
66 .BI "void netsnmp_ds_shutdown(void);"
67 Reclaims memory used to hold information gathered by
68 .BR netsnmp_ds_register_config " and " netsnmp_ds_register_premib .
70 .BI "int netsnmp_ds_register_config(u_char " type ", const char *" ftype ", const char *" token ", int " store ", int " which ");"
71 Registers a configuration file directive
74 a default storage type and slot. Specifically,
78 indicate the storage slot in the data type indicated by
82 is one of the following constants:
83 .BR ASN_BOOLEAN ", " ASN_INTEGER ", or " ASN_OCTET_STR .
86 variable indicates the file name base string searched for the
88 keyword. For example, the following call:
91 netsnmp_ds_register_config(ASN_INTEGER, "snmp", "testtoken", DS_APPLICATION_ID, 5)
94 would indicate that when the snmp.conf file(s) were found and parsed,
95 that any line beginning with the word "testtoken" should be read and
96 the value after "testtoken" should be stored into the
97 int_storage[DS_APPLICATION_ID][5] slot. For example the following
98 line in the configuration file:
104 would set int_storage[DS_APPLICATION_ID][5] = 502. This function returns
106 if the registration was made successfully, or
108 if the registration was not made (perhaps because the
109 .IR store " and " which
110 parameters do not correspond to a valid slot, or because of a memory
113 .BI "int netsnmp_ds_register_premib(u_char " type ", const char *" ftype ", const char *" token ", int " store ", int " which ");"
114 Analogous to the preceeding function, but the
116 is processed before MIBs are read (this is therefore useful for controlling
117 MIB processing options).
119 .BR snmp_config "(5), " read_config "(3)"