public SubframeAllocation Decode(BitArrayInputStream input) { SubframeAllocation allocation = new SubframeAllocation(); allocation.InitDefaults(); input.ReadBit(); switch (input.ReadBits(1)) { case 0: allocation.oneframe = input.ReadBitString(6); return(allocation); case 1: input.skipUnreadedBits(); allocation.fourframes = input.ReadBitString(0x18); return(allocation); } throw new Exception(GetType().Name + ":NoChoice had been choose"); }
public SubframeAllocation Decode(BitArrayInputStream input) { SubframeAllocation allocation = new SubframeAllocation(); allocation.InitDefaults(); input.readBit(); switch (input.readBits(1)) { case 0: allocation.oneframe = input.readBitString(6); return allocation; case 1: input.skipUnreadedBits(); allocation.fourframes = input.readBitString(0x18); return allocation; } throw new Exception(GetType().Name + ":NoChoice had been choose"); }