title: How to automatically logout the Android app if it is not touched(inactive) for 30 mins?
body: <p>I am developing an android app.I just want that if i don't touch (InActive)my app for 30 mins ,it automatically logout.I have Activity and fragment both files.I have googled a lot and implement many codes but no one worked out.So please kindly allow me a code which could do this.And please make it clear that in which Activity and fragment i need to implement that.I will be really very thankful to you.Please reply as soon as possible.</p>