Strategy

This is a class diagram for strategic design pattern.

Purpose

Defines a set of encapsulated algorithms that can be swapped to carry out a specific behavior.

Use When

  • The only difference between many related classes is their behavior.
  • Multiple versions or variations of an algorithm are required.
  • Algorithms access or utilize data that calling code shouldn't be exposed to.
  • The behavior of a class should be defined at runtime.
  • Conditional statements are complex and hard to maintain.
Import into your Project

Posted by: Shirley Langley

Turn every software project into a successful one.

Try Visual Paradigm for Free! Or learn more about our features.

Leave a Reply

Be the First to Comment!

avatar