How do I rename a folder which contains files? The function moveFileTo says it can be used to move or rename a file, but will calling that on a folder (that contains files) work? Would I make a File object using the old path, then call this with the new path, and it will just work?
(Also, I am assuming that any File objects I am holding onto that reference the files inside the original folder will need to be re-created using their new path, right?)
Or, would it be better/simpler/safer to create the new folder, copy the Files I have in the old folder to the new folder, and then delete the old folder?