import { FileManager } from './fileManager.core';
import { Protocol } from './protocol.core';
import { hookType, UploaderHook } from './uploaderHook.core';
import { FileFilter } from './fileFilter.core';
import { FileManagerOptions, TransferOptions } from '../interface';
/**
 * An abstract class for the transport functionality
 *
 * @export
 * @abstract
 * @class Transfer
 */
export declare abstract class Transfer {
    type: string;
    options: TransferOptions;
    readonly id: any;
    readonly queue$: any;
    readonly queueObs: FileManager[];
    private _id;
    private _queue$;
    private _hooks;
    private _isHTML5;
    private _isDragAndDrop;
    private _protocol;
    /**
     * Creates an instance of Transfer.
     *
     * @param {string} type
     *
     * @memberOf Transfer
     */
    constructor(type: string, _options?: TransferOptions);
    /**
     * Bind options to FileManager
     *
     * @param {FileManagerOptions} _options
     *
     * @memberOf FileManager
     */
    bindOptions(_options: TransferOptions): void;
    /**
     * It gives HTML5 check back
     *
     * @returns {Boolean}
     *
     * @memberOf Transfer
     */
    isHTML5(): Boolean;
    /**
     * It gives DragAndDrop check back
     *
     * @returns {Boolean}
     *
     * @memberOf Transfer
     */
    isDragAndDrop(): Boolean;
    /**
     * To implement a hock
     *
     * @param {UploaderHook} hook
     *
     * @memberOf Transfer
     */
    hook(_hook: UploaderHook): void;
    /**
     *
     *
     * @param {UploaderHook} hook
     * @returns this
     *
     * @memberOf Transfer
     */
    removeHook(_hook: UploaderHook): boolean;
    addFilesToQueue(_files: any, options?: FileManagerOptions): FileManager[];
    addFile(_file: FileManager): boolean;
    removeFile(_file: FileManager): boolean;
    notInQueue(_file: FileManager): number;
    addFilter(_filter: FileFilter): void;
    validate(_file: FileManager): boolean;
    _setProtocol(_protocol: Protocol): void;
    _getProtocol(): Protocol;
    /**
     * Validate response status code.
     *
     * @param {number} status
     * @returns {boolean}
     *
     * @memberOf Protocol
     */
    _isSuccessCode(status: number): boolean;
    /**
     * Upload functions
     */
    upload(): void;
    cancel(): void;
    remove(): void;
    uploadItem(item: FileManager): void;
    cancelUploadItem(item: FileManager): void;
    /**
     * Overwrite functions
     */
    onAddFileAll(_uploader: Transfer): void;
    onAddFile(_file: FileManager): void;
    onAddFileError(_file: FileManager): void;
    onBeforeUploadAll(_uploader: Transfer): void;
    onBeforeUpload(_file: FileManager): void;
    onProgress(_uploader: Transfer, _progress: any): void;
    onProgressFile(_file: FileManager, _progress: number): void;
    onProgressFileSpeed(_file: FileManager, _progress: any): void;
    onSuccess(_file: FileManager, _response: any, _status: number, _headers: any): void;
    onError(_file: FileManager, _response: any, _status: number, _headers: any): void;
    onComplete(_file: FileManager, _response: any, _status: number, _headers: any): void;
    onCompleteAll(_uploader: Transfer): void;
    /**
     * Internal functions
     */
    /**
     *
     *
     * @param {FileManager} _file
     * @param {number} _progress
     * @returns {void}
     *
     * @memberOf FileManager
     */
    _onAddFileAll(): void;
    _onAddFile(_file: FileManager): void;
    _onAddFileError(_file: FileManager): void;
    _onBeforeUploadAll(): void;
    _onBeforeUpload(_file: FileManager): void;
    _onProgressFileSpeed(_file: FileManager, _speed: any): void;
    _onProgressFile(_file: FileManager, _progress: number): void;
    _onProgress(): void;
    _onSuccessFile(_file: FileManager, response: any, status: number, headers: any): void;
    _onErrorFile(_file: FileManager, response: any, status: number, headers: any): void;
    _onCompleteFile(_file: FileManager, response: any, status: number, headers: any): void;
    _onCompleteAll(): void;
    _headersGetter(parsedHeaders: any): (name: any) => any;
    _parseHeaders(headers: any): any;
    _transformResponse(response: any, headers: any): void;
    _runHook(type: hookType, ...args: any[]): void;
    /**
     *
     *
     * @private
     * @param {UploaderHook} hook
     * @returns {Boolean}
     *
     * @memberOf Transfer
     */
    private hookExists(hook);
    private filterExists(_filter);
}
