PostSharpAPI ReferencePost­Sharp.​Patterns.​Diagnostics.​ContextsSuspendable­Logging­ContextSuspend
Open sandboxFocus

SuspendableLoggingContext.Suspend Method

Suspend()

Suspends the current context. Typically called when starting to wait for a wait dependency (the operand of the await operator in case of async methods), or after the MoveNext() method (in case of iterators).

Declaration
public virtual void Suspend()
Remarks

In case of iterators, the Suspend() method is only invoked when MoveNext() returns true. Otherwise, the Dispose(Boolean) method is invoked.