Files
rr3-apk/decompiled/sources/com/google/firebase/crashlytics/internal/metadata/RolloutAssignment.java
Daniel Elliott f9d20bb3fc Add decompiled APK source code (JADX)
- 28,932 files
- Full Java source code
- Smali files
- Resources

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-02-18 14:52:23 -08:00

39 lines
1.8 KiB
Java

package com.google.firebase.crashlytics.internal.metadata;
import com.google.firebase.crashlytics.internal.model.CrashlyticsReport;
import com.google.firebase.encoders.DataEncoder;
import com.google.firebase.encoders.json.JsonDataEncoderBuilder;
import org.json.JSONObject;
/* loaded from: classes3.dex */
public abstract class RolloutAssignment {
public static final DataEncoder ROLLOUT_ASSIGNMENT_JSON_ENCODER = new JsonDataEncoderBuilder().configureWith(AutoRolloutAssignmentEncoder.CONFIG).build();
public abstract String getParameterKey();
public abstract String getParameterValue();
public abstract String getRolloutId();
public abstract long getTemplateVersion();
public abstract String getVariantId();
public static RolloutAssignment create(String str, String str2, String str3, String str4, long j) {
return new AutoValue_RolloutAssignment(str, str2, validate(str3), str4, j);
}
public static RolloutAssignment create(String str) {
JSONObject jSONObject = new JSONObject(str);
return create(jSONObject.getString("rolloutId"), jSONObject.getString("parameterKey"), jSONObject.getString("parameterValue"), jSONObject.getString("variantId"), jSONObject.getLong("templateVersion"));
}
public CrashlyticsReport.Session.Event.RolloutAssignment toReportProto() {
return CrashlyticsReport.Session.Event.RolloutAssignment.builder().setRolloutVariant(CrashlyticsReport.Session.Event.RolloutAssignment.RolloutVariant.builder().setVariantId(getVariantId()).setRolloutId(getRolloutId()).build()).setParameterKey(getParameterKey()).setParameterValue(getParameterValue()).setTemplateVersion(getTemplateVersion()).build();
}
public static String validate(String str) {
return str.length() > 256 ? str.substring(0, 256) : str;
}
}