Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions src/Microsoft.VisualStudio.Threading/AsyncQueue`1.cs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public int Count
}

/// <summary>
/// Gets a value indicating whether the queue has completed.
/// Gets a value indicating whether the queue is both empty and had <see cref="Complete" /> invoked.
/// </summary>
/// <remarks>
/// This is arguably redundant with <see cref="Completion"/>.IsCompleted, but this property
Expand All @@ -101,7 +101,7 @@ public bool IsCompleted
}

/// <summary>
/// Gets a task that transitions to a completed state when <see cref="Complete"/> is called.
/// Gets a task that transitions to a completed state when <see cref="Complete"/> is called and the queue is empty.
/// </summary>
public Task Completion
{
Expand Down Expand Up @@ -142,6 +142,11 @@ public Task Completion
/// <summary>
/// Signals that no further elements will be enqueued.
/// </summary>
/// <remarks>
/// This method will return immediately.
/// Elements enqueued before calling this method may still be dequeued.
/// <see cref="IsCompleted" /> will return true only after this method has been called and the queue is empty.
/// </remarks>
public void Complete()
{
lock (this.SyncRoot)
Expand Down