• Home
  • Raw
  • Download

Lines Matching full:thread

27     JSThread *thread = argv->GetThread();  in LightWeightSetConstructor()  local
28 BUILTINS_API_TRACE(thread, LightWeightSet, Constructor); in LightWeightSetConstructor()
29 [[maybe_unused]] EcmaHandleScope handleScope(thread); in LightWeightSetConstructor()
30 ObjectFactory *factory = thread->GetEcmaVM()->GetFactory(); in LightWeightSetConstructor()
34 ContainerError::BusinessError(thread, ErrorFlag::IS_NULL_ERROR, in LightWeightSetConstructor()
36 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in LightWeightSetConstructor()
40 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in LightWeightSetConstructor()
44 JSAPILightWeightSet::CreateSlot(thread, JSAPILightWeightSet::DEFAULT_CAPACITY_LENGTH); in LightWeightSetConstructor()
46 JSAPILightWeightSet::CreateSlot(thread, JSAPILightWeightSet::DEFAULT_CAPACITY_LENGTH); in LightWeightSetConstructor()
47 lightweightSet->SetHashes(thread, hashes); in LightWeightSetConstructor()
48 lightweightSet->SetValues(thread, values); in LightWeightSetConstructor()
55 JSThread *thread = argv->GetThread(); in Add() local
56 BUILTINS_API_TRACE(thread, LightWeightSet, Add); in Add()
57 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Add()
61 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Add()
63 JSTaggedValue error = ContainerError::BusinessError(thread, BIND_ERROR, in Add()
65 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Add()
69 bool flag = JSAPILightWeightSet::Add(thread, JSHandle<JSAPILightWeightSet>::Cast(self), value); in Add()
76 JSThread *thread = argv->GetThread(); in AddAll() local
77 BUILTINS_API_TRACE(thread, LightWeightSet, AddAll); in AddAll()
78 [[maybe_unused]] EcmaHandleScope handleScope(thread); in AddAll()
82 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in AddAll()
84 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in AddAll()
86 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in AddAll()
93 value = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(value)->GetTarget()); in AddAll()
95 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in AddAll()
96 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in AddAll()
99 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in AddAll()
100 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in AddAll()
104 …return JSTaggedValue(JSAPILightWeightSet::AddAll(thread, JSHandle<JSAPILightWeightSet>::Cast(self)… in AddAll()
110 JSThread *thread = argv->GetThread(); in IsEmpty() local
111 BUILTINS_API_TRACE(thread, LightWeightSet, IsEmpty); in IsEmpty()
112 [[maybe_unused]] EcmaHandleScope handleScope(thread); in IsEmpty()
116 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in IsEmpty()
118 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in IsEmpty()
120 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in IsEmpty()
130 JSThread *thread = argv->GetThread(); in GetValueAt() local
131 BUILTINS_API_TRACE(thread, LightWeightSet, GetValueAt); in GetValueAt()
132 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetValueAt()
136 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in GetValueAt()
138 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in GetValueAt()
140 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetValueAt()
145 … value = JSHandle<JSTaggedValue>(thread, JSTaggedValue::TryCastDoubleToInt32(value->GetDouble())); in GetValueAt()
148 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in GetValueAt()
149 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in GetValueAt()
152 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in GetValueAt()
153 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetValueAt()
162 JSThread *thread = argv->GetThread(); in HasAll() local
163 BUILTINS_API_TRACE(thread, LightWeightSet, HasAll); in HasAll()
164 [[maybe_unused]] EcmaHandleScope handleScope(thread); in HasAll()
168 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in HasAll()
170 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in HasAll()
172 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in HasAll()
178 value = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(value)->GetTarget()); in HasAll()
180 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in HasAll()
181 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in HasAll()
184 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in HasAll()
185 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in HasAll()
195 JSThread *thread = argv->GetThread(); in Has() local
196 BUILTINS_API_TRACE(thread, LightWeightSet, Has); in Has()
197 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Has()
201 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Has()
203 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Has()
205 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Has()
210 return JSTaggedValue(set->Has(thread, value)); in Has()
216 JSThread *thread = argv->GetThread(); in HasHash() local
217 BUILTINS_API_TRACE(thread, LightWeightSet, HasHash); in HasHash()
218 [[maybe_unused]] EcmaHandleScope handleScope(thread); in HasHash()
222 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in HasHash()
224 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in HasHash()
226 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in HasHash()
237 JSThread *thread = argv->GetThread(); in Equal() local
238 BUILTINS_API_TRACE(thread, LightWeightSet, Equal); in Equal()
239 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Equal()
243 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Equal()
245 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Equal()
247 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Equal()
251 …return JSTaggedValue(JSAPILightWeightSet::Equal(thread, JSHandle<JSAPILightWeightSet>::Cast(self),… in Equal()
257 JSThread *thread = argv->GetThread(); in IncreaseCapacityTo() local
258 BUILTINS_API_TRACE(thread, LightWeightSet, IncreaseCapacityTo); in IncreaseCapacityTo()
259 [[maybe_unused]] EcmaHandleScope handleScope(thread); in IncreaseCapacityTo()
263 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in IncreaseCapacityTo()
265 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in IncreaseCapacityTo()
267 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in IncreaseCapacityTo()
274 … value = JSHandle<JSTaggedValue>(thread, JSTaggedValue::TryCastDoubleToInt32(value->GetDouble())); in IncreaseCapacityTo()
278 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in IncreaseCapacityTo()
279 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in IncreaseCapacityTo()
282 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in IncreaseCapacityTo()
283 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in IncreaseCapacityTo()
286 …JSAPILightWeightSet::IncreaseCapacityTo(thread, JSHandle<JSAPILightWeightSet>::Cast(self), minCapa… in IncreaseCapacityTo()
287 RETURN_VALUE_IF_ABRUPT_COMPLETION(thread, JSTaggedValue::False()); in IncreaseCapacityTo()
294 JSThread *thread = argv->GetThread(); in GetIteratorObj() local
295 BUILTINS_API_TRACE(thread, LightWeightSet, GetIteratorObj); in GetIteratorObj()
296 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetIteratorObj()
300 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in GetIteratorObj()
302 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in GetIteratorObj()
304 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetIteratorObj()
308 …JSAPILightWeightSet::GetIteratorObj(thread, JSHandle<JSAPILightWeightSet>::Cast(self), IterationKi… in GetIteratorObj()
315 JSThread *thread = argv->GetThread(); in Values() local
316 BUILTINS_API_TRACE(thread, LightWeightSet, Values); in Values()
317 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Values()
321 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Values()
323 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Values()
325 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Values()
329 …JSAPILightWeightSet::GetIteratorObj(thread, JSHandle<JSAPILightWeightSet>::Cast(self), IterationKi… in Values()
336 JSThread *thread = argv->GetThread(); in Entries() local
337 BUILTINS_API_TRACE(thread, LightWeightSet, Entries); in Entries()
338 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Entries()
342 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Entries()
344 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Entries()
346 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Entries()
350 JSAPILightWeightSet::GetIteratorObj(thread, JSHandle<JSAPILightWeightSet>::Cast(self), in Entries()
358 JSThread *thread = argv->GetThread(); in ForEach() local
359 BUILTINS_API_TRACE(thread, LightWeightSet, ForEach); in ForEach()
360 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ForEach()
366 … thisHandle = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(thisHandle)->GetTarget()); in ForEach()
368 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in ForEach()
370 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in ForEach()
375 … JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, callbackFnHandle.GetTaggedValue()); in ForEach()
376 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in ForEach()
379 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in ForEach()
380 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in ForEach()
383 return JSAPILightWeightSet::ForEach(thread, thisHandle, callbackFnHandle, thisArgHandle); in ForEach()
389 JSThread *thread = argv->GetThread(); in GetIndexOf() local
390 BUILTINS_API_TRACE(thread, LightWeightSet, GetIndexOf); in GetIndexOf()
391 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetIndexOf()
395 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in GetIndexOf()
397 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in GetIndexOf()
399 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetIndexOf()
404 int32_t result = set->GetIndexOf(thread, value); in GetIndexOf()
411 JSThread *thread = argv->GetThread(); in Remove() local
412 BUILTINS_API_TRACE(thread, LightWeightSet, Remove); in Remove()
413 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Remove()
417 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Remove()
419 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Remove()
421 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Remove()
426 JSAPILightWeightSet::CheckAndCopyValues(thread, lightweightset); in Remove()
428 return set->Remove(thread, key); in Remove()
434 JSThread *thread = argv->GetThread(); in RemoveAt() local
435 BUILTINS_API_TRACE(thread, LightWeightSet, RemoveAt); in RemoveAt()
436 [[maybe_unused]] EcmaHandleScope handleScope(thread); in RemoveAt()
440 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in RemoveAt()
442 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in RemoveAt()
444 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in RemoveAt()
449 … value = JSHandle<JSTaggedValue>(thread, JSTaggedValue::TryCastDoubleToInt32(value->GetDouble())); in RemoveAt()
452 JSHandle<EcmaString> result = JSTaggedValue::ToString(thread, value.GetTaggedValue()); in RemoveAt()
453 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in RemoveAt()
456 …JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::TYPE_ERROR, errorMsg.c_str(… in RemoveAt()
457 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in RemoveAt()
460 JSAPILightWeightSet::CheckAndCopyValues(thread, lightweightset); in RemoveAt()
462 return JSTaggedValue(set->RemoveAt(thread, value->GetInt())); in RemoveAt()
468 JSThread *thread = argv->GetThread(); in Clear() local
469 BUILTINS_API_TRACE(thread, LightWeightSet, Clear); in Clear()
470 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Clear()
474 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in Clear()
476 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in Clear()
478 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in Clear()
482 set->Clear(thread); in Clear()
489 JSThread *thread = argv->GetThread(); in ToString() local
490 BUILTINS_API_TRACE(thread, LightWeightSet, ToString); in ToString()
491 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ToString()
495 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in ToString()
497 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in ToString()
499 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in ToString()
502 …JSTaggedValue value = JSAPILightWeightSet::ToString(thread, JSHandle<JSAPILightWeightSet>::Cast(se… in ToString()
503 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in ToString()
510 JSThread *thread = argv->GetThread(); in ToArray() local
511 BUILTINS_API_TRACE(thread, LightWeightSet, ToArray); in ToArray()
512 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ToArray()
516 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in ToArray()
518 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in ToArray()
520 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in ToArray()
524 auto factory = thread->GetEcmaVM()->GetFactory(); in ToArray()
528 array->SetArrayLength(thread, length); in ToArray()
530 JSHandle<TaggedArray> srcArray(thread, lightweightset->GetValues()); in ToArray()
533 array->SetElements(thread, srcArray.GetTaggedValue()); in ToArray()
539 lightweightset->SetValues(thread, newElements.GetTaggedValue()); in ToArray()
540 array->SetElements(thread, newElements); in ToArray()
547 JSThread *thread = argv->GetThread(); in GetSize() local
548 BUILTINS_API_TRACE(thread, LightWeightSet, GetSize); in GetSize()
549 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetSize()
553 self = JSHandle<JSTaggedValue>(thread, JSHandle<JSProxy>::Cast(self)->GetTarget()); in GetSize()
555 JSTaggedValue error = ContainerError::BusinessError(thread, ErrorFlag::BIND_ERROR, in GetSize()
557 THROW_NEW_ERROR_AND_RETURN_VALUE(thread, error, JSTaggedValue::Exception()); in GetSize()