4 ms·
Writing code against IList instead of ArrayList, or IDatabase instead of PostgresDatabase unambiguously decreases coupling.
by dustingetz 11y ago
Writing code against IList instead of ArrayList, or IDatabase instead of PostgresDatabase unambiguously decreases coupling.
- Hermel 11y agoNot if you explicitely configure the IList to be an instance of ArrayList and expect it to behave like an ArrayList. In that case, just taking an ArrayList is the more honest and more readable option.