private void Initialize() { m_controlTransformers = new List <VcTransformer>(); // need to initialize it m_controlCapacitorBanks = new List <VcCapacitorBank>(); m_substationInformation = new VcSubstationInfomation(); m_substationAlarmDevice = new VcSubstationAlarmDevice(); m_ltcStatus = new VcLtcStatus(); m_rawKeyValuePairs = new Dictionary <string, object>(); }
public static VcSubstationAlarmDevice DeserializeFromXml(string pathName) { try { VcSubstationAlarmDevice voltVarController = null; XmlSerializer deserializer = new XmlSerializer(typeof(VcSubstationAlarmDevice)); StreamReader reader = new StreamReader(pathName); voltVarController = (VcSubstationAlarmDevice)deserializer.Deserialize(reader); reader.Close(); return(voltVarController); } catch (Exception exception) { throw new Exception("Failed to Deserialzie"); } }