dedlfix: Logging in class Diagram Uml Architectur

Beitrag lesen

Tach!

It's better to use a Logger-Object and pass it to the objects you create.

Yes, usually a logger isn't a core part of business classes. It is more a dependency. If injected via Dependency Injection then there is no need to have a super class that contains infrastructural things besides the business case. This solves both problems: no need for a base class, and it can be replaced for unit tests.

dedlfix.