package q;

import android.os.Bundle;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

/* JADX INFO: loaded from: classes.dex */
public final class d {

    /* JADX INFO: renamed from: a, reason: collision with root package name */
    public final String f32054a;

    /* JADX INFO: renamed from: b, reason: collision with root package name */
    public final c f32055b;

    @Nullable
    public final String encodingType;

    @Nullable
    public final String method;

    public d(@NonNull String str, @Nullable String str2, @Nullable String str3, @NonNull c cVar) {
        this.f32054a = str;
        this.method = str2;
        this.encodingType = str3;
        this.f32055b = cVar;
    }

    @Nullable
    public static d fromBundle(@NonNull Bundle bundle) {
        String string = bundle.getString("androidx.browser.trusted.sharing.KEY_ACTION");
        String string2 = bundle.getString("androidx.browser.trusted.sharing.KEY_METHOD");
        String string3 = bundle.getString("androidx.browser.trusted.sharing.KEY_ENCTYPE");
        c cVarFromBundle = c.fromBundle(bundle.getBundle("androidx.browser.trusted.sharing.KEY_PARAMS"));
        if (string == null || cVarFromBundle == null) {
            return null;
        }
        return new d(string, string2, string3, cVarFromBundle);
    }
}
