class FeatureActivator {

    public void changeStateOf(String code, boolean newState) {
        if (this.currentStates.containsKey(code)) {
            log.info("Switching state of {} to {}.", code, newState ? "ENABLED" : "DISABLED");
            this.currentStates.put(code, newState);
        }
    }

}