public static void main(String[] args) {
String str = "2019.05.14.测试.doc";
System.out.println(str.substring(0,str.lastIndexOf(".")));
}