This is automatically generated documentation. Edit after the "COMMENTS" heading; changes to the main body will be lost.
SNMPVariableInfo -- Click element; assigns variable semantics to SNMP OIDs
SNMPVariableInfo(OID TYPE [HANDLER], ...)
SNMPVariableInfo sets up a correspondence between SNMP OIDs and Click handlers. When an element like SNMPTrapSource wants to generate an SNMP variable binding, it will call the handler specified by SNMPVariableInfo. Each argument specifies an SNMP OID and the SNMP type of the corresponding variable. Valid types are:
NULLmust be followed by HANDLER, a handler ID. When another element wants to discover that variable's value, SNMPVariableInfo will call the specified handler and parse its value. For example, consider this configuration fragment: ... -> c :: Counter -> ... SNMPVariableInfo(220.127.116.11.18.104.22.168 Counter32 c.count); The SNMP OID "22.214.171.124.126.96.36.199" has type Counter32, and its value corresponds to the
c.counthandler. When another element requests the value of "188.8.131.52.184.108.40.206.0", SNMPVariableInfo will call
c.count, parse its value, and return the corresponding unsigned integer. Note, in this example, that the other element requested "220.127.116.11.18.104.22.168.0". The final ".0" indicates that "22.214.171.124.126.96.36.199" is a scalar variable: Counter32 is a scalar type. This ".0" is required; searching for "188.8.131.52.184.108.40.206" will not work. SNMP variable definitions are global. They are not scoped by compound elements, for example.