WaitForInitialization(IThreadAware, TimeSpan?, CancellationToken)
Actively waits for initialization of a thread aware object, i.e. for the constructor to complete.
Declaration
public static bool WaitForInitialization(IThreadAware threadAware, TimeSpan? timeout = null, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
IThreadAware | threadAware | Object. |
TimeSpan? | timeout | Timeout. |
CancellationToken | cancellationToken | CancellationToken. |
Returns
Type | Description |
---|---|
bool |
|
Remarks
May introduce deadlocks if used improperly.