Code example for ListFragment

Methods: setArguments

0
    	ThreadListFragment f = new ThreadListFragment();
 
        // Supply index input as an argument. 
        Bundle args = new Bundle();
        args.putInt("index", index);
        f.setArguments(args);
 
        return f;
    } 
 
    public int getShownIndex() { 
        return getArguments().getInt("index", 0);
    } 
 
     
 
	@Override 
	public void onCreate(Bundle savedInstanceState) {
		// TODO Auto-generated method stub 
		super.onCreate(savedInstanceState);
Contextual code suggestions in your IDE  Get Codota for Java