获取APK信息

  
        PackageManager pm = context.getPackageManager();   
        PackageInfo info = pm.getPackageArchiveInfo(filePath, PackageManager.GET_ACTIVITIES);   
        if(info != null){   
            ApplicationInfo appInfo = info.applicationInfo;   
            String appName = pm.getApplicationLabel(appInfo).toString();   
            String packageName = appInfo.packageName;   
         
        }   
 

posted on 2010-08-18 20:45  lbeing  阅读(443)  评论(0编辑  收藏  举报

导航