1 |
|
2 | import { Writable } from 'stream';
|
3 | import { Configuration } from './Configuration';
|
4 | import { MessageName } from './MessageName';
|
5 | import { Report } from './Report';
|
6 | import { Locator } from './types';
|
7 | export declare type LightReportOptions = {
|
8 | configuration: Configuration;
|
9 | stdout: Writable;
|
10 | suggestInstall?: boolean;
|
11 | };
|
12 | export declare class LightReport extends Report {
|
13 | static start(opts: LightReportOptions, cb: (report: LightReport) => Promise<void>): Promise<LightReport>;
|
14 | private configuration;
|
15 | private stdout;
|
16 | private suggestInstall;
|
17 | private errorCount;
|
18 | constructor({ configuration, stdout, suggestInstall }: LightReportOptions);
|
19 | hasErrors(): boolean;
|
20 | exitCode(): 0 | 1;
|
21 | reportCacheHit(locator: Locator): void;
|
22 | reportCacheMiss(locator: Locator): void;
|
23 | startTimerSync<T>(what: string, cb: () => T): T;
|
24 | startTimerPromise<T>(what: string, cb: () => Promise<T>): Promise<T>;
|
25 | startCacheReport<T>(cb: () => Promise<T>): Promise<T>;
|
26 | reportSeparator(): void;
|
27 | reportInfo(name: MessageName | null, text: string): void;
|
28 | reportWarning(name: MessageName, text: string): void;
|
29 | reportError(name: MessageName, text: string): void;
|
30 | reportProgress(progress: AsyncIterable<{
|
31 | progress: number;
|
32 | title?: string;
|
33 | }>): {
|
34 | stop: () => void;
|
35 | then<TResult1 = void, TResult2 = never>(onfulfilled?: ((value: void) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined): Promise<TResult1 | TResult2>;
|
36 | catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | null | undefined): Promise<void | TResult>;
|
37 | [Symbol.toStringTag]: string;
|
38 | finally(onfinally?: (() => void) | null | undefined): Promise<void>;
|
39 | };
|
40 | reportJson(data: any): void;
|
41 | finalize(): Promise<void>;
|
42 | private formatNameWithHyperlink;
|
43 | }
|
44 |
|
\ | No newline at end of file |