Should I use a strategy template or adapter template?
This is a classic mistake that everyone makes when developing an application (including me). Ideally, you should not look at the list of available design templates and choose the one that best suits your problem. Instead, you should come up with a starting class, and then try to determine the template that best describes your design. This protects you from over-designing i.e. Creating unnecessary components that you would otherwise not need. Over time, you will soon have a dictionary of design templates that you used, and not an application that tries to use a specific design template.
, , , /. , .
, "" , shutdown, connect, retry .. , AWSProvider LinodeProvider shutdown, connect retry. , API . , powerOff shutdown LinodeProvider.
, , , Aadpter. , , - , . , Factory , ; , , . , .
, , , , .