PostSharp//API Reference/Post­Sharp.​Patterns.​Threading/Concurrency­Controller­Factory/Create­Synchronized­Controller
Open sandboxFocus

Method CreateSynchronizedController

CreateSynchronizedController(Boolean)

Creates a new concurrency controller for the synchronized threading model (SynchronizedThreadingModel) and specifies whether the new controller should participate in deadlock detection.

Declaration
public static IConcurrencyController CreateSynchronizedController(bool useDeadlockDetection)
Parameters
Type Name Description
Boolean useDeadlockDetection

Indicates whether the controller should participate in the deadlock detection algorithm. Use IsEnabled(Assembly) to determine whether the policy is enabled for the current assembly.

Returns
Type Description
IConcurrencyController

A new instance of the synchronized concurrency controller.