/// <summary> /// Sets the given option bit to the specified value. /// </summary> /// <param name="bit">Option bit.</param> /// <param name="value">Value</param> protected virtual void setOptionBit(SordListOptions bit, bool value) { if (value) { optionsVal |= bit; } else { optionsVal &= ~bit; } }
/// <summary> /// Returns wether the given bit is set or not /// </summary> /// <param name="bit">One of the constants defined in SordListOptions</param> /// <returns>True, if the option is on.</returns> protected virtual bool getOptionBit(SordListOptions bit) { return((optionsVal & bit) != 0); }