* Parse a command string and return a ParsedCommand instance. * Returns null if parsing fails completely.
(command: string)
| 308 | * Returns null if parsing fails completely. |
| 309 | */ |
| 310 | parse(command: string): Promise<IParsedCommand | null> { |
| 311 | if (command === lastCmd && lastResult !== undefined) { |
| 312 | return lastResult |
| 313 | } |
| 314 | lastCmd = command |
| 315 | lastResult = doParse(command) |
| 316 | return lastResult |
| 317 | }, |
| 318 | } |
no test coverage detected