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

8
LINES

< > BotCompany Repo | #1027353 // drainStreamToPrint_charByChar

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

Libraryless. Click here for Pure Java version (2199L/14K).

1  
svoid drainStreamToPrint_charByChar(InputStream stream, IF0<Bool> enabled) ctex {
2  
  InputStreamReader in = new(stream);
3  
  int c;
4  
  while ((c = in.read()) >= 0) {
5  
    if (enabled == null || enabled!)
6  
      print_noNewLine(str((char) c));
7  
  }
8  
}

download  show line numbers  debug dex  old transpilations   

Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv

No comments. add comment

Snippet ID: #1027353
Snippet name: drainStreamToPrint_charByChar
Eternal ID of this version: #1027353/3
Text MD5: dc55e79301c4c7c4e0e73d707a9cb1a3
Transpilation MD5: 1f2422059ef6753111280097d9dbe2db
Author: stefan
Category: javax / io
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2020-03-11 15:37:16
Source code size: 249 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 161 / 242
Version history: 2 change(s)
Referenced in: [show references]