diff --git a/BuildingCoder/BuildingCoder/CmdCollectorPerformance.cs b/BuildingCoder/BuildingCoder/CmdCollectorPerformance.cs
index 37d0f81d..0d7ab75d 100644
--- a/BuildingCoder/BuildingCoder/CmdCollectorPerformance.cs
+++ b/BuildingCoder/BuildingCoder/CmdCollectorPerformance.cs
@@ -287,6 +287,25 @@ class CmdCollectorPerformance : IExternalCommand
{
Document _doc;
+ #region Get all model elements
+ ///
+ /// Return all model elements, cf.
+ /// http://forums.autodesk.com/t5/revit-api/traverse-all-model-elements-in-a-project-top-down-approach/m-p/5815247
+ ///
+ IEnumerable GetAllModelElements(
+ Document doc )
+ {
+ Options opt = new Options();
+
+ return new FilteredElementCollector( doc )
+ .WhereElementIsNotElementType()
+ .WhereElementIsViewIndependent()
+ .Where( e
+ => null != e.Category
+ && null != e.get_Geometry( opt ) );
+ }
+ #endregion // Get all model elements
+
#region Traverse all model elements top down Levels > Category > Family > Type > Instance
void TraverseInstances( Document doc )
{
diff --git a/BuildingCoder/BuildingCoder/Properties/AssemblyInfo.cs b/BuildingCoder/BuildingCoder/Properties/AssemblyInfo.cs
index 408e4e22..ac3ee92c 100644
--- a/BuildingCoder/BuildingCoder/Properties/AssemblyInfo.cs
+++ b/BuildingCoder/BuildingCoder/Properties/AssemblyInfo.cs
@@ -106,6 +106,7 @@
// 2015-09-04 2016.0.120.10 added original EditFilledRegion to show code improvements
// 2015-09-04 2016.0.120.11 in EditFilledRegion: foreach iter, using tx, single tx, XYZ static member
// 2015-09-04 2016.0.120.12 in EditFilledRegion: use MoveElements instead of MoveElement
+// 2015-09-14 2016.0.120.13 implemented GetAllModelElements
//
-[assembly: AssemblyVersion( "2016.0.120.12" )]
-[assembly: AssemblyFileVersion( "2016.0.120.12" )]
+[assembly: AssemblyVersion( "2016.0.120.13" )]
+[assembly: AssemblyFileVersion( "2016.0.120.13" )]