Strategy design pattern
Jun 26, 2024 · 1 min read · A strategy pattern is a behavioral design pattern that allows the behavior of an object to be selected at runtime. public interface TripStrategy { void travel(); } public class LongTripStrategy implements TripStrategy{ @Override public...
Join discussion