code: static long getFiveBytesLong(byte[] buffer, int offset) {
          return (buffer[offset] & 0xffL) << 32 | (buffer[offset + 1] & 0xffL) << 24 | (buffer[offset + 2] & 0xffL) << 16
                  | (buffer[offset + 3] & 0xffL) << 8 | (buffer[offset + 4] & 0xffL);
      }
docs: Converts five bytes of a byte array to an unsigned long.
  <p/>
  The byte order is big-endian.
  
  @param buffer the byte array.
  @param offset the offset in the array.
  @return the long value.