So I was following this tutorial where I pretty much copy pasted the code from the SAX parser example. I created the same employees.xml file in the same folder as my java class. The error I get is Exception in thread "main" java.lang.IllegalArgumentException: InputStream cannot be null
on this line of code:
parser.parse(ClassLoader.getSystemResourceAsStream("employees.xml"),handler);
You can view the rest of my code here if it's of any help: pastie link
Does anyone know how to make it read the xml file properly? Or if there are any other suggestions on a good way to parse XML in java please share. Thanks