Android Context Check isAppInstalled(Context context)

Here you can find the source of isAppInstalled(Context context)

Description

is App Installed

Declaration

public static final boolean isAppInstalled(Context context) 

Method Source Code

//package com.java2s;
import android.content.Context;

import android.content.pm.PackageManager;
import android.content.pm.PackageManager.NameNotFoundException;

public class Main {
    public static final String PACKAGE_NAME = "org.c_base.c_beam";

    public static final boolean isAppInstalled(Context context) {
        PackageManager manager = context.getPackageManager();
        try {/*from   ww w .  ja v a2  s .  c  o m*/
            manager.getPackageInfo(PACKAGE_NAME, 0);
            return true;
        } catch (NameNotFoundException e) {
            return false;
        }
    }
}

Related

  1. hasOtherSPAppsInstalled(Context context)
  2. hasTelephony(@Nonnull Context context)
  3. hasVibrationPermission(Context context)
  4. is3G(Context context)
  5. isAccessibilityEnabled(Context context, String id)
  6. isAppInstalled(Context context, String uri)
  7. isAppOnForeground(Context context)
  8. isApplicationBroughtToBackground( final Context context)
  9. isApplicationBroughtToBackground( final Context context)