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

namespace skyscraper8.Docsis.AnnexC
{
	public class RangingHoldOffSupport
	{
		public RangingHoldOffSupport(byte a, byte b, byte c, byte d)
		{
			CmRangingClassIdExtension = a;
			CmRangingClassIdExtension <<= 8;
			CmRangingClassIdExtension += b;

			Cm = ((d & 0x01) != 0);
			ERouter = ((d & 0x02) != 0);
			EMtaOrEDva = ((d & 0x04) != 0);
			DsgEStb = ((d & 0x08) != 0);
		}

		public ushort CmRangingClassIdExtension { get; private set; }
		public bool Cm { get; }
		public bool ERouter { get; }
		public bool EMtaOrEDva { get; }
		public bool DsgEStb { get; }
	}
}
