code: public void setOptColor(boolean optColor) {
      checkCanSetNoArgOption("--color");
      if (optNoColor && optColor) {
        throw new IllegalArgumentException(ExceptionMessageMap.getMessage("000120")
            + "  --color cannot be used with --no-color.");
      } 
      this.optColor = optColor;
    }
docs: Checks whether the --color option should be set and sets it.
  
  @param optColor True if the --color option should be used, false otherwise.