package o;

/* compiled from: r8-map-id-3b7cc9102578c509342fa2f0fabed2bfc72239cd258d579fc679bfcbc198b048 */
/* loaded from: classes.dex */
public final class AD implements InterfaceC1761lP {
    public static final AD b = new AD(0);
    public final /* synthetic */ int a;

    public /* synthetic */ AD(int i) {
        this.a = i;
    }

    @Override // o.InterfaceC1761lP
    public final C1059e00 a(Class cls) {
        switch (this.a) {
            case 0:
                if (!DD.class.isAssignableFrom(cls)) {
                    throw new IllegalArgumentException("Unsupported message type: ".concat(cls.getName()));
                }
                try {
                    return (C1059e00) DD.d(cls.asSubclass(DD.class)).c(3);
                } catch (Exception e) {
                    throw new RuntimeException("Unable to get message info for ".concat(cls.getName()), e);
                }
            default:
                throw new IllegalStateException("This should never be called.");
        }
    }

    @Override // o.InterfaceC1761lP
    public final boolean b(Class cls) {
        switch (this.a) {
            case 0:
                return DD.class.isAssignableFrom(cls);
            default:
                return false;
        }
    }
}
