using System;
using System.Collections.Generic;
using System.Text;
namespace Heckel.EasyTools.Diagramming.Drawing{
[Serializable()]
public class NodeStatus
{
private string _nodeId = "";
public string NodeId
{
get { return _nodeId; }
set { _nodeId = value; }
}
private string _uniqueNodeId = "";
public string UniqueNodeId
{
get { return _uniqueNodeId; }
set { _uniqueNodeId = value; }
}
private int _xPosCurrent = -1;
public int XPosCurrent
{
get { return _xPosCurrent; }
set { _xPosCurrent = value; }
}
private int _yPosCurrent = -1;
public int YPosCurrent
{
get { return _yPosCurrent; }
set { _yPosCurrent = value; }
}
private int _xPosDestination = -1;
public int XPosDestination
{
get { return _xPosDestination; }
set { _xPosDestination = value; }
}
private int _yPosDestination = -1;
public int YPosDestination
{
get { return _yPosDestination; }
set { _yPosDestination = value; }
}
public int _speedOfMove = -1;
public int SpeedOfMove
{
get { return _speedOfMove; }
set { _speedOfMove = value; }
}
public bool HasErrors
{
get { return _errors.Count > 0; }
}
public bool HasWarnings
{
get { return _warnings.Count > 0; }
}
public bool HasInfo
{
get { return _info.Count > 0; }
}
public bool HasMoveInstructions
{
get { return (_xPosDestination > -1 || _yPosDestination > -1); }
}
private List<string> _errors = new List<string>();
public List<string> Errors
{
get { return _errors; }
set { _errors = value; }
}
private List<string> _warnings = new List<string>();
public List<string> Warnings
{
get { return _warnings; }
set { _warnings = value; }
}
private List<string> _info = new List<string>();
public List<string> Info
{
get { return _info; }
set { _info = value; }
}
public NodeStatus(string nodeId, string uniqueNodeId, int xPosCurrent, int yPosCurrent)
{
this._nodeId = nodeId;
this._uniqueNodeId = uniqueNodeId;
this._xPosCurrent = xPosCurrent;
this._yPosCurrent = yPosCurrent;
}
}
}
|