public static ulong GetLowestBitValue(ulong flags) { int lowestBit = LongFlags.GetLowestBitPosition(flags); return(lowestBit == 0 ? 0UL : 1UL << (lowestBit - 1)); }
public static ulong GetHighestBitValue(ulong flags) { int highestBit = LongFlags.GetHighestBitPosition(flags); return(highestBit == 0 ? 0UL : 1UL << (highestBit - 1)); }