It just seems to baffle me that every single object which exists in a document is an element. And I can’t understand the logic or benefit to having this sort of structure in place…
This is a VAST over simplification, but here it goes:
To allow content to work on multiple types of objects they have to fall in a consistent class, which for Revit is
element. Similar structures exist in other programs, ie: AutoCAD uses Object.
The reason so many fall into
Element is because almost everything wants to be able to use those common functions, such as Element.Parameters, or Element.Name. Those two alone make 99% of items want to be an ‘element’ to keep all our lives simplistic. Imagine if every time you wanted to get the parameters from a list of objects you had to type something like
try Room.Parameters, else try Wall.Parameters, else try Floor.Parameters, else try Ceiling.Parameters... until you caught every object type possible in the Revit database. Note you would have to revamp that massive ‘try except’ each year as calling a type which doesn’t exist could break your code, and that maintaining that would be problematic.
Note that there are some items in Revit which do not fall into this structure, such as Structural Connection types, Material Assets, and the like. These are very unique situations where the basic structure of a Revit file doesn’t lend itself to the data, use, or external influence. Often the use of Properties instead of Parameters is a give away that this (to some extent) the case.