Megosztás a következőn keresztül:


IHostThreadPoolManager Interface

Provides methods that enable the common language runtime (CLR) to configure the thread pool and to queue work items to the thread pool.

Methods

Method

Description

IHostThreadPoolManager::GetAvailableThreads Method

Gets the number of threads in the thread pool that are not currently processing work items.

IHostThreadPoolManager::GetMaxThreads Method

Gets the maximum number of threads that the host maintains concurrently in the thread pool.

IHostThreadPoolManager::GetMinThreads Method

Gets the minimum number of idle threads that the host maintains in anticipation of requests.

IHostThreadPoolManager::QueueUserWorkItem Method

Queues a function for execution, and provides an object containing data to be used by the function.

IHostThreadPoolManager::SetMaxThreads Method

Sets the maximum number of threads that the host can maintain in the thread pool.

IHostThreadPoolManager::SetMinThreads Method

Sets the minimum number of idle threads that the host must maintain in anticipation of requests.

Remarks

The host is not required to configure the thread pool by using the values specified in calls to the SetMaxThreads and SetMinThreads methods. In this case, the host should return an HRESULT value of E_NOTIMPL from these methods.

Requirements

Platforms: See .NET Framework System Requirements.

Header: MSCorEE.h

Library: Included as a resource in MSCorEE.dll

.NET Framework Versions: 4, 3.5 SP1, 3.5, 3.0 SP1, 3.0, 2.0 SP1, 2.0

See Also

Reference

System.Threading

ThreadPool

Other Resources

Hosting Interfaces