Created
August 7, 2018 09:55
-
-
Save Ikhiloya/76b9989e06ea9d4e46ac4a9d646fae85 to your computer and use it in GitHub Desktop.
A simple code to convert a multi[part file to an inputStream and extract contents from a multipart file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public void extractMultipartFile(MultipartFile file){ | |
| InputStream inputStream =file.getInputStream(); | |
| String originalFileName = file.getOriginalFilename(); | |
| String fileName = file.getName(); | |
| byte[] bytes = file.getBytes(); | |
| String contentType = file.getContentType(); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment