1multiplexer(3) net-snmp multiplexer(3)
2
3
4
6 multiplexer - Splits mode requests into calls to different handlers.
7
8
9 Functions
10 netsnmp_mib_handler * netsnmp_get_multiplexer_handler
11 (netsnmp_mib_handler_methods *req)
12 returns a multiplixer handler given a netsnmp_mib_handler_methods
13 structure of subhandlers.
14 int netsnmp_multiplexer_helper_handler (netsnmp_mib_handler *handler,
15 netsnmp_handler_registration *reginfo, netsnmp_agent_request_info
16 *reqinfo, netsnmp_request_info *requests)
17 implements the multiplexer helper
18
20 Splits mode requests into calls to different handlers.
21
22 The multiplexer helper lets you split the calling chain depending on
23 the calling mode (get vs getnext vs set). Useful if you want different
24 routines to handle different aspects of SNMP requests, which is very
25 common for GET vs SET type actions.
26
27 Functionally:
28
29 1. GET requests call the get_method
30
31 2. GETNEXT requests call the getnext_method, or if not present, the
32 get_method.
33
34 3. GETBULK requests call the getbulk_method, or if not present, the
35 getnext_method, or if even that isn't present the get_method.
36
37 4. SET requests call the set_method, or if not present return a
38 SNMP_ERR_NOTWRITABLE error.
39
41 netsnmp_mib_handler* netsnmp_get_multiplexer_handler
42 (netsnmp_mib_handler_methods * req)
43 returns a multiplixer handler given a netsnmp_mib_handler_methods
44 structure of subhandlers.
45
46 Definition at line 33 of file multiplexer.c.
47
48 References netsnmp_mib_handler_s::myvoid, netsnmp_create_handler(),
49 netsnmp_multiplexer_helper_handler(), NULL, and snmp_log().
50
51 int netsnmp_multiplexer_helper_handler (netsnmp_mib_handler * handler,
52 netsnmp_handler_registration * reginfo, netsnmp_agent_request_info *
53 reqinfo, netsnmp_request_info * requests)
54 implements the multiplexer helper
55
56 Definition at line 54 of file multiplexer.c.
57
58 References netsnmp_agent_request_info_s::mode,
59 netsnmp_mib_handler_s::myvoid, netsnmp_call_handler(),
60 netsnmp_request_set_error_all(), and snmp_log().
61
62 Referenced by netsnmp_get_multiplexer_handler().
63
64
65
66Version 5.4 24 Nov 2006 multiplexer(3)