blob: 8ed81dd1a25b1fd33fd5840e917f24070b04d107 [file] [log] [blame]
.TH "instance" 3 "31 May 2012" "Version 5.5.2.rc2" "net-snmp" \" -*- nroff -*-
.ad l
.nh
.SH NAME
instance \-
.PP
Process individual MIB instances easily.
.SS "Functions"
.in +1c
.ti -1c
.RI "\fBnetsnmp_mib_handler\fP * \fBnetsnmp_get_instance_handler\fP (void)"
.br
.RI "\fICreates an instance helper handler, calls netsnmp_create_handler, which then could be registered, using \fBnetsnmp_register_handler()\fP. \fP"
.ti -1c
.RI "int \fBnetsnmp_register_instance\fP (\fBnetsnmp_handler_registration\fP *reginfo)"
.br
.RI "\fIThis function registers an instance helper handler, which is a way of registering an exact OID such that GENEXT requests are handled entirely by the helper. \fP"
.ti -1c
.RI "int \fBnetsnmp_register_read_only_instance\fP (\fBnetsnmp_handler_registration\fP *reginfo)"
.br
.RI "\fIThis function injects a 'read only' handler into the handler chain prior to serializing/registering the handler. \fP"
.ti -1c
.RI "int \fBnetsnmp_register_read_only_ulong_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, u_long *it, Netsnmp_Node_Handler *subhandler)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_ulong_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, u_long *it, Netsnmp_Node_Handler *subhandler)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_read_only_counter32_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, u_long *it, Netsnmp_Node_Handler *subhandler)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_read_only_long_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, long *it, Netsnmp_Node_Handler *subhandler)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_long_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, long *it, Netsnmp_Node_Handler *subhandler)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_read_only_uint_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, unsigned int *it, Netsnmp_Node_Handler *subhandler)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_uint_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, unsigned int *it, Netsnmp_Node_Handler *subhandler)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_read_only_int_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler *subhandler)"
.br
.ti -1c
.RI "int \fBregister_read_only_int_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler *subhandler)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_read_only_ulong_instance_context\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, u_long *it, Netsnmp_Node_Handler *subhandler, const char *contextName)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_ulong_instance_context\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, u_long *it, Netsnmp_Node_Handler *subhandler, const char *contextName)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_read_only_counter32_instance_context\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, u_long *it, Netsnmp_Node_Handler *subhandler, const char *contextName)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_read_only_long_instance_context\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, long *it, Netsnmp_Node_Handler *subhandler, const char *contextName)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_long_instance_context\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, long *it, Netsnmp_Node_Handler *subhandler, const char *contextName)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_int_instance_context\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler *subhandler, const char *contextName)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_read_only_int_instance_context\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler *subhandler, const char *contextName)"
.br
.ti -1c
.RI "int \fBregister_read_only_int_instance_context\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler *subhandler, const char *contextName)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_num_file_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, const char *file_name, int asn_type, int mode, Netsnmp_Node_Handler *subhandler, const char *contextName)"
.br
.ti -1c
.RI "int \fBnetsnmp_register_int_instance\fP (const char *name, const oid *reg_oid, size_t reg_oid_len, int *it, Netsnmp_Node_Handler *subhandler)"
.br
.RI "\fIThis function registers an int helper handler to a specified OID. \fP"
.ti -1c
.RI "int \fBnetsnmp_instance_ulong_handler\fP (\fBnetsnmp_mib_handler\fP *handler, \fBnetsnmp_handler_registration\fP *reginfo, \fBnetsnmp_agent_request_info\fP *reqinfo, \fBnetsnmp_request_info\fP *requests)"
.br
.ti -1c
.RI "int \fBnetsnmp_instance_counter32_handler\fP (\fBnetsnmp_mib_handler\fP *handler, \fBnetsnmp_handler_registration\fP *reginfo, \fBnetsnmp_agent_request_info\fP *reqinfo, \fBnetsnmp_request_info\fP *requests)"
.br
.ti -1c
.RI "int \fBnetsnmp_instance_long_handler\fP (\fBnetsnmp_mib_handler\fP *handler, \fBnetsnmp_handler_registration\fP *reginfo, \fBnetsnmp_agent_request_info\fP *reqinfo, \fBnetsnmp_request_info\fP *requests)"
.br
.ti -1c
.RI "int \fBnetsnmp_instance_int_handler\fP (\fBnetsnmp_mib_handler\fP *handler, \fBnetsnmp_handler_registration\fP *reginfo, \fBnetsnmp_agent_request_info\fP *reqinfo, \fBnetsnmp_request_info\fP *requests)"
.br
.ti -1c
.RI "int \fBnetsnmp_instance_num_file_handler\fP (\fBnetsnmp_mib_handler\fP *handler, \fBnetsnmp_handler_registration\fP *reginfo, \fBnetsnmp_agent_request_info\fP *reqinfo, \fBnetsnmp_request_info\fP *requests)"
.br
.ti -1c
.RI "int \fBnetsnmp_instance_uint_handler\fP (\fBnetsnmp_mib_handler\fP *handler, \fBnetsnmp_handler_registration\fP *reginfo, \fBnetsnmp_agent_request_info\fP *reqinfo, \fBnetsnmp_request_info\fP *requests)"
.br
.ti -1c
.RI "int \fBnetsnmp_instance_helper_handler\fP (\fBnetsnmp_mib_handler\fP *handler, \fBnetsnmp_handler_registration\fP *reginfo, \fBnetsnmp_agent_request_info\fP *reqinfo, \fBnetsnmp_request_info\fP *requests)"
.br
.in -1c
.SH "Detailed Description"
.PP
Process individual MIB instances easily.
.SH "Function Documentation"
.PP
.SS "\fBnetsnmp_mib_handler\fP* netsnmp_get_instance_handler (void)"
.PP
Creates an instance helper handler, calls netsnmp_create_handler, which then could be registered, using \fBnetsnmp_register_handler()\fP. \fBReturns:\fP
.RS 4
Returns a pointer to a netsnmp_mib_handler struct which contains the handler's name and the access method
.RE
.PP
.PP
Definition at line 49 of file instance.c.
.SS "int netsnmp_instance_counter32_handler (\fBnetsnmp_mib_handler\fP * handler, \fBnetsnmp_handler_registration\fP * reginfo, \fBnetsnmp_agent_request_info\fP * reqinfo, \fBnetsnmp_request_info\fP * requests)"\fBDeprecated\fP
.RS 4
This function is unused and scheduled for removal in Net-SNMP 5.6
.RE
.PP
.PP
Definition at line 572 of file instance.c.
.SS "int netsnmp_instance_int_handler (\fBnetsnmp_mib_handler\fP * handler, \fBnetsnmp_handler_registration\fP * reginfo, \fBnetsnmp_agent_request_info\fP * reqinfo, \fBnetsnmp_request_info\fP * requests)"\fBDeprecated\fP
.RS 4
This function is unused and scheduled for removal in Net-SNMP 5.6
.RE
.PP
.PP
Definition at line 689 of file instance.c.
.SS "int netsnmp_instance_long_handler (\fBnetsnmp_mib_handler\fP * handler, \fBnetsnmp_handler_registration\fP * reginfo, \fBnetsnmp_agent_request_info\fP * reqinfo, \fBnetsnmp_request_info\fP * requests)"\fBDeprecated\fP
.RS 4
This function is unused and scheduled for removal in Net-SNMP 5.6
.RE
.PP
.PP
Definition at line 611 of file instance.c.
.SS "int netsnmp_instance_num_file_handler (\fBnetsnmp_mib_handler\fP * handler, \fBnetsnmp_handler_registration\fP * reginfo, \fBnetsnmp_agent_request_info\fP * reqinfo, \fBnetsnmp_request_info\fP * requests)"
.PP
fall through
.PP
Definition at line 771 of file instance.c.
.SS "int netsnmp_instance_uint_handler (\fBnetsnmp_mib_handler\fP * handler, \fBnetsnmp_handler_registration\fP * reginfo, \fBnetsnmp_agent_request_info\fP * reqinfo, \fBnetsnmp_request_info\fP * requests)"\fBDeprecated\fP
.RS 4
This function is unused and scheduled for removal in Net-SNMP 5.6
.RE
.PP
.PP
Definition at line 905 of file instance.c.
.SS "int netsnmp_instance_ulong_handler (\fBnetsnmp_mib_handler\fP * handler, \fBnetsnmp_handler_registration\fP * reginfo, \fBnetsnmp_agent_request_info\fP * reqinfo, \fBnetsnmp_request_info\fP * requests)"\fBDeprecated\fP
.RS 4
This function is unused and scheduled for removal in Net-SNMP 5.6
.RE
.PP
.PP
Definition at line 492 of file instance.c.
.SS "int netsnmp_register_instance (\fBnetsnmp_handler_registration\fP * reginfo)"
.PP
This function registers an instance helper handler, which is a way of registering an exact OID such that GENEXT requests are handled entirely by the helper. First need to inject it into the calling chain of the handler defined by the netsnmp_handler_registration struct, reginfo. The new handler is injected at the top of the list and will be the new handler to be called first. This function also injects a serialize handler before actually calling netsnmp_register_handle, registering reginfo.
.PP
\fBParameters:\fP
.RS 4
\fIreginfo\fP a handler registration structure which could get created using netsnmp_create_handler_registration. Used to register an instance helper handler.
.RE
.PP
\fBReturns:\fP
.RS 4
MIB_REGISTERED_OK is returned if the registration was a success. Failures are MIB_REGISTRATION_FAILED and MIB_DUPLICATE_REGISTRATION.
.RE
.PP
.PP
\fBExamples: \fP
.in +1c
\fBdelayed_instance.c\fP.
.PP
Definition at line 74 of file instance.c.
.SS "int netsnmp_register_int_instance (const char * name, const oid * reg_oid, size_t reg_oid_len, int * it, Netsnmp_Node_Handler * subhandler)"
.PP
This function registers an int helper handler to a specified OID. \fBParameters:\fP
.RS 4
\fIname\fP the name used for registration pruposes.
.br
\fIreg_oid\fP the OID where you want to register your integer at
.br
\fIreg_oid_len\fP the length of the OID
.br
\fIit\fP the integer value to be registered during initialization
.br
\fIsubhandler\fP a handler to do whatever you want to do, otherwise use NULL to use the default int handler.
.RE
.PP
\fBReturns:\fP
.RS 4
MIB_REGISTERED_OK is returned if the registration was a success. Failures are MIB_REGISTRATION_FAILED and MIB_DUPLICATE_REGISTRATION.
.RE
.PP
.PP
Definition at line 475 of file instance.c.
.SS "int netsnmp_register_read_only_instance (\fBnetsnmp_handler_registration\fP * reginfo)"
.PP
This function injects a 'read only' handler into the handler chain prior to serializing/registering the handler. The only purpose of this 'read only' handler is to return an appropriate error for any requests passed to it in a SET mode. Inserting it into your handler chain will ensure you're never asked to perform a SET request so you can ignore those error conditions.
.PP
\fBParameters:\fP
.RS 4
\fIreginfo\fP a handler registration structure which could get created using netsnmp_create_handler_registration. Used to register a read only instance helper handler.
.RE
.PP
\fBReturns:\fP
.RS 4
MIB_REGISTERED_OK is returned if the registration was a success. Failures are MIB_REGISTRATION_FAILED and MIB_DUPLICATE_REGISTRATION.
.RE
.PP
.PP
Definition at line 101 of file instance.c.
.SH "Author"
.PP
Generated automatically by Doxygen for net-snmp from the source code.