in my Android app I have created a ListView component called myList, and filled it with objects of my own custom type:
class MyClass{
private String di
You are implementing the Click Handler rather than Select Handler. A List by default doesn't suppose to have selection.
What you should change, in your above example, is to
public void onItemClick(AdapterView> adapter, View v, int position, long id) {
MyClass item = (MyClass) adapter.getItem(position);
}