Esempio n. 1
0
    public override void ReportUnhandledException(Exception exception)
    {
        try
        {
            ReportUnhandledException(YandexAppMetricaErrorDetails.From(exception));
        }
        catch (Exception e)
        {
#if DEBUG
            Debug.Log("[AppMetrica] Failed to parse stacktrace: " + e.Message + "\n" + e.StackTrace);
#endif
            // use old crash format
            ymm_reportError(exception.Message, exception.StackTrace);
        }
    }
Esempio n. 2
0
    public override void ReportUnhandledException(Exception exception)
    {
        try
        {
            ReportUnhandledException(YandexAppMetricaErrorDetails.From(exception));
        }
        catch (Exception e)
        {
#if DEBUG
            Debug.Log("[AppMetrica] Failed to parse stacktrace: " + e.Message + "\n" + e.StackTrace);
#endif
            // use old crash format
            CallAppMetrica("reportUnhandledException", new[] { "Throwable" },
                           exception.ToAndroidThrowable());
        }
    }
Esempio n. 3
0
    public override void ReportError(string groupIdentifier, string condition, Exception exception)
    {
        try
        {
            ReportError(groupIdentifier, condition,
                        exception == null ? null : YandexAppMetricaErrorDetails.From(exception));
        }
        catch (Exception e)
        {
#if DEBUG
            Debug.Log("[AppMetrica] Failed to parse stacktrace: " + e.Message + "\n" + e.StackTrace);
#endif
            // use old crash format
            ymm_reportErrorWithException(groupIdentifier, condition, JsonStringFromDictionary(exception.ToHashtable()));
        }
    }
Esempio n. 4
0
    public override void ReportError(string groupIdentifier, string condition, Exception exception)
    {
        try
        {
            ReportError(groupIdentifier, condition,
                        exception == null ? null : YandexAppMetricaErrorDetails.From(exception));
        }
        catch (Exception e)
        {
#if DEBUG
            Debug.Log("[AppMetrica] Failed to parse stacktrace: " + e.Message + "\n" + e.StackTrace);
#endif
            // use old crash format
            CallAppMetrica("reportError", new[] { "String", "String", "Throwable" },
                           groupIdentifier, condition, exception.ToAndroidThrowable());
        }
    }