docs: private void setRule(String name, String value) throws InvalidArgumentException, XmlPullParserException {
      if (value.length() > 1024) {
        throw new InvalidArgumentException("value '" + value + "' is more than 1024 long");
      }
  
      for (FilterRule rule: filterRuleList) {
        // Remove rule.name is same as given name.
        if (rule.name().equals(name)) {
          filterRuleList.remove(rule);
        }
      }
  
      FilterRule newRule = new FilterRule();
      newRule.setName(name);
      newRule.setValue(value);
      filterRuleList.add(newRule);
    }