Code example for ListView

Methods: getItemAtPosition

0
        data.add(temp);
    } 
 
    @Override 
    protected void onListItemClick(ListView l, View v, int position, long id) {
        Map<String,?> map = (Map<String,?>) l.getItemAtPosition(position);
        Intent intent = (Intent) map.get("intent");
        startActivity(intent);
    } 
} 
Contextual code suggestions in your IDE  Get Codota for Java