docs: private void updateRequiredOptions(Option option) throws AlreadySelectedException
      {
          if (option.isRequired())
          {
              expectedOpts.remove(option.getKey());
          }
  
          // if the option is in an OptionGroup make that option the selected option of the group
          if (options.getOptionGroup(option) != null)
          {
              OptionGroup group = options.getOptionGroup(option);
  
              if (group.isRequired())
              {
                  expectedOpts.remove(group);
              }
  
              group.setSelected(option);
          }
      }