code: public static byte[] reverseArray(final byte[] nullableArrayToBeInverted) {
      if (nullableArrayToBeInverted != null && nullableArrayToBeInverted.length > 0) {
        int indexStart = 0;
        int indexEnd = nullableArrayToBeInverted.length - 1;
        while (indexStart < indexEnd) {
          final byte a = nullableArrayToBeInverted[indexStart];
          nullableArrayToBeInverted[indexStart] = nullableArrayToBeInverted[indexEnd];
          nullableArrayToBeInverted[indexEnd] = a;
          indexStart++;
          indexEnd--;
        }
      }
      return nullableArrayToBeInverted;
    }
docs: Reverse order of bytes in a byte array.
  
  @param nullableArrayToBeInverted a byte array which order must be reversed,
  it can be null
  @return the same array instance but with reversed byte order, null if the
  source array is null
  @since 1.1