2018-06-22 17:10:38 +02:00
|
|
|
interface ISolidFile {
|
2018-06-22 17:21:14 +02:00
|
|
|
//TODO: show length
|
|
|
|
/** File name of this file. */
|
|
|
|
path: [string];
|
2018-06-22 17:10:38 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
interface ISolidFileInfo {
|
|
|
|
/** List of files that are part of this torrent. */
|
|
|
|
files: ISolidFile[];
|
|
|
|
/** Length of one piece in bytes, e.g. 4194304 for 4 MB. */
|
|
|
|
'piece length': number;
|
|
|
|
/** Concatenated hashes of all pieces. */
|
|
|
|
pieces: string;
|
|
|
|
/** Whether the torrent is private, always 0. */
|
|
|
|
private: 0 | 1;
|
|
|
|
/** Whether the torrent is closed, always 1. */
|
|
|
|
closed: 0 | 1;
|
|
|
|
/** Unique ID of this torrent, e.g. '85ff8715-d1ce-4320-805c-bea80b6dd03c' */
|
|
|
|
uniqueid: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
interface ISolid {
|
|
|
|
/** Timestamp when this torrent was created, given in seconds since 1970. Can be read with `new Date(... * 1000)`. */
|
|
|
|
'creation date': number;
|
|
|
|
/** Internal tracker URL used to announce this torrent. */
|
|
|
|
announce: string;
|
|
|
|
/** Title of this torrent in the format `${product}: ${from}to${to}` */
|
|
|
|
title: string;
|
|
|
|
/** Unknown integer, always 16097. */
|
|
|
|
networkgroupid: number;
|
|
|
|
/** The URL where the files from this torrent are stored, in the format `http://cdn-patch.swtor.com/patch/${product}/${product}_${from}to${to}/` */
|
|
|
|
reliable: string;
|
|
|
|
/** Always '0' */
|
|
|
|
'reliable-id': string;
|
|
|
|
/** Contains further information about this torrent, including the list of files. */
|
|
|
|
info: ISolidFileInfo;
|
|
|
|
}
|
|
|
|
|
|
|
|
export default ISolid;
|