override
, final
, public
(while inheritance) just to make code compact & consumable(most of the time) in single standard screen size. I also prefer struct
instead of class
just to save line by not writing “public:
” sometimes and also miss virtual destructor, constructor, copy constructor, prefix std::
, deleting dynamic memory, intentionally. I also consider myself a pragmatic person who wants to convey an idea in the simplest way possible rather than the standard way or using Jargons.TextProcessor::m_list_strategy
which we can use to change the strategy on the fly.add_list_item()
) through virtual table(rather passing it as a C++ template parameter) which means you do not have the ability to change your algorithm/strategy at runtime.