Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove apache commons io #437

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

dominikl
Copy link
Member

@dominikl dominikl commented Apr 5, 2024

Equivalent to ome/omero-romio#14 . But currently still fails because of the commons.io dep of omero-blitz.

It uses these replacements:

FilenameUtils.getBaseName -> MoreFiles.getNameWithoutExtension
FilenameUtils.getName -> Path.getFileName
FilenameUtils.getPath -> Path.toString
FilenameUtils.concat -> Paths.get
FilenameUtils.getExtension -> MoreFiles.getFileExtension
FilenameUtils.isExtension -> MoreFiles.getFileExtension
FilenameUtils.removeExtension -> MoreFiles.getNameWithoutExtension
FilenameUtils.getPrefix -> Path.getRoot

FileUtils.byteCountToDisplaySize -> own impl in IOUtil  (Returns a human-readable version of the file size)
FileUtils.copyURLToFile -> Files.copy
FileUtils.sizeOfDirectory -> own impl in IOUtil  (Counts the size of a directory recursively)
FileUtils.forceMkdir -> Files.createDirectory
FileUtils.deleteDirectory ->  MoreFiles.deleteRecursively
FileUtils.copyFile -> Files.copy
FileUtils.copyFileToDirectory -> Files.copy
FileUtils.moveFileToDirectory -> Files.move
FileUtils.writeStringToFile -> Files.write
FileUtils.readFileToString -> Files.readLines

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant