code: public static String getDateString(String format, Date date) {
          SimpleDateFormat sdf = new SimpleDateFormat(format);
          return sdf.format(date);
      }
docs: 根据传递的参数格式化日期
  
  @param format
  @param date