调用底层不能直接访问的类和方法
比如:我想调用 “com.android.internal.policy.PolicyManager” 中的 “makeNewWindow”方法。
String POLICYMANAGER_CLASS_NAME = "com.android.internal.policy.PolicyManager";
try {
Class policyClass = Class.forName(POLICYMANAGER_CLASS_NAME);
Method makeNewWindow = policyClass.getMethod("makeNewWindow",
new Class[] { Context.class });
比昨天又近了一步!