Code example for SAXNotSupportedException

0
 
  public void setFeature(String name, boolean value)
    throws ParserConfigurationException, SAXNotRecognizedException, SAXNotSupportedException 
  { 
    if (!FEATURE_NAMES.contains(name))
      throw new SAXNotSupportedException(name);
    features.put(name, value ? Boolean.TRUE : Boolean.FALSE);
  } 
 
  public boolean getFeature(String name)
    throws ParserConfigurationException, SAXNotRecognizedException, SAXNotSupportedException 
  { 
    if (!FEATURE_NAMES.contains(name))
      throw new SAXNotSupportedException(name);
    Boolean value = (Boolean) features.get(name);
    return (value == null) ? false : value.booleanValue();
  } 
 
} 
Experience pair programming with AI  Get Codota for Java