Check out example codes for "fragment manager in android". It will help you in understanding the concepts better.

Code Example 1

Intent intent = new Intent(v.getContext(), Addbill.class);
        v.getContext().startActivity(intent);
        getActivity().finish();

Learn ReactJs, React Native from akashmittal.com