Lines Matching refs:thread
27 JSThread *thread = argv->GetThread();
28 BUILTINS_API_TRACE(thread, HashMap, Constructor);
29 [[maybe_unused]] EcmaHandleScope handleScope(thread);
30 ObjectFactory *factory = thread->GetEcmaVM()->GetFactory();
35 ContainerError::BusinessError(thread, ErrorFlag::IS_NULL_ERROR,
37 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
42 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread);
45 JSTaggedValue hashMapArray = TaggedHashArray::Create(thread);
46 hashMap->SetTable(thread, hashMapArray);
55 JSThread *thread = argv->GetThread();
56 BUILTINS_API_TRACE(thread, HashMap, Keys);
57 [[maybe_unused]] EcmaHandleScope handleScope(thread);
61 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
63 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
65 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
69 JSAPIHashMapIterator::CreateHashMapIterator(thread, self, IterationKind::KEY);
76 JSThread *thread = argv->GetThread();
77 BUILTINS_API_TRACE(thread, HashMap, Values);
78 [[maybe_unused]] EcmaHandleScope handleScope(thread);
82 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
84 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
86 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
90 JSAPIHashMapIterator::CreateHashMapIterator(thread, self, IterationKind::VALUE);
97 JSThread *thread = argv->GetThread();
98 BUILTINS_API_TRACE(thread, HashMap, GetIteratorObj);
99 [[maybe_unused]] EcmaHandleScope handleScope(thread);
103 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
105 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
107 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
111 JSAPIHashMapIterator::CreateHashMapIterator(thread, self, IterationKind::KEY_AND_VALUE);
118 JSThread *thread = argv->GetThread();
119 BUILTINS_API_TRACE(thread, HashMap, Entries);
120 [[maybe_unused]] EcmaHandleScope handleScope(thread);
124 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
126 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
128 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
132 JSAPIHashMapIterator::CreateHashMapIterator(thread, self, IterationKind::KEY_AND_VALUE);
139 JSThread *thread = argv->GetThread();
140 BUILTINS_API_TRACE(thread, HashMap, ForEach);
141 [[maybe_unused]] EcmaHandleScope handleScope(thread);
145 thisHandle = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(thisHandle)->GetTarget());
147 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
149 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
154 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, callbackFnHandle);
155 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread);
158 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str());
159 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
163 JSHandle<TaggedHashArray> table(thread, hashMap->GetTable());
165 ObjectFactory *factory = thread->GetEcmaVM()->GetFactory();
166 JSMutableHandle<TaggedQueue> queue(thread, factory->NewTaggedQueue(0));
167 JSMutableHandle<TaggedNode> node(thread, JSTaggedValue::Undefined());
168 JSMutableHandle<JSTaggedValue> key(thread, JSTaggedValue::Undefined());
169 JSMutableHandle<JSTaggedValue> value(thread, JSTaggedValue::Undefined());
171 JSHandle<JSTaggedValue> undefined = thread->GlobalConstants()->GetHandledUndefined();
173 node.Update(TaggedHashArray::GetCurrentNode(thread, queue, table, index));
178 EcmaInterpreter::NewRuntimeCallInfo(thread, callbackFnHandle,
180 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread);
183 RETURN_VALUE_IF_ABRUPT_COMPLETION(thread, funcResult);
192 JSThread *thread = argv->GetThread();
193 BUILTINS_API_TRACE(thread, HashMap, Set);
194 [[maybe_unused]] EcmaHandleScope handleScope(thread);
198 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
200 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
202 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
208 JSAPIHashMap::Set(thread, hashMap, key, value);
209 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread);
216 JSThread *thread = argv->GetThread();
217 BUILTINS_API_TRACE(thread, HashMap, SetAll);
218 [[maybe_unused]] EcmaHandleScope handleScope(thread);
222 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
224 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
226 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
233 obj = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(obj)->GetTarget());
235 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, obj);
236 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread);
239 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str());
240 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
246 JSAPIHashMap::SetAll(thread, targetMap, sourceMap);
253 JSThread *thread = argv->GetThread();
254 BUILTINS_API_TRACE(thread, HashMap, Get);
255 [[maybe_unused]] EcmaHandleScope handleScope(thread);
259 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
261 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
263 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
268 return hashMap->Get(thread, key.GetTaggedValue());
274 JSThread *thread = argv->GetThread();
275 BUILTINS_API_TRACE(thread, HashMap, Remove);
276 [[maybe_unused]] EcmaHandleScope handleScope(thread);
281 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
283 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
285 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
290 return JSAPIHashMap::Remove(thread, hashMap, key.GetTaggedValue());
296 JSThread *thread = argv->GetThread();
297 BUILTINS_API_TRACE(thread, HashMap, HasKey);
298 [[maybe_unused]] EcmaHandleScope handleScope(thread);
303 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
305 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
307 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
312 return hashMap->HasKey(thread, key.GetTaggedValue());
318 JSThread *thread = argv->GetThread();
319 BUILTINS_API_TRACE(thread, HashMap, HasValue);
320 [[maybe_unused]] EcmaHandleScope handleScope(thread);
325 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
327 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
329 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
334 return JSAPIHashMap::HasValue(thread, hashMap, value);
340 JSThread *thread = argv->GetThread();
341 BUILTINS_API_TRACE(thread, HashMap, Replace);
342 [[maybe_unused]] EcmaHandleScope handleScope(thread);
346 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
348 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
350 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
356 return JSTaggedValue(jsHashMap->Replace(thread, key.GetTaggedValue(), newValue.GetTaggedValue()));
362 JSThread *thread = argv->GetThread();
363 BUILTINS_API_TRACE(thread, HashMap, Clear);
364 [[maybe_unused]] EcmaHandleScope handleScope(thread);
368 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
370 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
372 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
376 jsHashMap->Clear(thread);
383 JSThread *thread = argv->GetThread();
384 BUILTINS_API_TRACE(thread, HashMap, GetLength);
385 [[maybe_unused]] EcmaHandleScope handleScope(thread);
389 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
391 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
393 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());
403 JSThread *thread = argv->GetThread();
404 BUILTINS_API_TRACE(thread, HashMap, IsEmpty);
405 [[maybe_unused]] EcmaHandleScope handleScope(thread);
409 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget());
411 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR,
413 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception());