*snmp_set_valueretrieval* -- Specify the method how the SNMP values will be
returned

  bool snmp_set_valueretrieval(int method)~

{method} types SNMP_VALUE_LIBRARY The return values will be as returned by the
Net-SNMP library. SNMP_VALUE_PLAIN The return values will be the plain value
without the SNMP type hint. SNMP_VALUE_OBJECT The return values will be
objects with the properties "value" and "type", where the latter is one of the
SNMP_OCTET_STR, SNMP_COUNTER etc. constants.

Using |snmp_set_valueretrieval|

<?php >
   snmp_set_valueretrieval(SNMP_VALUE_LIBRARY);
   $ret = snmpget('localhost', 'public', 'IF-MIB::ifName.1');
   // $ret = "STRING: lo"
  
   snmp_set_valueretrieval(SNMP_VALUE_PLAIN);
   $ret = snmpget('localhost', 'public', 'IF-MIB::ifName.1');
   // $ret = "lo";
  
   snmp_set_valueretrieval(SNMP_VALUE_OBJECT);
   $ret = snmpget('localhost', 'public', 'IF-MIB::ifName.1');
   // stdClass Object
   // (
   //   [type] => 4        <-- SNMP_OCTET_STR, see constants
   //   [value] => lo
   // )
?>





|snmp_get_valueretrieval|

vim:ft=help:
