Clarification on the Strategy Pattern

Posted by Holly on Programmers See other posts from Programmers or by Holly
Published on 2012-11-10T15:06:07Z Indexed on 2012/11/10 23:17 UTC
Read the original article Hit count: 244

Filed under:
|

I've just been reading through some basic design patterns,

Could someone tell me if the term "strategy pattern" only applies if your implementing a completely abstract interface?

What about when your children (concretes?) inherit from a parent class (the strategy?) with some implemented methods and some virtual and/or abstract functions? Otherwise the rest of the implementation, the idea that you can switch between different children at run time, is identical. This is something i'm quite familiar with, i was wondering if you would still call it the Strategy Pattern or if that term only applies to using an interface.

Apologies if this question is not appropriate! Or if this is just nitpicking :) I'm still learning and i'm not really sure if design patterns are quite heavily defined within the industry or just a concept to be implemented as you like.

© Programmers or respective owner

Related posts about c++

Related posts about design-patterns