Class declaration

public class SAXPars extends DefaultHandler {...} 

Function call

 SAXParserFactory factory = SAXParserFactory.newInstance(); SAXParser parser = factory.newSAXParser(); SAXPars saxp = new SAXPars(); parser.parse(in, saxp); 

The parse method does not work

Informs that there is no method with input parameters InputStream, SAXPars

Respectively can not lead SAXPars to DefaultHandler

  • Can you formulate the problem more specifically? The code is quite a valid one. - Nofate
  • I fixed the question, now it should be clear - mr. Ball
  • 3
    And from which package do you take the DefaultHandler in the first case? Exactly from the right? - Nofate
  • Yes, thank you for this and there was a problem. import jdk.internal.org.xml.sax.helpers.DefaultHandler; need without jdk.internal. - mr. Ball

0