using System.Collections.Generic;

namespace XmlForDB;

public class ParamDetailsInfoComparer : IEqualityComparer<ParamDetailsInfo>
{
	public bool Equals(ParamDetailsInfo x, ParamDetailsInfo y)
	{
		return (string.Compare(x.NodeDetailsRID, y.NodeDetailsRID, ignoreCase: true) == 0 && string.Compare(x.ParamRID, y.ParamRID, ignoreCase: true) == 0 && string.Compare(x.ParamAttributesRID, y.ParamAttributesRID, ignoreCase: true) == 0) ? true : false;
	}

	public int GetHashCode(ParamDetailsInfo obj)
	{
		return obj.NodeDetailsRID.ToLower().GetHashCode() + obj.ParamRID.ToLower().GetHashCode();
	}
}
