code: public static String convertMsToDate(long millis, String dateFormatPattern) {
      DateFormat dateFormat = new SimpleDateFormat(dateFormatPattern);
      return dateFormat.format(new Date(millis));
    }
docs: Converts a millisecond number to a formatted date String.
  
  @param millis a long millisecond number
  @param dateFormatPattern the date format to follow when converting. i.e. mm-dd-yyyy
  @return formatted date String