Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
var mapping;
var oids = { foo: { x: 'bar' } };
_.each(oids, function (row, index) {
// driver.log.fatal(row.entPhysicalClass, this.snmp.get(row.entPhysicalClass));
mapping[index] = {
name: row.x
};
}, this);
/**
* Keep track of all elements in the system as a flat collection
* key is the oid index from the table
*/
interface MyNode {
name: string
}
interface Mapping{
[index: string] : MyNode
}
var mapping: Mapping;
var oids = {foo: {x:'bar'}};
_.each(oids, function(row ,index){
// driver.log.fatal(row.entPhysicalClass, this.snmp.get(row.entPhysicalClass));
mapping[index] = {
name: row.x
}
}, this)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.