C# Class NLight.Core.BinaryHelper

Contains useful functions for manipulating bits.
Datei anzeigen Open project: slorion/nlight

Public Methods

Method Description
Reverse ( long value, int significantBitCount ) : long

Reverses the number of significant bits specified.

RotateLeft ( int value, int count ) : int

Rotates the bits to the left.

RotateRight ( int value, int count ) : int

Rotates the bits to the right.

Method Details

Reverse() public static method

Reverses the number of significant bits specified.
public static Reverse ( long value, int significantBitCount ) : long
value long The value to reverse.
significantBitCount int The number of significant bits to reverse.
return long

RotateLeft() public static method

Rotates the bits to the left.
public static RotateLeft ( int value, int count ) : int
value int The value to rotate.
count int The number of bits to rotate.
return int

RotateRight() public static method

Rotates the bits to the right.
public static RotateRight ( int value, int count ) : int
value int The value to rotate.
count int The number of bits to rotate.
return int