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

8
LINES

< > BotCompany Repo | #1020671 // dm_resumeSendingFileToOtherMachine - also splits. warning: signed, but not encrypted

JavaX fragment (include)

1  
please include function dm_sendFileToOtherMachine.
2  
3  
svoid dm_resumeSendingFileToOtherMachine(File f, S computerID, S remotePath, long startFrom) {
4  
  for (LongRange r : chunks(startFrom, fileSize(f), dm_sendFileToOtherMachine_chunkSize)) {
5  
    print("Sending file chunk " + r + " of " + f + " to " + computerID + ":" + remotePath);
6  
    dm_evalOnOtherMachine(computerID, "saveBinaryFilePart_base64(fileRelativeToUserDir(" + quote(remotePath) + "), " + r.start + "L, " + quote(base64encode(loadBinaryFileChunk(f, r))) + ");");
7  
  }
8  
}

Author comment

Began life as a copy of #1020607

download  show line numbers  debug dex  old transpilations   

Travelled to 8 computer(s): bhatertpkbcr, cfunsshuasjs, gwrvuhgaqvyk, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1020671
Snippet name: dm_resumeSendingFileToOtherMachine - also splits. warning: signed, but not encrypted
Eternal ID of this version: #1020671/3
Text MD5: 921960dfbf0cd618edd667c4a6c0325c
Author: stefan
Category: javax / stefan's os
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-12-30 17:46:57
Source code size: 536 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 271 / 313
Version history: 2 change(s)
Referenced in: [show references]