Libraryless. Click here for Pure Java version (2052L/13K).
1 | static long guessClusteredDirSize(File dir, O... _) { |
2 | optPar O pred; // F1<File, Bool> |
3 | long n = 0; |
4 | long clusterSize = assumedClusterSize(); |
5 | for (File f : pred == null ? findAllFiles_noDirs(dir) : findAllFiles_noDirs_pred(dir, pred)) |
6 | n += roundUpTo(clusterSize, f.length()); |
7 | ret n; |
8 | } |
9 | |
10 | static long guessClusteredDirSize() { |
11 | ret guessClusteredDirSize(programDir()); |
12 | } |
Began life as a copy of #1001727
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1010166 |
Snippet name: | guessClusteredDirSize (assumes some cluster size); recurses |
Eternal ID of this version: | #1010166/7 |
Text MD5: | 85d86ee06599748ab0c9cb84aa7e2762 |
Transpilation MD5: | 23513dfdc7f955670214abbb85bbff0e |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-08-09 23:49:12 |
Source code size: | 391 bytes / 12 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 521 / 626 |
Version history: | 6 change(s) |
Referenced in: | [show references] |