import { Obj } from './types'; declare const Transfer_base: ObjectConstructor; /** * A class to represent a receiver’s interaction with a single file * transfer offer within a batch. There is functionality here to * skip or accept offered files and either to spool the packet * payloads or to handle them yourself. */ declare class Transfer extends Transfer_base { _file_info: Obj; _file_offset: number; _send: Function; _end: Function; /** * Not called directly. */ constructor(fileInfo: Obj, offset: number, sendFunc: Function, endFunc: Function); /** * Send a (non-terminal) piece of the file. * * @param { number[] | Uint8Array } arrayLike - The bytes to send. */ send(arrayLike: number[] | Uint8Array): void; /** * Complete the file transfer. * * @param { number[] | Uint8Array } [arrayLike] - The last bytes to send. * * @return { Promise } Resolves when the receiver has indicated * acceptance of the end of the file transfer. */ end(arrayLike: number[] | Uint8Array | undefined): Promise; } export default Transfer;