FileRecvChunkCallback


Description:

[ CCode ( has_target = false ) ]
public delegate void FileRecvChunkCallback (Tox self, uint32 friend_number, uint32 file_number, uint64 position, uint8[] data, void* user_data)

When length is 0, the transfer is finished and the client should release the resources it acquired for the transfer. After a call with length = 0, the file number can be reused for new file transfers.

If position is equal to file_size (received in the file_receive callback) when the transfer finishes, the file was received completely. Otherwise, if file_size was UINT64_MAX, streaming ended successfully when length is 0.

Parameters:

friend_number

The friend number of the friend who is sending the file.

file_number

The friend-specific file number the data received is associated with.

position

The file position of the first byte in data.

data

A byte array containing the received chunk.