-
ER-214 Heterogenous Collection detected: The code adds objects of different types in a collection. This can cause serious mainteance issues.
The creator and consumer of the collection have to have implicit knowledge about the index of a specific object inside of the collection.
Go with a dedicated parameter or Data Transfer Object instead.
There is only one exception for using Heterogenous Collection: If all objects in the collection implement a specific interface, this is acceptable.
-
Severity | 1 |
Enabled | yes |
Waivable | |
Violation |
|
Fix |
|
Hammurapi 3 Copyright © 2004 Hammurapi Group. All Rights Reserved.