public static ProfileFragment newInstance(boolean showTabBar){
  ProfileFragment fragment=new ProfileFragment();
  Bundle args=new Bundle();
  args.putBoolean(SHOW_TAB_BAR,showTabBar);
  fragment.setArguments(args);
  return fragment;
}

public static ProfileFragment newInstance ( boolean showTabBar ) { ProfileFragment fragment = new ProfileFragment ( ) ; Bundle args = new Bundle ( ) ; args . putBoolean ( SHOW_TAB_BAR , showTabBar ) ; fragment . setArguments ( args ) ; return fragment ; }
use this factory method to create a new instance of this fragment using the provided parameters .
