I'm using net-snmp library (c/c++) to write the snmp trap sender. For basic object types, it's quite simple to add an object to the trap:
snmp_varlist_add_variable(notification_vars, MibName, length, MIBType, MIBValue, len);
Where 'MibName' being the OID, 'MIBValue' the value as a string and 'MIBType' the ASN type. Now, how to do this for an indexed table? Is there any support for this? How to add all the rows with their elements to the trap?
Or are there simpler alternatives to this?