Package 

Class FeedbackShakeIntegration

  • All Implemented Interfaces:
    android.app.Application.ActivityLifecycleCallbacks , io.sentry.Integration , io.sentry.SentryFeedbackOptions.IShakeController , java.io.Closeable , java.lang.AutoCloseable

    
    public final class FeedbackShakeIntegration
     implements Integration, Closeable, Application.ActivityLifecycleCallbacks, SentryFeedbackOptions.IShakeController
                        

    Detects shake gestures and shows the user feedback dialog when a shake is detected. determines the initial state; it can be toggled at runtime via {@code Sentry.feedback().enableOnShake()} and {@code * Sentry.feedback().disableOnShake()}.

    Shake detection is scoped to the resumed activity: a dialog belongs to the window of the activity that created it, so it can only ever be visible while that activity is resumed. Dialogs report themselves via onDialogVisible / onDialogGone and detection is then suppressed for the activity hosting them, which keeps a shake from stacking a second dialog on top of a visible one without letting a dialog on a backgrounded activity suppress detection elsewhere.

    • Method Summary

      Modifier and Type Method Description
      void register(@NotNull() IScopes scopes, @NotNull() SentryOptions sentryOptions)
      synchronized void enableOnShake()
      synchronized void disableOnShake()
      boolean isOnShakeEnabled()
      void close()
      void onActivityResumed(@NotNull() Activity activity)
      void onActivityPaused(@NotNull() Activity activity)
      void onActivityCreated(@NotNull() Activity activity, @Nullable() Bundle savedInstanceState)
      void onActivityStarted(@NotNull() Activity activity)
      void onActivityStopped(@NotNull() Activity activity)
      void onActivitySaveInstanceState(@NotNull() Activity activity, @NotNull() Bundle outState)
      void onActivityDestroyed(@NotNull() Activity activity)
      • Methods inherited from class io.sentry.Integration

        register
      • Methods inherited from class java.io.Closeable

        close
      • Methods inherited from class android.app.Application.ActivityLifecycleCallbacks

        onActivityCreated, onActivityDestroyed, onActivityPaused, onActivityPostCreated, onActivityPostDestroyed, onActivityPostPaused, onActivityPostResumed, onActivityPostSaveInstanceState, onActivityPostStarted, onActivityPostStopped, onActivityPreCreated, onActivityPreDestroyed, onActivityPrePaused, onActivityPreResumed, onActivityPreSaveInstanceState, onActivityPreStarted, onActivityPreStopped, onActivityResumed, onActivitySaveInstanceState, onActivityStarted, onActivityStopped
      • Methods inherited from class io.sentry.SentryFeedbackOptions.IShakeController

        disableOnShake, enableOnShake, isOnShakeEnabled
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait