Lines Matching full:thread
30 JSThread *thread = argv->GetThread(); in LightWeightSetConstructor() local
31 BUILTINS_API_TRACE(thread, LightWeightSet, Constructor); in LightWeightSetConstructor()
32 [[maybe_unused]] EcmaHandleScope handleScope(thread); in LightWeightSetConstructor()
33 ObjectFactory *factory = thread->GetEcmaVM()->GetFactory(); in LightWeightSetConstructor()
37 ContainerError::BusinessError(thread, ErrorFlag::IS_NULL_ERROR, in LightWeightSetConstructor()
39 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in LightWeightSetConstructor()
43 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in LightWeightSetConstructor()
47 JSAPILightWeightSet::CreateSlot(thread, JSAPILightWeightSet::DEFAULT_CAPACITY_LENGTH); in LightWeightSetConstructor()
49 JSAPILightWeightSet::CreateSlot(thread, JSAPILightWeightSet::DEFAULT_CAPACITY_LENGTH); in LightWeightSetConstructor()
50 lightweightSet->SetHashes(thread, hashes); in LightWeightSetConstructor()
51 lightweightSet->SetValues(thread, values); in LightWeightSetConstructor()
58 JSThread *thread = argv->GetThread(); in Add() local
59 BUILTINS_API_TRACE(thread, LightWeightSet, Add); in Add()
60 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Add()
64 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Add()
66 JSTaggedValue error = ContainerError::BusinessError(thread, BIND_ERROR, in Add()
68 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Add()
72 bool flag = JSAPILightWeightSet::Add(thread, JSHandle<JSAPILightWeightSet>::Cast(self), value); in Add()
79 JSThread *thread = argv->GetThread(); in AddAll() local
80 BUILTINS_API_TRACE(thread, LightWeightSet, AddAll); in AddAll()
81 [[maybe_unused]] EcmaHandleScope handleScope(thread); in AddAll()
85 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in AddAll()
87 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in AddAll()
89 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in AddAll()
96 value = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(value)->GetTarget()); in AddAll()
98 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in AddAll()
101 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in AddAll()
102 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in AddAll()
106 …return JSTaggedValue(JSAPILightWeightSet::AddAll(thread, JSHandle<JSAPILightWeightSet>::Cast(self)… in AddAll()
112 JSThread *thread = argv->GetThread(); in IsEmpty() local
113 BUILTINS_API_TRACE(thread, LightWeightSet, IsEmpty); in IsEmpty()
114 [[maybe_unused]] EcmaHandleScope handleScope(thread); in IsEmpty()
118 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in IsEmpty()
120 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in IsEmpty()
122 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in IsEmpty()
132 JSThread *thread = argv->GetThread(); in GetValueAt() local
133 BUILTINS_API_TRACE(thread, LightWeightSet, GetValueAt); in GetValueAt()
134 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetValueAt()
138 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in GetValueAt()
140 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in GetValueAt()
142 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetValueAt()
147 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in GetValueAt()
150 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in GetValueAt()
151 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetValueAt()
161 JSThread *thread = argv->GetThread(); in HasAll() local
162 BUILTINS_API_TRACE(thread, LightWeightSet, HasAll); in HasAll()
163 [[maybe_unused]] EcmaHandleScope handleScope(thread); in HasAll()
167 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in HasAll()
169 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in HasAll()
171 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in HasAll()
177 value = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(value)->GetTarget()); in HasAll()
179 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in HasAll()
182 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in HasAll()
183 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in HasAll()
193 JSThread *thread = argv->GetThread(); in Has() local
194 BUILTINS_API_TRACE(thread, LightWeightSet, Has); in Has()
195 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Has()
199 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Has()
201 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Has()
203 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Has()
214 JSThread *thread = argv->GetThread(); in HasHash() local
215 BUILTINS_API_TRACE(thread, LightWeightSet, HasHash); in HasHash()
216 [[maybe_unused]] EcmaHandleScope handleScope(thread); in HasHash()
220 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in HasHash()
222 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in HasHash()
224 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in HasHash()
235 JSThread *thread = argv->GetThread(); in Equal() local
236 BUILTINS_API_TRACE(thread, LightWeightSet, Equal); in Equal()
237 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Equal()
241 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Equal()
243 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Equal()
245 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Equal()
249 …return JSTaggedValue(JSAPILightWeightSet::Equal(thread, JSHandle<JSAPILightWeightSet>::Cast(self),… in Equal()
255 JSThread *thread = argv->GetThread(); in IncreaseCapacityTo() local
256 BUILTINS_API_TRACE(thread, LightWeightSet, IncreaseCapacityTo); in IncreaseCapacityTo()
257 [[maybe_unused]] EcmaHandleScope handleScope(thread); in IncreaseCapacityTo()
261 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in IncreaseCapacityTo()
263 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in IncreaseCapacityTo()
265 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in IncreaseCapacityTo()
270 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in IncreaseCapacityTo()
273 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in IncreaseCapacityTo()
274 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in IncreaseCapacityTo()
277 …JSAPILightWeightSet::IncreaseCapacityTo(thread, JSHandle<JSAPILightWeightSet>::Cast(self), minCapa… in IncreaseCapacityTo()
278 RETURN_VALUE_IF_ABRUPT_COMPLETION(thread, JSTaggedValue::False()); in IncreaseCapacityTo()
285 JSThread *thread = argv->GetThread(); in GetIteratorObj() local
286 BUILTINS_API_TRACE(thread, LightWeightSet, GetIteratorObj); in GetIteratorObj()
287 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetIteratorObj()
291 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in GetIteratorObj()
293 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in GetIteratorObj()
295 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetIteratorObj()
299 …JSAPILightWeightSet::GetIteratorObj(thread, JSHandle<JSAPILightWeightSet>::Cast(self), IterationKi… in GetIteratorObj()
306 JSThread *thread = argv->GetThread(); in Values() local
307 BUILTINS_API_TRACE(thread, LightWeightSet, Values); in Values()
308 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Values()
312 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Values()
314 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Values()
316 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Values()
320 …JSAPILightWeightSet::GetIteratorObj(thread, JSHandle<JSAPILightWeightSet>::Cast(self), IterationKi… in Values()
327 JSThread *thread = argv->GetThread(); in Entries() local
328 BUILTINS_API_TRACE(thread, LightWeightSet, Entries); in Entries()
329 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Entries()
333 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Entries()
335 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Entries()
337 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Entries()
341 JSAPILightWeightSet::GetIteratorObj(thread, JSHandle<JSAPILightWeightSet>::Cast(self), in Entries()
349 JSThread *thread = argv->GetThread(); in ForEach() local
350 BUILTINS_API_TRACE(thread, LightWeightSet, ForEach); in ForEach()
351 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ForEach()
357 … thisHandle = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(thisHandle)->GetTarget()); in ForEach()
359 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in ForEach()
361 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in ForEach()
366 … JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, callbackFnHandle.GetTaggedValue()); in ForEach()
369 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in ForEach()
370 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in ForEach()
373 return JSAPILightWeightSet::ForEach(thread, thisHandle, callbackFnHandle, thisArgHandle); in ForEach()
379 JSThread *thread = argv->GetThread(); in GetIndexOf() local
380 BUILTINS_API_TRACE(thread, LightWeightSet, GetIndexOf); in GetIndexOf()
381 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetIndexOf()
385 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in GetIndexOf()
387 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in GetIndexOf()
389 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetIndexOf()
401 JSThread *thread = argv->GetThread(); in Remove() local
402 BUILTINS_API_TRACE(thread, LightWeightSet, Remove); in Remove()
403 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Remove()
407 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Remove()
409 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Remove()
411 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Remove()
416 return set->Remove(thread, key); in Remove()
422 JSThread *thread = argv->GetThread(); in RemoveAt() local
423 BUILTINS_API_TRACE(thread, LightWeightSet, RemoveAt); in RemoveAt()
424 [[maybe_unused]] EcmaHandleScope handleScope(thread); in RemoveAt()
428 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in RemoveAt()
430 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in RemoveAt()
432 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in RemoveAt()
437 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in RemoveAt()
440 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in RemoveAt()
441 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in RemoveAt()
445 return JSTaggedValue(set->RemoveAt(thread, index)); in RemoveAt()
451 JSThread *thread = argv->GetThread(); in Clear() local
452 BUILTINS_API_TRACE(thread, LightWeightSet, Clear); in Clear()
453 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Clear()
457 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Clear()
459 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Clear()
461 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Clear()
465 set->Clear(thread); in Clear()
472 JSThread *thread = argv->GetThread(); in ToString() local
473 BUILTINS_API_TRACE(thread, LightWeightSet, ToString); in ToString()
474 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ToString()
478 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in ToString()
480 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in ToString()
482 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in ToString()
485 …JSTaggedValue value = JSAPILightWeightSet::ToString(thread, JSHandle<JSAPILightWeightSet>::Cast(se… in ToString()
486 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in ToString()
493 JSThread *thread = argv->GetThread(); in ToArray() local
494 BUILTINS_API_TRACE(thread, LightWeightSet, ToArray); in ToArray()
495 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ToArray()
499 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in ToArray()
501 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in ToArray()
503 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in ToArray()
507 auto factory = thread->GetEcmaVM()->GetFactory(); in ToArray()
511 array->SetArrayLength(thread, length); in ToArray()
513 JSHandle<TaggedArray> srcArray(thread, lightweightset->GetValues()); in ToArray()
515 array->SetElements(thread, dstElements); in ToArray()
522 JSThread *thread = argv->GetThread(); in GetSize() local
523 BUILTINS_API_TRACE(thread, LightWeightSet, GetSize); in GetSize()
524 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetSize()
528 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in GetSize()
530 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in GetSize()
532 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetSize()