public static ErrorCorrectionLevel ForBits(int bits) { if (bits < 0 || bits >= FOR_BITS.Length) { throw new IndexOutOfRangeException(); } return FOR_BITS[bits]; } }
private FormatInformation(int formatInfo) { // Bits 3,4 errorCorrectionLevel = ErrorCorrectionLevel.ForBits((formatInfo >> 3) & 0x03); // Bottom 3 bits dataMask = (byte)(formatInfo & 0x07); }