I want all exceptions that may occur in the application while the user is running, send it to the Andoid Developer Console. Suppose that the exception information is sendFeedback() using the sendFeedback() method. And here the question arises: where should I place this method sendFeedback() , given that this method will be used throughout the application? And how to use it? I have two suggestions:
- in the
Applicationclass (and then in everycatch-e of eachtry-catchcall this method) - in the class that implements the
java.lang.Thread.UncaughtExceptionHandlerinterface (and then on eachThread.setDefaultUncaughtExceptionHandler(...)callThread.setDefaultUncaughtExceptionHandler(...))
How correct is it? Or are both options bad and better done somehow differently?