If an abstract class does not have fields. Should it be made into an interface? Why ObjectPool is not? #102616
Unanswered
zms9110750
asked this question in
General
Replies: 1 comment 2 replies
-
Classes can gain new members version to version. Interfaces, for the most part, can't. (Default Interface Methods change this slightly, but not fully). Framework Design Guidelines recommend abstract classes over interfaces, unless you have a really good reason for an interface. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
https://github.com/dotnet/aspnetcore/blob/8486d31e24f30e3fa1809a95699a0adc16f448d7/src/ObjectPool/src/ObjectPool.cs
Is this some kind of historical legacy, or is there indeed a design concept that I don't know about?
Beta Was this translation helpful? Give feedback.
All reactions