日期:2014-05-17 浏览次数:20839 次
/// <summary>
/// 保存配置信息到文件
/// </summary>
/// <param name="info"></param>
public void SaveCollectorInfoToFile(CollectorConfigDyna info)
{
try
{
FileStream fs = null;
if (File.Exists(inputConfigName))
{
File.Delete(inputConfigName);
}
fs = new FileStream(inputConfigName, FileMode.CreateNew, FileAccess.Write);
{
IFormatter formatter = new BinaryFormatter();
formatter.Serialize(fs, info);
}
fs.Dispose();
}
catch (Exception ex)
{ }
}
/// <summary>
&