Pause & Resume with Android MediaRecorder (API level < 24)

I could solve this problem using mp4parser library. Thanks much to author of this library 🙂 Add below dependency in your gradle file: compile ‘com.googlecode.mp4parser:isoparser:1.0.2’ The solution is to stop recorder when user pause and start again on resume as already mentioned in many other answers in stackoverflow. Store all the audio/video files generated in … Read more

Merging xml file using java NodeList

In order to do that on your own. You should do this following : public static void mergeXML(){ DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = null; Document doc = null; Document doc2 = null; try { db = dbf.newDocumentBuilder(); doc = db.parse(new File(“D:\\Loic_Workspace\\Test2\\res\\test.xml”)); doc2 = db.parse(new File(“D:\\Loic_Workspace\\Test2\\res\\test2.xml”)); NodeList ndListFirstFile = doc.getElementsByTagName(“staff”); Node nodeArea = doc.importNode(doc2.getElementsByTagName(“area”).item(0), … Read more