Interface LocalFile

Represents a local file.

interface LocalFile {
    @type: "localFile";
    can_be_deleted?: boolean;
    can_be_downloaded?: boolean;
    download_offset: number;
    downloaded_prefix_size: number;
    downloaded_size: number;
    is_downloading_active?: boolean;
    is_downloading_completed?: boolean;
    path: string;
}

Properties

@type: "localFile"
can_be_deleted?: boolean

True, if the file can be deleted.

can_be_downloaded?: boolean

True, if it is possible to download or generate the file.

download_offset: number

Download will be started from this offset. downloaded_prefix_size is calculated from this offset.

downloaded_prefix_size: number

If is_downloading_completed is false, then only some prefix of the file starting from download_offset is ready to be read. downloaded_prefix_size is the size of that prefix in bytes.

downloaded_size: number

Total downloaded file size, in bytes. Can be used only for calculating download progress. The actual file size may be bigger, and some parts of it may contain garbage.

is_downloading_active?: boolean

True, if the file is currently being downloaded (or a local copy is being generated by some other means).

is_downloading_completed?: boolean

True, if the local copy is fully available.

path: string

Local path to the locally available file part; may be empty.