开发者

what is the android exception that best fits this scenario?

PackageManager pm = context.getPackageManager();
List<ResolveInfo> apps = 
    pm.queryIntentActivities(viewDocIntent, PackageManager.MATCH_DEFAULT_ONLY);

if (apps.size() &开发者_Python百科gt; 0)
    context.startActivity(viewDocIntent);
else
    throw new ... SOMETHING

Which exception would you think should be thrown if the resulting list is empty?


ActivityNotFoundException.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜