... and there has never been a need to group objects by
their type or runtime class, and doing that would not make the process any faster.
Sorry for my bad English.
Example:
I must will do next operations:
1. To check that all dimensions contain the correct values (not manually changed).
2. To check all text and multileader objects on compliance to a rule (regular expression) and if will be found - to do necessary changes (replace old values on new values by other regular expression).
3. To check that all text, the sizes, multileaders and hatches are on the necessary layers.
4. etc.
For the solution of these tasks, I want to lock Database for external changes, then having executed
once iteration - to create the dictionary Dictionary<string, List<ObjectId>>. Average speed of obtaining such dictionary - 1-1,5 second for 1 000 000 objects (for my computer). But then, having received the objects of ObjectId grouped in type, it will be simpler to me to carry out the tasks. For example, it is convenient to use LINQ for collection processing. After task performance I will unlock Database.