|
1 | 1 | export interface LogOptions { |
2 | | - /** If false, don't output a trailing newline for the log entry. Default true. */ |
| 2 | + // If false, don't output a trailing newline for the log entry. Default true. |
3 | 3 | trailingNewline?: boolean; |
4 | 4 |
|
5 | | - /** If specified, add this log entry to the log file at the specified location. */ |
| 5 | + // If specified, add this log entry to the log file at the specified location. |
6 | 6 | additionalLogLocation?: string; |
7 | 7 | } |
8 | 8 |
|
9 | 9 | export interface Logger { |
10 | | - /** Writes the given log message, optionally followed by a newline. */ |
| 10 | + /** |
| 11 | + * Writes the given log message, optionally followed by a newline. |
| 12 | + * This function is asynchronous and will only resolve once the message is written |
| 13 | + * to the side log (if required). It is not necessary to await the results of this |
| 14 | + * function if you don't need to guarantee that the log writing is complete before |
| 15 | + * continuing. |
| 16 | + * |
| 17 | + * @param message The message to log. |
| 18 | + * @param options Optional settings. |
| 19 | + */ |
11 | 20 | log(message: string, options?: LogOptions): Promise<void>; |
| 21 | + |
12 | 22 | /** |
13 | | - * Reveal this channel in the UI. |
| 23 | + * Reveal the logger channel in the UI. |
14 | 24 | * |
15 | 25 | * @param preserveFocus When `true` the channel will not take focus. |
16 | 26 | */ |
17 | 27 | show(preserveFocus?: boolean): void; |
18 | 28 |
|
19 | 29 | /** |
20 | | - * Remove the log at the specified location |
| 30 | + * Remove the log at the specified location. |
| 31 | + * |
21 | 32 | * @param location log to remove |
22 | 33 | */ |
23 | 34 | removeAdditionalLogLocation(location: string | undefined): void; |
|
0 commit comments