Lines Matching refs:thread
97 …let thread: ProcedureThread = new ProcedureThread("trace/database/ui-worker/ProcedureWorker.js", {…
98 thread.name = this.names[this.works.length]
99 thread.onmessage = (event: MessageEvent) => {
100 thread.busy = false;
103 thread.busy = false;
106 if (Reflect.has(thread.taskMap, event.data.id)) {
108 let fun = thread.taskMap[event.data.id];
112 Reflect.deleteProperty(thread.taskMap, event.data.id)
119 thread.onmessageerror = e => {
121 thread.onerror = e => {
123 thread.id = this.works.length
124 thread.busy = false
125 this.works?.push(thread)
126 return thread;
130 …let thread: ProcedureThread = new ProcedureThread("trace/database/logic-worker/ProcedureLogicWorke…
131 thread.name = this.logicDataHandles[this.works.length - this.names.length]
132 thread.onmessage = (event: MessageEvent) => {
133 thread.busy = false;
136 thread.postMessage({
147 if (Reflect.has(thread.taskMap, event.data.id)) {
149 let fun = thread.taskMap[event.data.id];
157 if (Reflect.has(thread.taskMap, event.data.id)) {
159 let fun = thread.taskMap[event.data.id];
163 Reflect.deleteProperty(thread.taskMap, event.data.id)
170 thread.onmessageerror = e => {
172 thread.onerror = e => {
174 thread.id = this.works.length
175 thread.busy = false
176 this.works?.push(thread)
177 return thread;
182 let thread = this.works[i];
183 thread.terminate();
190 let thread = this.works[i];
191 thread.queryFunc("clear", {}, undefined, () => {
198 let thread: ProcedureThread | undefined
200 thread = noBusyThreads[0];
201 thread!.queryFunc(type, args, transfer, handler)
203 return thread;
209 let thread: ProcedureThread | undefined
211 thread = noBusyThreads[0];
212 thread!.queryFunc(type, args, transfer, (res: any, hover: any) => {