public final static String FORMAT_STRING = "yyyy-MM-dd HH:mm:ss"; public final static String FORMAT_STRING2 = "EEE MMM dd yyyy HH:mm:ss z"; public final static String[] REPLACE_STRING = new String[]{"GMT+0800", "GMT+08:00"}; public final static String SPLIT_STRING = "中国标准时间)"; public static String parseTimeZoneString dateString) { try { dateString = dateString.splitPattern.quoteSPLIT_STRING))[0].replaceREPLACE_STRING[0], REPLACE_STRING[1]); //转换为date SimpleDateFormat sf1 = new SimpleDateFormatFORMAT_STRING2, Locale.ENGLISH); Date date = sf1.parsedateString); return new SimpleDateFormatFORMAT_STRING).formatdate); } catch Exception e) { throw new RuntimeException"时间转化格式错误" + "[dateString=" + dateString + "]" + "[FORMAT_STRING=" + FORMAT_STRING + "]"); } }