(path: string, opts?: FileCreateOptions)
| 115 | } |
| 116 | |
| 117 | async create(path: string, opts?: FileCreateOptions): Promise<FileWriter> { |
| 118 | return this.limiter.execute(async () => { |
| 119 | const writer = await this.fs.create(path, opts); |
| 120 | return { |
| 121 | write: (content) => this.limiter.execute(() => writer.write(content), "write"), |
| 122 | }; |
| 123 | }, "create"); |
| 124 | } |
| 125 | |
| 126 | createDir(dir: string, opts?: FileCreateOptions): Promise<void> { |
| 127 | return this.limiter.execute(() => this.fs.createDir(dir, opts), "createDir"); |