mirror of
https://github.com/debauchee/barrier.git
synced 2025-07-13 14:47:41 +02:00
Refactored file assemble and send code #4601
This commit is contained in:
parent
1df566d241
commit
a81b88c730
12 changed files with 140 additions and 209 deletions
|
@ -141,15 +141,6 @@ public:
|
|||
*/
|
||||
void disconnect();
|
||||
|
||||
//! Clears the file buffer
|
||||
void clearReceivedFileData();
|
||||
|
||||
//! Set the expected size of receiving file
|
||||
void setExpectedFileSize(String data);
|
||||
|
||||
//! Received a chunk of file data
|
||||
void fileChunkReceived(String data);
|
||||
|
||||
//! Create a new thread and use it to send file to client
|
||||
void sendFileToClient(const char* filename);
|
||||
|
||||
|
@ -178,8 +169,11 @@ public:
|
|||
//! Return true if recieved file size is valid
|
||||
bool isReceivedFileSizeValid();
|
||||
|
||||
//! Return expected file size
|
||||
size_t getExpectedFileSize() { return m_expectedFileSize; }
|
||||
//! Return expected file data size
|
||||
size_t& getExpectedFileSize() { return m_expectedFileSize; }
|
||||
|
||||
//! Return received file data
|
||||
String& getReceivedFileData() { return m_receivedFileData; }
|
||||
|
||||
//@}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue