- 28,932 files - Full Java source code - Smali files - Resources Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
33 lines
1.3 KiB
Java
33 lines
1.3 KiB
Java
package com.google.firebase.crashlytics.internal.stacktrace;
|
|
|
|
import java.util.Stack;
|
|
|
|
/* loaded from: classes3.dex */
|
|
public class TrimmedThrowableData {
|
|
public final TrimmedThrowableData cause;
|
|
public final String className;
|
|
public final String localizedMessage;
|
|
public final StackTraceElement[] stacktrace;
|
|
|
|
public TrimmedThrowableData(String str, String str2, StackTraceElement[] stackTraceElementArr, TrimmedThrowableData trimmedThrowableData) {
|
|
this.localizedMessage = str;
|
|
this.className = str2;
|
|
this.stacktrace = stackTraceElementArr;
|
|
this.cause = trimmedThrowableData;
|
|
}
|
|
|
|
public static TrimmedThrowableData makeTrimmedThrowableData(Throwable th, StackTraceTrimmingStrategy stackTraceTrimmingStrategy) {
|
|
Stack stack = new Stack();
|
|
while (th != null) {
|
|
stack.push(th);
|
|
th = th.getCause();
|
|
}
|
|
TrimmedThrowableData trimmedThrowableData = null;
|
|
while (!stack.isEmpty()) {
|
|
Throwable th2 = (Throwable) stack.pop();
|
|
trimmedThrowableData = new TrimmedThrowableData(th2.getLocalizedMessage(), th2.getClass().getName(), stackTraceTrimmingStrategy.getTrimmedStackTrace(th2.getStackTrace()), trimmedThrowableData);
|
|
}
|
|
return trimmedThrowableData;
|
|
}
|
|
}
|