Wait - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

Threads

  

Wait

  

wait for a thread to finish

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

Wait( id1, id2, ... )

Parameters

id1, id2, ...

-

(integer) thread identifiers

Description

• 

The Wait command pauses the current thread until the threads specified as arguments finish.

Examples

(1)

p := proc( limit )
   local now, start;
   start := time[real]();
   now := start;
   
   while now - start < limit        
   do
       Threads:-Sleep( 0.1 );
       now := time[real]();
   end;

   return now-start;
end:

(2)

(3)

(4)

See Also

Threads

Threads[ConditionVariable]

Threads[Create]

Threads[Mutex]

Threads[Self]

 


Download Help Document