import AbstractHttpClientWithJSDom from 'restful-decorator-plugin-jsdom/lib'; import { IBluebird } from 'restful-decorator/lib/index'; import Bluebird from 'bluebird'; import { IJSDOM } from 'jsdom-extra'; import { IESJzoneRecentUpdate, IESJzoneRecentUpdateRowBook, IParametersSlice, IESJzoneRecentUpdateDay, IESJzoneChapter, IESJzoneChapterByPasswordForm, IESJzoneChapterOptions, IESJzoneChapterLocked } from './types'; /** * https://www.wenku8.net/index.php */ export declare class ESJzoneClient extends AbstractHttpClientWithJSDom { protected _handleArticleList, R = T & Pick>(_this: this, retDataInit: T): R; protected _handleArticleTopListAll any>(method: T, args: IParametersSlice, from?: number, pageTo?: number, { throwError, delay, }?: { throwError?: boolean; delay?: number; }): Bluebird> & { from: number; to: number; }>; /** * 轻小说列表 * 注意與轻小说最近更新不同,此列表可能會額外多出其他小說 */ articleList(page?: number, ...argv: any[]): IBluebird; articleListAll(from: number, to?: number, options?: { throwError?: boolean; delay?: number; }, ...args: IParametersSlice): Bluebird; /** * @deprecated * @todo */ isLogin(): IBluebird; bookInfo(novel_id: number | string): IBluebird; cookiesRemoveTrack(): this; _getDecodeChapter(argv: { novel_id: string | number; chapter_id: string | number; code: string; }): Promise; /** * * @param {IESJzoneChapterByPasswordForm} data * @returns {Bluebird} */ _queryChapterByPassword(data: IESJzoneChapterByPasswordForm): Bluebird; /** * @see https://www.esjzone.cc/forum/1604843935/100652.html */ _getChapterByPassword(argv: { novel_id: string | number; chapter_id: string | number; password?: string; }, jsdom?: IJSDOM, data?: Partial): Bluebird; _getChapter(argv: { novel_id: string | number; chapter_id: string | number; }): Bluebird & { $returnValue: IJSDOM; }>; /** * * @example ``` * api.getChapter({ novel_id: 2555, cid: 2, chapter_id: 101191, }, { cb(data) { data.$elem.after(`(插圖${data.i})\n`); data.$elem.remove(); }, }) ``` */ getChapter(argv: { novel_id: string | number; chapter_id: string | number; password?: string; }, options?: IESJzoneChapterOptions): Bluebird; recentUpdateDay(): IBluebird; } export default ESJzoneClient;