This question is marked as “Android,” and I noticed that you mentioned Activity, so I'm going to assume that you are trying to load an XML file in an Android application. If so, put your XML file under /assetsand call:
InputStream is = getAssets().open("input.xml")
Activity. SAXBuilder. , ( unit test).