@Implements(value=com.google.android.gms.common.GooglePlayServicesUtil.class) public class ShadowGooglePlayServicesUtil extends java.lang.Object
Calls to static method of GooglePlayServicesUtil
will be redirected to the provided ShadowGooglePlayServicesUtil.GooglePlayServicesUtilImpl
implementation. Use provideImpl(GooglePlayServicesUtilImpl)
to set the implementation instance. By default, a ShadowGooglePlayServicesUtil.GooglePlayServicesUtilImpl
is used in call redirection. Use mocks or subclassing ShadowGooglePlayServicesUtil.GooglePlayServicesUtilImpl
to achieve desired behaviors.
Modifier and Type | Class and Description |
---|---|
static class |
ShadowGooglePlayServicesUtil.GooglePlayServicesUtilImpl
Class containing methods with same signatures of the static methods of
GooglePlayServicesUtil . |
Constructor and Description |
---|
ShadowGooglePlayServicesUtil() |
Modifier and Type | Method and Description |
---|---|
static android.app.Dialog |
getErrorDialog(int errorCode,
android.app.Activity activity,
int requestCode) |
static android.app.Dialog |
getErrorDialog(int errorCode,
android.app.Activity activity,
int requestCode,
android.content.DialogInterface.OnCancelListener cancelListener) |
static android.app.PendingIntent |
getErrorPendingIntent(int errorCode,
android.content.Context context,
int requestCode) |
static ShadowGooglePlayServicesUtil.GooglePlayServicesUtilImpl |
getImpl() |
static java.lang.String |
getOpenSourceSoftwareLicenseInfo(android.content.Context context) |
static android.content.Context |
getRemoteContext(android.content.Context context) |
static android.content.res.Resources |
getRemoteResource(android.content.Context context) |
static int |
isGooglePlayServicesAvailable(android.content.Context context) |
static void |
provideImpl(ShadowGooglePlayServicesUtil.GooglePlayServicesUtilImpl impl) |
static void |
reset() |
static boolean |
showErrorDialogFragment(int errorCode,
android.app.Activity activity,
android.support.v4.app.Fragment fragment,
int requestCode,
android.content.DialogInterface.OnCancelListener cancelListener) |
static boolean |
showErrorDialogFragment(int errorCode,
android.app.Activity activity,
int requestCode) |
static boolean |
showErrorDialogFragment(int errorCode,
android.app.Activity activity,
int requestCode,
android.content.DialogInterface.OnCancelListener cancelListener) |
static void |
showErrorNotification(int errorCode,
android.content.Context context) |
public static ShadowGooglePlayServicesUtil.GooglePlayServicesUtilImpl getImpl()
public static void provideImpl(ShadowGooglePlayServicesUtil.GooglePlayServicesUtilImpl impl)
@Resetter public static void reset()
@Implementation public static android.content.Context getRemoteContext(android.content.Context context)
@Implementation public static android.content.res.Resources getRemoteResource(android.content.Context context)
@Implementation public static boolean showErrorDialogFragment(int errorCode, android.app.Activity activity, android.support.v4.app.Fragment fragment, int requestCode, android.content.DialogInterface.OnCancelListener cancelListener)
@Implementation public static boolean showErrorDialogFragment(int errorCode, android.app.Activity activity, int requestCode)
@Implementation public static boolean showErrorDialogFragment(int errorCode, android.app.Activity activity, int requestCode, android.content.DialogInterface.OnCancelListener cancelListener)
@Implementation public static android.app.Dialog getErrorDialog(int errorCode, android.app.Activity activity, int requestCode)
@Implementation public static android.app.Dialog getErrorDialog(int errorCode, android.app.Activity activity, int requestCode, android.content.DialogInterface.OnCancelListener cancelListener)
@Implementation public static android.app.PendingIntent getErrorPendingIntent(int errorCode, android.content.Context context, int requestCode)
@Implementation public static java.lang.String getOpenSourceSoftwareLicenseInfo(android.content.Context context)
@Implementation public static int isGooglePlayServicesAvailable(android.content.Context context)
@Implementation public static void showErrorNotification(int errorCode, android.content.Context context)