MCPcopy Create free account
hub / github.com/csound/csound / stop

Method stop

wasm/browser/src/mains/spn.main.js:142–162  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

140 }
141
142 async stop() {
143 if (this.started) {
144 this.eventPromises.createStopPromise();
145 const stopResult = this.csoundApi.csoundStop(this.csoundInstance);
146 await this.eventPromises.waitForStop();
147 if (this.watcherStdOut) {
148 this.watcherStdOut.close();
149 delete this.watcherStdOut;
150 }
151
152 if (this.watcherStdErr) {
153 this.watcherStdErr.close();
154 delete this.watcherStdErr;
155 }
156
157 delete this.csoundInputBuffer;
158 delete this.csoundOutputBuffer;
159 delete this.currentPlayState;
160 return stopResult;
161 }
162 }
163
164 async start() {
165 if (!this.csoundApi) {

Callers 3

csoundResetMethod · 0.45
csoundResetMethod · 0.45
tests.jsFile · 0.45

Calls 4

createStopPromiseMethod · 0.80
waitForStopMethod · 0.80
closeMethod · 0.80
csoundStopMethod · 0.45

Tested by

no test coverage detected