• Home
  • Raw
  • Download

Lines Matching full:thread

34     JSThread *thread = argv->GetThread();  in ArrayListConstructor()  local
35 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ArrayListConstructor()
36 ObjectFactory *factory = thread->GetEcmaVM()->GetFactory(); in ArrayListConstructor()
39 … THROW_TYPE_ERROR_AND_RETURN(thread, "new target can't be undefined", JSTaggedValue::Exception()); in ArrayListConstructor()
44 obj->SetElements(thread, newTaggedArray); in ArrayListConstructor()
45 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in ArrayListConstructor()
54 JSThread *thread = argv->GetThread(); in Add() local
55 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Add()
59 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in Add()
63 … return GetTaggedBoolean(JSAPIArrayList::Add(thread, JSHandle<JSAPIArrayList>::Cast(self), value)); in Add()
70 JSThread *thread = argv->GetThread(); in Insert() local
71 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Insert()
75 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in Insert()
81 THROW_TYPE_ERROR_AND_RETURN(thread, "index is not Integer", JSTaggedValue::Exception()); in Insert()
83 …JSAPIArrayList::Insert(thread, JSHandle<JSAPIArrayList>::Cast(self), value, JSTaggedValue::ToUint3… in Insert()
92 JSThread *thread = argv->GetThread(); in Clear() local
93 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Clear()
97 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in Clear()
100 JSAPIArrayList::Clear(thread, JSHandle<JSAPIArrayList>::Cast(self)); in Clear()
109 JSThread *thread = argv->GetThread(); in Clone() local
110 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Clone()
114 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in Clone()
117 …JSHandle<JSAPIArrayList> newArrayList = JSAPIArrayList::Clone(thread, JSHandle<JSAPIArrayList>::Ca… in Clone()
126 JSThread *thread = argv->GetThread(); in Has() local
127 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Has()
131 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in Has()
145 JSThread *thread = argv->GetThread(); in GetCapacity() local
149 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in GetCapacity()
152 uint32_t capacity = JSAPIArrayList::GetCapacity(thread, JSHandle<JSAPIArrayList>::Cast(self)); in GetCapacity()
161 JSThread *thread = argv->GetThread(); in IncreaseCapacityTo() local
162 [[maybe_unused]] EcmaHandleScope handleScope(thread); in IncreaseCapacityTo()
166 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in IncreaseCapacityTo()
171 … THROW_TYPE_ERROR_AND_RETURN(thread, "newCapacity is not Integer", JSTaggedValue::Exception()); in IncreaseCapacityTo()
174 JSAPIArrayList::IncreaseCapacityTo(thread, JSHandle<JSAPIArrayList>::Cast(self), in IncreaseCapacityTo()
175 JSTaggedValue::ToUint32(thread, newCapacity)); in IncreaseCapacityTo()
184 JSThread *thread = argv->GetThread(); in TrimToCurrentLength() local
185 [[maybe_unused]] EcmaHandleScope handleScope(thread); in TrimToCurrentLength()
189 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in TrimToCurrentLength()
192 JSAPIArrayList::TrimToCurrentLength(thread, JSHandle<JSAPIArrayList>::Cast(self)); in TrimToCurrentLength()
201 JSThread *thread = argv->GetThread(); in Get() local
202 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Get()
206 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in Get()
211 …alue element = JSHandle<JSAPIArrayList>::Cast(self)->Get(thread, JSTaggedValue::ToUint32(thread, v… in Get()
220 JSThread *thread = argv->GetThread(); in GetIndexOf() local
221 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetIndexOf()
225 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in GetIndexOf()
230 …return JSTaggedValue(JSAPIArrayList::GetIndexOf(thread, JSHandle<JSAPIArrayList>::Cast(self), valu… in GetIndexOf()
237 JSThread *thread = argv->GetThread(); in IsEmpty() local
238 [[maybe_unused]] EcmaHandleScope handleScope(thread); in IsEmpty()
242 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in IsEmpty()
252 JSThread *thread = argv->GetThread(); in GetLastIndexOf() local
253 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetLastIndexOf()
257 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in GetLastIndexOf()
262 …return JSTaggedValue(JSAPIArrayList::GetLastIndexOf(thread, JSHandle<JSAPIArrayList>::Cast(self), … in GetLastIndexOf()
269 JSThread *thread = argv->GetThread(); in RemoveByIndex() local
270 [[maybe_unused]] EcmaHandleScope handleScope(thread); in RemoveByIndex()
274 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in RemoveByIndex()
279 THROW_TYPE_ERROR_AND_RETURN(thread, "index is not Integer", JSTaggedValue::Exception()); in RemoveByIndex()
282 …JSAPIArrayList::RemoveByIndex(thread, JSHandle<JSAPIArrayList>::Cast(self), JSTaggedValue::ToUint3… in RemoveByIndex()
284 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in RemoveByIndex()
292 JSThread *thread = argv->GetThread(); in Remove() local
293 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Remove()
297 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in Remove()
302 bool isRemove = JSAPIArrayList::Remove(thread, JSHandle<JSAPIArrayList>::Cast(self), value); in Remove()
303 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in Remove()
312 JSThread *thread = argv->GetThread(); in RemoveByRange() local
313 [[maybe_unused]] EcmaHandleScope handleScope(thread); in RemoveByRange()
317 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in RemoveByRange()
323 …THROW_TYPE_ERROR_AND_RETURN(thread, "startIndex or endIndex is not Integer", JSTaggedValue::Except… in RemoveByRange()
325 … JSAPIArrayList::RemoveByRange(thread, JSHandle<JSAPIArrayList>::Cast(self), startIndex, endIndex); in RemoveByRange()
327 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in RemoveByRange()
335 JSThread *thread = argv->GetThread(); in ReplaceAllElements() local
336 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ReplaceAllElements()
340 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in ReplaceAllElements()
345 …THROW_TYPE_ERROR_AND_RETURN(thread, "the callbackfun is not callable.", JSTaggedValue::Exception()… in ReplaceAllElements()
349 return JSAPIArrayList::ReplaceAllElements(thread, self, callbackFnHandle, thisArgHandle); in ReplaceAllElements()
356 JSThread *thread = argv->GetThread(); in Set() local
357 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Set()
361 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in Set()
366 …JSHandle<JSAPIArrayList>::Cast(self)->Set(thread, JSTaggedValue::ToUint32(thread, index), value.Ge… in Set()
368 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in Set()
376 JSThread *thread = argv->GetThread(); in SubArrayList() local
377 [[maybe_unused]] EcmaHandleScope handleScope(thread); in SubArrayList()
381 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in SubArrayList()
387 …THROW_TYPE_ERROR_AND_RETURN(thread, "startIndex or endIndex is not Integer", JSTaggedValue::Except… in SubArrayList()
390 JSAPIArrayList::SubArrayList(thread, JSHandle<JSAPIArrayList>::Cast(self), value1, value2); in SubArrayList()
392 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in SubArrayList()
400 JSThread *thread = argv->GetThread(); in Sort() local
401 [[maybe_unused]] EcmaHandleScope handleScope(thread); in Sort()
405 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in Sort()
410 THROW_TYPE_ERROR_AND_RETURN(thread, "Callable is false", JSTaggedValue::Exception()); in Sort()
413 JSHandle<TaggedArray> elements(thread, JSHandle<JSAPIArrayList>::Cast(self)->GetElements()); in Sort()
414 JSMutableHandle<JSTaggedValue> presentValue(thread, JSTaggedValue::Undefined()); in Sort()
415 JSMutableHandle<JSTaggedValue> middleValue(thread, JSTaggedValue::Undefined()); in Sort()
416 JSMutableHandle<JSTaggedValue> previousValue(thread, JSTaggedValue::Undefined()); in Sort()
426 int32_t compareResult = base::ArrayHelper::SortCompare(thread, callbackFnHandle, in Sort()
428 RETURN_EXCEPTION_IF_ABRUPT_COMPLETION(thread); in Sort()
439 elements->Set(thread, j, previousValue.GetTaggedValue()); in Sort()
441 elements->Set(thread, endIndex, presentValue.GetTaggedValue()); in Sort()
452 JSThread *thread = argv->GetThread(); in GetSize() local
453 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetSize()
457 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in GetSize()
467 JSThread *thread = argv->GetThread(); in ConvertToArray() local
468 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ConvertToArray()
472 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in ConvertToArray()
477 JSHandle<JSArray> array = thread->GetEcmaVM()->GetFactory()->NewJSArray(); in ConvertToArray()
478 array->SetArrayLength(thread, length); in ConvertToArray()
479 JSHandle<TaggedArray> arrayListElements(thread, arrayList->GetElements()); in ConvertToArray()
484thread->GetEcmaVM()->GetFactory()->CopyArray(arrayListElements, arrayListCapacity, arrayListCapaci… in ConvertToArray()
485 array->SetElements(thread, newElements); in ConvertToArray()
493 JSThread *thread = argv->GetThread(); in ForEach() local
494 [[maybe_unused]] EcmaHandleScope handleScope(thread); in ForEach()
498 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in ForEach()
503 …THROW_TYPE_ERROR_AND_RETURN(thread, "the callbackfun is not callable.", JSTaggedValue::Exception()… in ForEach()
508 return JSAPIArrayList::ForEach(thread, self, callbackFnHandle, thisArgHandle); in ForEach()
515 JSThread *thread = argv->GetThread(); in GetIteratorObj() local
516 [[maybe_unused]] EcmaHandleScope handleScope(thread); in GetIteratorObj()
521 … THROW_TYPE_ERROR_AND_RETURN(thread, "obj is not JSAPIArrayList", JSTaggedValue::Exception()); in GetIteratorObj()
524 …JSTaggedValue values = JSAPIArrayList::GetIteratorObj(thread, JSHandle<JSAPIArrayList>::Cast(self)… in GetIteratorObj()