I am new in android development and now my launcher activity show only 5 seconds and after that I want to check the user is logged in or not function and perform the actions
The best option to achieve this is using a Handler:
int TIME = 5000; //5000 ms (5 Seconds)
new Handler().postDelayed(new Runnable() {
@Override
public void run() {
function(); //call function!
}
}, TIME);