Atualizando Fragmentos da Atividade em um ViewPager

Eu sou novo no desenvolvimento do Android e eu realmente aprecio alguma ajuda aqui.

Estou usando um fragmento que contém um TextView e estou usando 5 instâncias da mesma classe MyFragment.

Na atividade, eu tenho um botão e um ViewPager, e eu preciso do botão para atualizar todo o conteúdo das instâncias de fragmento, sempre que estiver clicado.

Aqui está a atividade

public class MainActivity extends FragmentActivity {

final static String[] CONTENT = {"a", "b"};
ViewPager pager;

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);
    List<MyFragment> fragments = new Vector<MyFragment>();
    for(int i = 0; i < 5; i++){
        MyFragment fragment = new MyFragment(CONTENT);
        fragments.add(fragment);
    }
    PagerAdapter adapter = new PagerAdapter(this.getSupportFragmentManager(), fragments);
    pager = (ViewPager) findViewById(R.id.viewpager);
    pager.setAdapter(adapter);

    Button button = (Button) findViewById(R.id.button);
    button.setOnClickListener(new OnClickListener() {

        @Override
        public void onClick(View v) {
            //method that isn't working
            PagerAdapter adapter = (PagerAdapter)pager.getAdapter();
            for(int i = 0; i < 5; i++){
                MyFragment fragment = (MyFragment) adapter.getItem(i);
                fragment.textView.setText(fragment.content[1]);
            }
        }
    });
}
}

O fragmento

public class MyFragment extends Fragment{

String[] content;
    TextView textView;

public MyFragment(String[] content) {
    this.content = content;
}

@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
        Bundle savedInstanceState) {
    View view = inflater.inflate(R.layout.fragment_content, container, false);
    textView = (TextView) view.findViewById(R.id.textView1);
    textView.setText(content[0]);
    return view;
}

}

E o FragmentPagerAdapter

public class PagerAdapter extends FragmentPagerAdapter{

List<MyFragment> fragments;

public PagerAdapter(FragmentManager fm, List<MyFragment> fragments) {
    super(fm);
    this.fragments = fragments;
}

@Override
public Fragment getItem(int arg0) {
    return fragments.get(arg0);
}

@Override
public int getCount() {
    return fragments.size();
}

}

O método OnClick me fornece um NullPointerException sempre que tento acessar um fragmento do adaptador que é menor que adapter.getCurrentItem () - 1 ou mais que adapter.getCurrentItem () + 1.

Alguma idéia de como atualizar todos os fragmentos ao mesmo tempo?

Desde já, obrigado.

questionAnswers(1)

yourAnswerToTheQuestion