ConcurrentQueue<T>.IProducerConsumerCollection<T>.TryTake 메서드
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
에서 개체를 제거하고 반환하려고 시도합니다 IProducerConsumerCollection<T>.
virtual bool System.Collections.Concurrent.IProducerConsumerCollection<T>.TryTake([Runtime::InteropServices::Out] T % item) = System::Collections::Concurrent::IProducerConsumerCollection<T>::TryTake;
bool IProducerConsumerCollection<T>.TryTake(out T item);
abstract member System.Collections.Concurrent.IProducerConsumerCollection<T>.TryTake : 'T -> bool
override this.System.Collections.Concurrent.IProducerConsumerCollection<T>.TryTake : 'T -> bool
Function TryTake (ByRef item As T) As Boolean Implements IProducerConsumerCollection(Of T).TryTake
매개 변수
- item
- T
이 메서드가 반환될 때 작업이 성공 item 하면 제거된 개체가 포함됩니다. 제거할 수 있는 개체가 없으면 값이 지정되지 않습니다.
반품
true요소가 제거되고 성공적으로 반환되면 이고, 그렇지 않으면 . false
구현
설명
의 경우 ConcurrentQueue<T>이 작업은 개체를 처음부터 제거하려고 시도합니다 ConcurrentQueue<T>.