java - Renaming a RandomAccessFile -
i have raf called data.bin , temporary raf called temp.bin.
data = new randomaccessfile("data.bin","rws"); temp = new randomaccessfile("temp.bin","rws");
the temp file data.bin file alter information in it. once im done altering temp file how change name of temp.bin data.bin , delete old data.bin?
ive seen things renaming files .renameto() , stuff apply randomaccessfile. , couldnt find method rafs
randomaccessfile not designed replace file class.
it designed allow reading writing more or less.
please use file class renaming.
Comments
Post a Comment