@Override
        public void finish() {
          boolean modifiedBack = active ? state.remove(ruleId) : state.add(ruleId);
          assert modifiedBack;
        }
@Override
        public void finish()