If you are looking to implement code for reopen an activity in notification click in android than follow the below code.
Example flow of the application for this type of functionality : If the application is not running and user click on notification than it will open the user dashboard and if the application is and user click on notification than it will close the dashboard activity and reopen the activity page.
Example flow of the application for this type of functionality : If the application is not running and user click on notification than it will open the user dashboard and if the application is and user click on notification than it will close the dashboard activity and reopen the activity page.