@Test public void testEnabledDealerFeatures() { Features feat = new Features(); assertThat(feat.enabledDealerFeatures()) .containsExactly(Feature.DEALER_CALLER_IDENTIFICATION); feat.disable(Feature.DEALER_CALLER_IDENTIFICATION); assertThat(feat.enabledDealerFeatures()).isEmpty(); }
public List<Feature> enabledDealerFeatures() { List<Feature> dealerFeatures = new ArrayList<>(); if (isEnabled(Feature.DEALER_CALLER_IDENTIFICATION)) { dealerFeatures.add(Feature.DEALER_CALLER_IDENTIFICATION); } return dealerFeatures; }
Features { public List<Feature> enabledDealerFeatures() { List<Feature> dealerFeatures = new ArrayList<>(); if (isEnabled(Feature.DEALER_CALLER_IDENTIFICATION)) { dealerFeatures.add(Feature.DEALER_CALLER_IDENTIFICATION); } return dealerFeatures; } }
Features { public List<Feature> enabledDealerFeatures() { List<Feature> dealerFeatures = new ArrayList<>(); if (isEnabled(Feature.DEALER_CALLER_IDENTIFICATION)) { dealerFeatures.add(Feature.DEALER_CALLER_IDENTIFICATION); } return dealerFeatures; }  }
Features { public List<Feature> enabledDealerFeatures() { List<Feature> dealerFeatures = new ArrayList<>(); if (isEnabled(Feature.DEALER_CALLER_IDENTIFICATION)) { dealerFeatures.add(Feature.DEALER_CALLER_IDENTIFICATION); } return dealerFeatures; }  void disable(Feature feature); boolean isEnabled(Feature feature); boolean isDisabled(Feature feature); List<Feature> enabledDealerFeatures(); List<Feature> enabledBrokerFeatures(); }
Features { public List<Feature> enabledDealerFeatures() { List<Feature> dealerFeatures = new ArrayList<>(); if (isEnabled(Feature.DEALER_CALLER_IDENTIFICATION)) { dealerFeatures.add(Feature.DEALER_CALLER_IDENTIFICATION); } return dealerFeatures; }  void disable(Feature feature); boolean isEnabled(Feature feature); boolean isDisabled(Feature feature); List<Feature> enabledDealerFeatures(); List<Feature> enabledBrokerFeatures();  }