internal static int BitDecodeResourceModelIndex(uint handle, int bitIndex) { var index = Bits.BitDecodeNoneable(handle, bitIndex, kResourceModelBitMask); Contract.Assert(IsValidResourceModelIndex(index)); return(index); }
internal static int BitDecodeLanguageIndex(uint handle, int bitIndex) { var index = Bits.BitDecodeNoneable(handle, bitIndex, kLanguageIndexBitMask); Contract.Assert(IsValidLanguageIndex(index)); return(index); }
internal static int BitDecodeIndex(uint handle, int bitIndex) { var index = Bits.BitDecodeNoneable(handle, bitIndex, kIndexBitMask); Contract.Assert(index.IsNoneOrPositive()); return(index); }
internal static int BitDecodeIndex(uint handle, int bitIndex) { var index = Bits.BitDecodeNoneable(handle, bitIndex, kIndexBitMask); Contract.Assert(index.IsNoneOrPositive() && index < EngineRegistry.Engines.Count); return(index); }
/// <summary>Bit decode a value from this handle</summary> /// <param name="value">Value decoded from this handle</param> /// <param name="traits"></param> public void DecodeNoneable64(out long value, Bitwise.BitFieldTraits traits) { Contract.Requires <ArgumentException>(!traits.IsEmpty); value = (long)Bits.BitDecodeNoneable(mBits.u64, ref mBitIndex, traits.Bitmask64); }
/// <summary>Bit decode a value from this handle</summary> /// <param name="value">Value decoded from this handle</param> /// <param name="bitMask">Masking value for <paramref name="value"/></param> public void DecodeNoneable64(out long value, ulong bitMask) { Contract.Requires <ArgumentException>(bitMask != 0); value = (long)Bits.BitDecodeNoneable(mBits.u64, ref mBitIndex, bitMask); }
/// <summary>Bit decode a value from this handle</summary> /// <param name="value">Value decoded from this handle</param> /// <param name="traits"></param> public void DecodeNoneable32(out int value, Bitwise.BitFieldTraits traits) { Contract.Requires <ArgumentException>(!traits.IsEmpty); value = (int)Bits.BitDecodeNoneable(mBits.u64, ref mBitIndex, traits.Bitmask32); }
/// <summary>Bit decode a value from this handle</summary> /// <param name="value">Value decoded from this handle</param> /// <param name="bitMask">Masking value for <paramref name="value"/></param> public void DecodeNoneable32(out int value, uint bitMask) { Contract.Requires <ArgumentException>(bitMask != 0); value = (int)Bits.BitDecodeNoneable(mBits.u64, ref mBitIndex, bitMask); }