SHARE
TWEET

Untitled

a guest Jan 21st, 2020 56 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. public long getFolderSize(File file, long size) {
  2.     if (file.isDirectory()) {
  3.         for (File child : file.listFiles()) {
  4.             size += child.length();
  5.             getFolderSize(child, size);
  6.         }
  7.     }
  8.     return size;
  9. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top