Libraryless. Click here for Pure Java version (14513L/101K).
1 | !7 |
2 | |
3 | sclass PrintBuffers extends DynBigNumber { |
4 | void start { |
5 | super.start(); |
6 | setDescription("PRINT BUFFERS"); |
7 | ownTimer(doEveryAndNow(5.0, r actualUpdate)); |
8 | } |
9 | |
10 | void actualUpdate { |
11 | Set<StringBuffer> set = asSet(allPrintBuffers()); |
12 | //totalByteSizeOfCharSequences(set) |
13 | long n = totalByteCapacityOfStringBuffers_generic(set); |
14 | setValue(toK(n) + " K, " + n2(set, "buffer")); |
15 | } |
16 | |
17 | JComponent visualize() { |
18 | ret withCenteredButtons(super.visualize(), |
19 | "Trim", r trimAllPrintBuffers, |
20 | "Clear", r clearAllPrintBuffers); |
21 | } |
22 | } |
Began life as a copy of #1016643
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: | #1016646 |
Snippet name: | Total Size Of Print Buffers |
Eternal ID of this version: | #1016646/7 |
Text MD5: | 6c4f5933086f45c791d39a368f8db000 |
Transpilation MD5: | c37139e7d1a8259716f087b70a48febb |
Author: | stefan |
Category: | javax / modules |
Type: | JavaX source code (Dynamic Module) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2018-12-22 20:28:43 |
Source code size: | 586 bytes / 22 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 435 / 566 |
Version history: | 6 change(s) |
Referenced in: | [show references] |