Method Set
Set(BitArray, Int32)
Sets the bit at the given index
to true.
Declaration
public static void Set(this BitArray bits, int index)
Parameters
Type | Name | Description |
---|---|---|
BitArray | bits | The BitArray object. |
System.Int32 | index | The position to set to true. |
Set(BitArray, Int32, Int32, Boolean)
Sets the bit at the given index range to true.
Declaration
public static void Set(this BitArray bits, int fromIndex, int toIndex, bool value)
Parameters
Type | Name | Description |
---|---|---|
BitArray | bits | The BitArray object. |
System.Int32 | fromIndex | The start of the range to set(inclusive) |
System.Int32 | toIndex | The end of the range to set(exclusive) |
System.Boolean | value | the value to set to the range |
Set(BitArray, Int32, Int32)
Declaration
public static void Set(this BitArray bits, int startIdx, int endIdx)
Parameters
Type | Name | Description |
---|---|---|
BitArray | bits | |
System.Int32 | startIdx | |
System.Int32 | endIdx |