May 2010
Intermediate to advanced
1272 pages
61h 18m
English
Queue CollectionThe System.Collections.Queue collection works according to the FIFO (First-In, First-Out) paradigm, meaning that the first item you add to the collection is the first pulled out from the collection. Queue exposes two methods, Enqueue that adds a new item to the collection and Dequeue that removes an item from the collection. Both methods receive an argument of type Object. The following code provides an example:

You just need to invoke the Dequeue method to consume and automatically remove an item from the collection. You can also invoke the Peek method which just returns the first item from the collection without removing ...
Read now
Unlock full access