웹 응용 프로그램을 작성 중입니다. 그리고 응용 프로그램에서 사용자의 임시 폴더 경로를 얻으려면 -PC & 잘 작동하지만 서버에 war 파일을 배포 할 때 사용자 PC 대신 서버의 임시 폴더 경로를 제공합니다. 하지만 내 목표는 사용자 PC를 얻는 것입니다 임시 폴더 경로. 이 내가 임시 폴더를 가져 오는 데 사용 무엇 : -임시 폴더 경로를 얻는 방법
String temppath=System.getProperty("java.io.tmpdir");
System.out.println("Temp path is "+System.getProperty("java.io.tmpdir"));
FileOutputStream fo = new FileOutputStream(temppath+"employee.ser");
ObjectOutputStream os = new ObjectOutputStream(fo);
이