public System.Collections.Generic.List <ValueMessage> GetMonitorValues(System.Collections.Generic.List <DevSnmpConfig> configs) { DevAccessCfg instance = DevAccessCfg.GetInstance(); System.Collections.Generic.List <SnmpConfiger> list = new System.Collections.Generic.List <SnmpConfiger>(); foreach (DevSnmpConfig current in configs) { DevModelConfig deviceModelConfig = instance.getDeviceModelConfig(current.modelName, current.fmwareVer); SnmpConfiger item = new SnmpConfiger(instance.getSnmpConfig(current), deviceModelConfig, current.devMac, current.devID); list.Add(item); } return(new DefaultSnmpExecutors(list).GetVaules()); }
public DevPortGroupAPI(System.Collections.Generic.List <DevSnmpConfig> devcfgs) { this.devsnmpconfigs = devcfgs; DevAccessCfg instance = DevAccessCfg.GetInstance(); foreach (DevSnmpConfig current in devcfgs) { DevModelConfig deviceModelConfig = instance.getDeviceModelConfig(current.modelName, current.fmwareVer); SnmpConfiger snmpConfiger = new SnmpConfiger(instance.getSnmpConfig(current), deviceModelConfig, current.devMac, current.devID); snmpConfiger.GroupOutlets = current.groupOutlets; this.snmpConfigs.Add(snmpConfiger); } this.se = new DefaultSnmpExecutors(this.snmpConfigs); }
public void SetTrapReceiver(System.Collections.Generic.List <DevSnmpConfig> configs, Sys_Para pSys) { DevAccessCfg instance = DevAccessCfg.GetInstance(); System.Collections.Generic.List <SnmpConfiger> list = new System.Collections.Generic.List <SnmpConfiger>(); foreach (DevSnmpConfig current in configs) { DevModelConfig deviceModelConfig = instance.getDeviceModelConfig(current.modelName, current.fmwareVer); SnmpConfiger item = new SnmpConfiger(instance.getSnmpConfig(current), deviceModelConfig, current.devMac, current.devID); list.Add(item); } DefaultSnmpExecutors defaultSnmpExecutors = new DefaultSnmpExecutors(list); defaultSnmpExecutors.UpdateTrapReceiver(pSys, TrapEnabled.Yes); }
public System.Collections.Generic.List <ThresholdMessage> GetThresholdsEatonPDU_M2(System.Collections.Generic.List <DevSnmpConfig> configs) { DevAccessCfg instance = DevAccessCfg.GetInstance(); System.Collections.Generic.List <SnmpConfiger> list = new System.Collections.Generic.List <SnmpConfiger>(); foreach (DevSnmpConfig current in configs) { DevAccessAPI devAccessAPI = new DevAccessAPI(current); DevRealConfig eatonPDUNumber_M = devAccessAPI.GetEatonPDUNumber_M2(); DevModelConfig deviceModelConfig = instance.getDeviceModelConfig(current.modelName, current.fmwareVer); SnmpConfiger item = new SnmpConfiger(instance.getSnmpConfig(current), deviceModelConfig, current.devMac, current.devID, eatonPDUNumber_M); list.Add(item); } return(new DefaultSnmpExecutors(list).GetThresholdsEatonPDU_M2()); }
public System.Collections.Generic.List <ThresholdMessage> GetMonitorThresholds(System.Collections.Generic.List <DevSnmpConfig> configs) { DevAccessCfg instance = DevAccessCfg.GetInstance(); System.Collections.Generic.List <SnmpConfiger> list = new System.Collections.Generic.List <SnmpConfiger>(); foreach (DevSnmpConfig current in configs) { DevModelConfig deviceModelConfig = instance.getDeviceModelConfig(current.modelName, current.fmwareVer); SnmpConfiger item = new SnmpConfiger(instance.getSnmpConfig(current), deviceModelConfig, current.devMac, current.devID); list.Add(item); } DefaultSnmpExecutors defaultSnmpExecutors = new DefaultSnmpExecutors(list); System.Collections.Generic.List <ThresholdMessage> thresholds = defaultSnmpExecutors.GetThresholds(); this.retryConfigs = defaultSnmpExecutors.getRetryList(); return(thresholds); }