CyrusBuilt.MonoPi.BitSet.Set C# (CSharp) Метод

Set() публичный Метод

Sets the bit at the specified index to true.
/// cannot be less than zero. ///
public Set ( Int32 index ) : void
index System.Int32 /// The index of the bit to set. ///
Результат void
		public void Set(Int32 index) {
			if (index < 0) {
				throw new IndexOutOfRangeException("index cannot be less than zero.");
			}

			Int32 offset = WordIndex(index);
			this.ExpandTo(offset);
			this._bits[offset] |= (1L << index);  // Restores invariants.
			this.CheckInvariants();
		}

Same methods

BitSet::Set ( Int32 index, System.Boolean value ) : void
BitSet::Set ( Int32 from, Int32 to ) : void
BitSet::Set ( Int32 from, Int32 to, System.Boolean value ) : void