* Format the provided source code using the formatting tool. * * This method should construct the command line arguments and call the formatter executable with the constructed * arguments, returning the execution result
(source: string, options: FormatOptions)
| 40 | * arguments, returning the execution result |
| 41 | */ |
| 42 | async format(source: string, options: FormatOptions): Promise<UnprocessedExecResult> { |
| 43 | const args = [`--style=${options.baseStyle}`]; |
| 44 | return await exec.execute(this.formatterInfo.exe, args, {input: source}); |
| 45 | } |
| 46 | |
| 47 | /** |
| 48 | * Test if a formatting base style is valid for this formatter |