如题。在不添加依赖的情况下该如何在一个Module中调用另一个module中的Activity?
使用:
Intent intent = new Intent("myAction");
intent.setClassName("packageName", "packageName+ActivityName");
startActivity(intent);
会出现
android.content.ActivityNotFoundException: Unable to find explicit activity class
求大神赐教!
ringa_lee2017-04-17 17:34:16
If you don’t add dependencies, your module will not be compiled into your app. How can you find it? Obviously that's not possible.
怪我咯2017-04-17 17:34:16
1. There is a way to solve it. Using routing, all activities are registered in a routing table, and one key corresponds to one activity
2. Jump through the routing tool class