Back to list
Views:   0
Replies:  0
Reply 1

What you describe is certainly not the Strategy Pattern. In Strategy all classes (of the strategy) have the same interface. 

What you have is inheritance. The 'superior' should derive from 'standard' and then possibly override some virtual functions and add some additional methods and behavior. I am not sure if there is another pattern that can help you. Perhaps the State pattern, but it all depends on your requirements. 

Since 'standard' and 'superior' are so very different you would ideally place a single IF statement somewhere in your logic and then have two entirely self-contained components that handle the particular situation. So, you apply some form of refactoring. 

Hope this helps. 

Deshaun Hyram, Jun 10, 2013
Stay Inspired!
Join other developers and designers who have already signed up for our mailing list.
Terms     Privacy     Licensing       EULA       Sitemap      
© Data & Object Factory, LLC.
Made with    in Austin, Texas