protected String createFile ( String dir , String fileName , byte [ ] content ) { String baseName = FilenameUtils . getBaseName ( fileName ) ; String ext = FilenameUtils . getExtension ( fileName ) ; String downloadedFile = FileUtil . saveToFile ( dir + baseName , ext , content ) ; return linkToFile ( downloadedFile ) ; }
Creates a file using the supplied content .