Package org.apache.commons.codec.net
Class Utils
java.lang.Object
org.apache.commons.codec.net.Utils
Utility methods for this package.
This class is immutable and thread-safe.
- Since:
- 1.4
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final int
Radix used in encoding and decoding. -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
RADIX
private static final int RADIXRadix used in encoding and decoding.- See Also:
-
-
Constructor Details
-
Utils
Utils()
-
-
Method Details
-
digit16
Returns the numeric value of the characterb
in radix 16.- Parameters:
b
- The byte to be converted.- Returns:
- The numeric value represented by the character in radix 16.
- Throws:
DecoderException
- Thrown when the byte is not valid perCharacter.digit(char,int)
-
hexDigit
static char hexDigit(int b) Returns the upper case hex digit of the lower 4 bits of the int.- Parameters:
b
- the input int- Returns:
- the upper case hex digit of the lower 4 bits of the int.
-