Nguyễn Cap Tuyến
New member
Is file empty Java?
Answer
Well, it’s pretty easy to check emptiness for a file in Java by using the length() method of the
java.io.File class. This method returns zero if the file is empty, but the good thing is it also returns zero if the file doesn’t exist.
Answer
Well, it’s pretty easy to check emptiness for a file in Java by using the length() method of the
java.io.File class. This method returns zero if the file is empty, but the good thing is it also returns zero if the file doesn’t exist.