Get an activity's ResolveInfo object knowing it's name?

view story

http://stackoverflow.com РI want to add my activity (com.myapp.launcher.settings) to an empty ArrayList. ArrayList<ResolveInfo> selectedApps = new ArrayList<ResolveInfo>(); selectedApps.add(/*WHAT GOES IN HERE?*/); But I don't know how to get a ResolveInfo object with my activity. I managed to make a workaround that loops through all apps to find my activity. But it's not very efficient or practical: // Get an array list of all apps     ArrayList<ResolveInfo> allApps = (ArrayList<ResolveInfo>) pm.queryIntentActivities(intent, PackageManager.PERMISSION_GRANTED); for(final (HowTos)