System.Threading.TWorkStealingQueue.TrySteal

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

function TrySteal(out AItem: T; Timeout: Cardinal = 0): Boolean;

C++

bool __fastcall TrySteal(/* out */ T &AItem, unsigned Timeout = (unsigned)(0x0));

Properties

Type Visibility Source Unit Parent
function public
System.Threading.pas
System.Threading.hpp
System.Threading TWorkStealingQueue

Description

TrySteal takes tasks from other threads queues when the calling thread pool thread finishes its own queue.

If the Timeout finishes before the thread finds other tasks, TrySteal will return False.

See Also