http://www.charlesandhudson.com/archives/hand-tools-list-important.jpgPPT_LOGO_4b
‹#›
Autodesk Developer Network, April 2010
The Rice – New Element Iteration Interfaces
§Iterate and filter elements from a document, or only elements from a list of element ids
§High performance filters which do not expand the element in memory for evaluation
§Chained shortcuts which apply common filters
§Group more than two filters
§Match derived types automatically with the type filter
§Iterate elements from all design options or from specific design options
§Use foreach on the collector element
§LINQ query compatible
C:\Documents and Settings\walmslk\Local Settings\Temporary Internet Files\Content.IE5\EARWAUQM\MPj04096740000[1].jpg
This iteration interface provides greater performance. You can get a list of elements from the document or a list of element ids. We shall also identify some high performance filters.

Revit internally has some elements in memory that are not expanded. So typically Revit has to expand those to perform certain iterations and that consumes some of the cycles. The unexpanded bit of each element does contain some information and so this release is expected to provide some services in case you have to read some information off an element, it does not have to expand the element in memory and get the information out for you and thus providing a performance advantage. We can now chain up the filters if we want to provide some combination of filters in sequence.

…
…
…