Is there any way to convert a File object to MultiPartFile? So that I can send that object to methods that accept the objects of MultiPartFile
interface?
File myFile = new File("/path/to/the/file.txt")
MultiPartFile ....?
def (MultiPartFile file) {
def is = new BufferedInputStream(file.getInputStream())
//do something interesting with the stream
}