I have got stucked where one of my function is taking some time to execute. I have a hierarchy of objects in object using object models and ArrayList(s). I just want to know the techniques by which I can debug the code to check which statement of code is taking time in execution.
Simply use this.
long startTime = System.nanoTime();
YourMethode();
long endTime = System.nanoTime();
long MethodeDuration = (endTime - startTime);