code: public static ItemRuleMap toItemRuleMap(List<ItemParameters> itemParametersList) throws IllegalRuleException {
          if (itemParametersList == null || itemParametersList.isEmpty()) {
              return null;
          }
          ItemRuleMap itemRuleMap = new ItemRuleMap();
          for (ItemParameters parameters : itemParametersList) {
              itemRuleMap.putItemRule(toItemRule(parameters));
          }
          return itemRuleMap;
      }
docs: Convert the given item parameters list into an {@code ItemRuleMap}.
  
  @param itemParametersList the item parameters list to convert
  @return the item rule map
  @throws IllegalRuleException if an illegal rule is found