multipartFile设置获取OriginalFilename

multipartFile设置获取OriginalFilename

注:MockMultipartFile

    public MultipartFileResp xx(File file) {
           ...
            FileInputStream inputStream = new FileInputStream(file);
            MultipartFile multipartFile = new MockMultipartFile("File",file.getName(),"text/plain", inputStream);
            log.info("[test] getOriginalFilename={}",multipartFile.getOriginalFilename());
           ...
    }

MultipartFile

你可能感兴趣的:(multipartFile设置获取OriginalFilename)