2021-08-03 07:33:18 +00:00
|
|
|
package f0;
|
|
|
|
|
2021-11-02 06:38:17 +00:00
|
|
|
import d0.z.d.m;
|
2021-08-03 07:33:18 +00:00
|
|
|
import java.io.IOException;
|
2021-11-02 06:38:17 +00:00
|
|
|
import kotlin.jvm.internal.DefaultConstructorMarker;
|
|
|
|
/* compiled from: Protocol.kt */
|
2022-03-07 09:34:54 +00:00
|
|
|
/* loaded from: classes3.dex */
|
2021-11-02 06:38:17 +00:00
|
|
|
public enum y {
|
|
|
|
HTTP_1_0("http/1.0"),
|
|
|
|
HTTP_1_1("http/1.1"),
|
|
|
|
SPDY_3("spdy/3.1"),
|
|
|
|
HTTP_2("h2"),
|
|
|
|
H2_PRIOR_KNOWLEDGE("h2_prior_knowledge"),
|
|
|
|
QUIC("quic");
|
|
|
|
|
2021-12-02 18:53:44 +00:00
|
|
|
public static final a q = new a(null);
|
2021-11-02 06:38:17 +00:00
|
|
|
private final String protocol;
|
|
|
|
|
|
|
|
/* compiled from: Protocol.kt */
|
2022-03-07 09:34:54 +00:00
|
|
|
/* loaded from: classes3.dex */
|
2021-11-02 06:38:17 +00:00
|
|
|
public static final class a {
|
|
|
|
public a(DefaultConstructorMarker defaultConstructorMarker) {
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
|
2021-11-02 06:38:17 +00:00
|
|
|
public final y a(String str) throws IOException {
|
|
|
|
m.checkParameterIsNotNull(str, "protocol");
|
|
|
|
y yVar = y.HTTP_1_0;
|
|
|
|
if (!m.areEqual(str, y.f(yVar))) {
|
|
|
|
yVar = y.HTTP_1_1;
|
|
|
|
if (!m.areEqual(str, y.f(yVar))) {
|
|
|
|
yVar = y.H2_PRIOR_KNOWLEDGE;
|
|
|
|
if (!m.areEqual(str, y.f(yVar))) {
|
|
|
|
yVar = y.HTTP_2;
|
|
|
|
if (!m.areEqual(str, y.f(yVar))) {
|
|
|
|
yVar = y.SPDY_3;
|
|
|
|
if (!m.areEqual(str, y.f(yVar))) {
|
|
|
|
yVar = y.QUIC;
|
|
|
|
if (!m.areEqual(str, y.f(yVar))) {
|
2021-12-17 21:59:34 +00:00
|
|
|
throw new IOException(b.d.b.a.a.v("Unexpected protocol: ", str));
|
2021-11-02 06:38:17 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return yVar;
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-03-07 09:34:54 +00:00
|
|
|
y(String str) {
|
2021-11-02 06:38:17 +00:00
|
|
|
this.protocol = str;
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
|
2021-11-02 06:38:17 +00:00
|
|
|
public static final /* synthetic */ String f(y yVar) {
|
|
|
|
return yVar.protocol;
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
|
2022-03-07 09:34:54 +00:00
|
|
|
@Override // java.lang.Enum
|
2021-11-02 06:38:17 +00:00
|
|
|
public String toString() {
|
|
|
|
return this.protocol;
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
}
|