BitMathIsPowerOfTwo(Int32) Method

Determines if the number is a power of 2.

Definition

Namespace: Gemstone
Assembly: Gemstone.Common (in Gemstone.Common.dll) Version: 1.0.158 -- Release Build+8af53c44e6ad1fac543a652d58b46c9843b74b64
public static bool IsPowerOfTwo(
	int value
)

Parameters

value  Int32
The value to check power of two properties.

Return Value

Boolean
true if value is a power of 2; otherwise, false.

Exceptions

ArgumentOutOfRangeExceptionIf is less than zero

See Also