RemoveParticipants Method

Task Parallel System.Threading

Notifies the Barrier that there will be fewer participants.

Namespace:  System.Threading
Assembly:  System.Threading (in System.Threading.dll)

Syntax

Visual Basic (Declaration)
Public Sub RemoveParticipants ( _
	participantCount As Integer _
)
C#
public void RemoveParticipants(
	int participantCount
)

Parameters

participantCount
Type: System..::.Int32
The number of additional participants to remove from the barrier.

Exceptions

ExceptionCondition
System..::.ArgumentOutOfRangeExceptionparticipantCount is less than 0.
System..::.InvalidOperationExceptionThe barrier already has 0 participants.
System..::.InvalidOperationException The method was invoked from within a post-phase action.
System..::.ObjectDisposedExceptionThe current instance has already been disposed.

See Also