using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using skyscraper5.Skyscraper.Plugins;

namespace skyscraper5.Dvb.Descriptors.Extension
{
	[SkyscraperPlugin]
	[ExtensionDescriptor(0x11,"PMT")]
    internal class _0x11_T2MIDescriptor : Dvb.ExtensionDescriptor
    {
        public _0x11_T2MIDescriptor(byte[] buffer)
        {
            T2MiStreamId = buffer[0] & 0x07;
            NumT2MiStreams = buffer[1] & 0x07;
            NumT2MiStreams++;
            PcrIscrCommonClockFlag = (buffer[2] & 0x01) != 0;
        }

        public int T2MiStreamId { get; private set; }
        public int NumT2MiStreams { get; private set; }
        public bool PcrIscrCommonClockFlag { get; private set; }
    }
}
