Site Map Contact Us Home
E-mail Newsletter
Subscribe to get informed about
Clever Components news.

Your Name:
Your Email:
 
SUBSCRIBE
 
Previous Newsletters
 




Products Articles Downloads Order Support
Customer Portal     

Thread Pool

Features | Detailed Description

The Thread Pool is a component from the Clever Internet Suite library.

This component provides a pool of threads that can be used to post work items, process asynchronous I/O, wait on behalf of other threads, and process timers.

Available in VCL edition.

Features:

  • Works asynchronously
  • Runs many tasks in a few working threads
  • Supports COM initialization
  • Easy-to-use class structure
  • Free one year upgrades and support

Run asynchronous tasks with few lines of source code

The Thread Pool component allows you to define a method that can be run asynchronously in a thread and provide optional parameters to this method:

// [Delphi]
procedure TForm1.Button1Click(Sender: TObject);
begin
   clThreadPool1.MinThreadCount := 2;
   clThreadPool1.MaxThreadCount := 5;
   clThreadPool1.InitializeCOM := True;

   clThreadPool1.QueueWorkItem(Self, ThreadExecProc);
end;

procedure TForm1.ThreadExecProc(AContext: TObject; AThread: TThread);
begin
   //do necessary work
   //access the AContext members
end;

Complete Delphi source code

When Purchasing the Clever Internet Suite you receive the full sources for all suite components and also free unlimited support.

Interested?

    Copyright © 2000-2019