Code example for PackageManager

Methods: getInstalledPackages

0
    } 
  } 
 
  @Override 
  public List<PackageInfo> getPackageList() {
    List<PackageInfo> result=
        mgr.getInstalledPackages(PackageManager.GET_SIGNATURES);
 
    Collections.sort(result, new Comparator<PackageInfo>() {
      @Override 
      public int compare(final PackageInfo a, final PackageInfo b) {
        return(a.packageName.compareTo(b.packageName));
      } 
    }); 
 
    return(result);
  } 
 
  @Override 
  public void onPackageSelected(PackageInfo pkgInfo) {
    Signature[] signatures=pkgInfo.signatures;