org.openmuc.openiec61850

## Class HexConverter

- java.lang.Object
- - org.openmuc.openiec61850.HexConverter

    public class HexConverter
    extends java.lang.Object

### Method Summary

All Methods Static Methods Concrete Methods
`static void` `appendHexString(byte b, java.lang.StringBuilder builder)`
`static void` `appendHexString(java.lang.StringBuilder builder, byte[] byteArray, int offset, int length)`
`static void` `appendShortHexString(byte b, java.lang.StringBuilder builder)`
`static void` `appendShortHexString(java.lang.StringBuilder builder, byte[] bytes, int offset, int length)`
`static byte[]` `fromShortHexString(java.lang.String shortHexString)`
`static java.lang.String` `toHexString(byte b)`
`static java.lang.String` `toHexString(byte[] bytes)`
`static java.lang.String` `toHexString(byte[] bytes, int offset, int length)`
`static java.lang.String` `toShortHexString(byte b)` Returns the byte as a hex string.
`static java.lang.String` `toShortHexString(byte[] bytes)`
`static java.lang.String` `toShortHexString(byte[] bytes, int offset, int length)`
`static java.lang.String` `toShortHexString(int i)` Returns the integer value as hex string filled with leading zeros.
`static java.lang.String` `toShortHexString(long l)` Returns the long value as hex string filled with leading zeros.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Method Detail

#### toHexString

    public static java.lang.String toHexString(byte b)

#### toHexString

    public static java.lang.String toHexString(byte[] bytes)

#### toHexString

    public static java.lang.String toHexString(byte[] bytes,
                                               int offset,
                                               int length)

#### toShortHexString

    public static java.lang.String toShortHexString(int i)

Returns the integer value as hex string filled with leading zeros. If you do not want leading zeros use Integer.toHexString(int i) instead.

Parameters:
  `i` - the integer value to be converted
Returns:
  the hex string

#### toShortHexString

    public static java.lang.String toShortHexString(long l)

Returns the long value as hex string filled with leading zeros. If you do not want leading zeros use Long.toHexString(long i) instead.

Parameters:
  `l` - the long value to be converted
Returns:
  the hex string

#### toShortHexString

    public static java.lang.String toShortHexString(byte b)

Returns the byte as a hex string. If b is less than 16 the hex string returned contains a leading zero.

Parameters:
  `b` - the byte to be converted
Returns:
  the byte as a hex string.

#### toShortHexString

    public static java.lang.String toShortHexString(byte[] bytes)

#### toShortHexString

    public static java.lang.String toShortHexString(byte[] bytes,
                                                    int offset,
                                                    int length)

#### fromShortHexString

    public static byte[] fromShortHexString(java.lang.String shortHexString)
                                     throws java.lang.NumberFormatException

Throws:
  `java.lang.NumberFormatException`

#### appendShortHexString

    public static void appendShortHexString(byte b,
                                            java.lang.StringBuilder builder)

#### appendShortHexString

    public static void appendShortHexString(java.lang.StringBuilder builder,
                                            byte[] bytes,
                                            int offset,
                                            int length)

#### appendHexString

    public static void appendHexString(byte b,
                                       java.lang.StringBuilder builder)

#### appendHexString

    public static void appendHexString(java.lang.StringBuilder builder,
                                       byte[] byteArray,
                                       int offset,
                                       int length)