차이
문서의 선택한 두 판 사이의 차이를 보여줍니다.
| 파일_다운로드시_한글_파일명_처리 [2024/02/12 09:34] – 만듦 koov | 파일_다운로드시_한글_파일명_처리 [2024/02/12 09:35] (현재) – koov | ||
|---|---|---|---|
| 줄 7: | 줄 7: | ||
| <WRAP prewrap> | <WRAP prewrap> | ||
| <code java> | <code java> | ||
| + | import java.io.File; | ||
| + | import java.io.FileInputStream; | ||
| + | import java.nio.charset.StandardCharsets; | ||
| + | import java.util.List; | ||
| + | |||
| + | import org.springframework.beans.factory.annotation.Autowired; | ||
| + | import org.springframework.http.ContentDisposition; | ||
| + | import org.springframework.http.HttpHeaders; | ||
| + | import org.springframework.http.MediaType; | ||
| + | import org.springframework.stereotype.Service; | ||
| + | import org.springframework.util.FileCopyUtils; | ||
| + | |||
| + | import jakarta.servlet.ServletOutputStream; | ||
| + | import jakarta.servlet.http.HttpServletResponse; | ||
| + | |||
| + | ... | ||
| + | |||
| + | |||
| String filePath = file.getFilePath(); | String filePath = file.getFilePath(); | ||
| String fileName = file.getFileName(); | String fileName = file.getFileName(); | ||