//本地路径
String relativeSyncFilePath = "xxxxx";
//获取操作系统
Properties prop = System.getProperties();
String os = prop.getProperty("os.name");
//判断是不是windiws操作系统
if(os.startsWith("win") || os.startsWith("Win")){//windows操作系统,斜杠做转换
relativeSyncFilePath = relativeSyncFilePath.replaceAll("/", "\\\\");
}