Code example for FragmentPagerAdapter

Methods: notifyDataSetChanged

0
			String tag = tabSpec.getTag();
 
			TabInfo info = new TabInfo(tag, clss, args);
			mTabs.add(info);
			mTabHost.addTab(tabSpec);
			notifyDataSetChanged(); 
		} 
 
		@Override 
		public int getCount() 
		{ 
			return mTabs.size();
		} 
 
		@Override 
		public Fragment getItem(int position)
		{ 
			TabInfo info = mTabs.get(position);
			return Fragment.instantiate(mContext, info.clss.getName(), info.args);
		} 
Connect your IDE to all the code out there  Get Codota for Java