Maximiliano Contieri
1 min readSep 12, 2020

--

Thank you !

I don’t know which language you are using but I’m certain it is not coupled to ONE operating system.

There’s only one operating system which is passed to you as context. Malloc() and Free() are Operating System dependant so the compiler manages this context for you.

I don’t know much about game development. If you use Untiy Physics engine as Singleton you will not be able to mock it with a fake Physics engine. You just couple to it and trust everything will be right.

Lastly. I agree with treating everything as a service.

I disagree to couple to them by calling SingletonTranslationService::getInstance()

Who provides that service ? can you mock it ? can you put a decorator before it ? can you put a spy ? You can do all those things and much more if you break this hard binding

--

--

Maximiliano Contieri
Maximiliano Contieri

Written by Maximiliano Contieri

I’m a senior software engineer specialized in declarative designs. S.O.L.I.D. and agile methodologies fan. Maximilianocontieri.com

Responses (1)