May 2010
Intermediate to advanced
1272 pages
61h 18m
English
Partitioning operators allow accomplishing a technique known as paging, which is common in data access scenarios. There are two main operators in LINQ: Skip and Take, in which Skip avoids selecting the specified number of elements, and Take puts the specified number of elements into a sequence. Code in Listing 24.3 shows an example of paging implementation using the two operators.
Listing 24.3 Implementing a Basic Paging Technique


The private field pageCount acts as a counter. According to its value, the query skips the number ...
Read now
Unlock full access