private void LoadNetworkConfiguration() { CheckForBackupFile(); XmlSerializer backupSerializer = new XmlSerializer(_nodNetworkHelperData.GetType()); StreamReader backupFileReader = new StreamReader(BACKUP_FILE_NAME); try { _nodNetworkHelperData = (NodNetworkHelperData)backupSerializer.Deserialize(backupFileReader); } catch (Exception) { return; } finally { backupFileReader.Close(); backupFileReader.Dispose(); } }
public void Dispose() { if (_networkWatcher != null) { _networkWatcher.Dispose(); } _nodNetworkHelperData = null; }