Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

9
LINES

< > BotCompany Repo | #1031588 // print_tee - print line into console and StringBuilder

JavaX fragment (include) [tags: use-pretranspiled]

Transpiled version (2783L) is out of date.

svoid print_tee(Appendable buf, S prefix default "", O o) ctex {
  S s = combinePrintParameters(prefix, o);
  buf?.append(s + "\n"); // we prefer this over 2 calls, it's possibly atomic
  print(s);
}

svoid print_tee(StringBuilder buf) {
  print_tee(buf, "");
}

Author comment

Began life as a copy of #1010503

download  show line numbers  debug dex  old transpilations   

Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt

No comments. add comment

Snippet ID: #1031588
Snippet name: print_tee - print line into console and StringBuilder
Eternal ID of this version: #1031588/2
Text MD5: 82d48fd7d57bec87da43cff0b2009b44
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-06-22 07:15:55
Source code size: 271 bytes / 9 lines
Pitched / IR pitched: No / No
Views / Downloads: 107 / 152
Version history: 1 change(s)
Referenced in: [show references]