Interface AppMetricaPlugins


public interface AppMetricaPlugins

AppMetricaPlugins is an extension of AppMetrica.

Instance of object that implements AppMetricaPlugins can be obtained via AppMetrica.getPluginExtension() method call.

For every app process only one AppMetricaPlugins instance is created. You can either query it each time you need it, or save the reference by yourself.


NOTE: to use this extension you must activate AppMetrica first via AppMetrica.activate(android.content.Context, AppMetricaConfig).
See Also:
  • Method Details

    • reportUnhandledException

      void reportUnhandledException(@NonNull PluginErrorDetails errorDetails)
      Reports unhandled exception from plugin.
      Parameters:
      errorDetails - Object describing the exception.
      See Also:
    • reportError

      void reportError(@NonNull PluginErrorDetails errorDetails, @Nullable String message)
      Reports error from plugin. Use this method to report an unexpected situation. If you use this method errors will be grouped by errorDetails stacktrace. If you want to influence the way errors are grouped use reportError(String, String, PluginErrorDetails)
      Parameters:
      errorDetails - Object describing the error. For the error to be sent, errorDetails must contain non empty stacktrace. Otherwise it will be ignored. If you can't provide stacktrace, use reportError(String, String, PluginErrorDetails) with filled identifier.
      message - Short description or name of the error.
      See Also:
    • reportError

      void reportError(@NonNull String identifier, @Nullable String message, @Nullable PluginErrorDetails errorDetails)
      Reports error from plugin. Use this method to report an unexpected situation. This method should be used if you want to customize error grouping. If not use reportError(PluginErrorDetails, String)
      Parameters:
      identifier - An identifier used for grouping errors. Errors that have the same identifiers will belong in one group. Do not use dynamically formed strings or exception messages as identifiers to avoid having too many small crash groups.
      message - Short description or name of the error.
      errorDetails - Object describing the error.
      See Also: