Package org.jf.util
Class NibbleUtils
java.lang.Object
org.jf.util.NibbleUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic intextractHighSignedNibble(int value) Extracts the high signed 4-bit nibble from the least significant byte of the given valuestatic intextractHighUnsignedNibble(int value) Extracts the high unsigned 4-bit nibble from the least significant byte of the given valuestatic intextractLowSignedNibble(int value) Extracts the low signed 4-bit nibble from the least significant byte of the given valuestatic intextractLowUnsignedNibble(int value) Extracts the low unsigned 4-bit nibble from the least significant byte of the given value
-
Constructor Details
-
NibbleUtils
public NibbleUtils()
-
-
Method Details
-
extractHighSignedNibble
public static int extractHighSignedNibble(int value) Extracts the high signed 4-bit nibble from the least significant byte of the given value- Parameters:
value- the value to extract the nibble from- Returns:
- the extracted signed nibble value
-
extractLowSignedNibble
public static int extractLowSignedNibble(int value) Extracts the low signed 4-bit nibble from the least significant byte of the given value- Parameters:
value- the value to extract the nibble from- Returns:
- the extracted signed nibble value
-
extractHighUnsignedNibble
public static int extractHighUnsignedNibble(int value) Extracts the high unsigned 4-bit nibble from the least significant byte of the given value- Parameters:
value- the value to extract the nibble from- Returns:
- the extracted unsigned nibble value
-
extractLowUnsignedNibble
public static int extractLowUnsignedNibble(int value) Extracts the low unsigned 4-bit nibble from the least significant byte of the given value- Parameters:
value- the value to extract the nibble from- Returns:
- the extracted unsigned nibble value
-