using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Aitex.Core.RT.IOCore
{
    public class IntlkNode
    {
        public int Index;
        public bool IoTypeIsDI; //True:DI   False:DO
        public bool IsReversed;

        public override int GetHashCode()
        {
            return string.Format("{0}_{1}_{2}", Index, IoTypeIsDI, IsReversed).ToString().GetHashCode();
        }

        public override bool Equals(object obj)
        {
            var o1 = obj as IntlkNode;
            if (o1 != null && o1.Index == Index && o1.IoTypeIsDI == IoTypeIsDI && o1.IsReversed == IsReversed)
                return true;
            return false;
        }
    }
}