using System;
namespace YariSoft.Utils{
[Serializable]
public class AgentInfo
{
#region Local variables
private bool _agentActive = true;
private bool _agentInput = false;
private string _ConfigFileName = "";
#endregion
#region Properties
public bool AgentActive
{
get{ return _agentActive; }
set{ this._agentActive = value; }
}
public bool AgentInput
{
get{ return this._agentInput; }
set{ this._agentInput = value; }
}
public string ConfigFileName
{
get{ return this._ConfigFileName; }
set{ this._ConfigFileName = value; }
}
#endregion
#region Constructor/Destructor
public AgentInfo()
{
}
#endregion
#region Public functions
public bool SaveToFile( String FileName )
{
return YariSoft.Utils.ConfigFile.SaveToFile( ref FileName, this, false );
}
public static AgentInfo LoadFromFile( string FileName )
{
AgentInfo result = ( AgentInfo )YariSoft.Utils.ConfigFile.LoadFromFile( ref FileName, false );
if( result == null ){
result = new AgentInfo();
}
return result;
}
#endregion
}
}
|