ThreadingPolicy Class |
Namespace: AGI.Foundation.Infrastructure.Threading
The ThreadingPolicy type exposes the following members.
Name | Description | |
---|---|---|
![]() ![]() | NumberOfThreads |
Gets or sets the number of threads to use to execute parallelizable operations.
|
![]() ![]() | ThreadSource |
Gets or sets the source of new threads to be used to execute parallelizable operations.
|
Name | Description | |
---|---|---|
![]() ![]() | ConfigureToUseAllLogicalProcessors |
Configures the threading policy so that parallelizable operations use one thread for each
logical processor on the system. In some partial-trust environments, in may not be possible
to determine the number of logical processors. In that case, the threading policy will
be configured to use two threads.
|
![]() ![]() | ConfigureToUseCurrentThreadOnly |
Configures the threading policy so that parallelizable operations are executed using only
the thread that invoked them. No additional threads are created.
|
![]() ![]() | ResetCurrentToDefault |
Resets the current threading policy to the default.
|
![]() ![]() | UseCurrentAsDefault |
Sets the current threading policy as the default policy to be used for new threads.
|