Code example for FragmentActivity

 * in a {@link PersonListActivity}. 
 * <p> 
 * This activity is mostly just a 'shell' activity containing nothing 
 * more than a {@link PersonDetailFragment}. 
public class PersonDetailActivity extends FragmentActivity { 
    protected void onCreate(Bundle savedInstanceState) {
        // Show the Up button in the action bar. 
        // savedInstanceState is non-null when there is fragment state 
        // saved from previous configurations of this activity 
        // (e.g. when rotating the screen from portrait to landscape). 
        // In this case, the fragment will automatically be re-added 
        // to its container so we don't need to manually add it.