package com.google.crypto.tink.shaded.protobuf;

/* loaded from: classes3.dex */
class w implements n0 {

    /* renamed from: a, reason: collision with root package name */
    private static final w f14469a = new w();

    private w() {
    }

    public static w c() {
        return f14469a;
    }

    @Override // com.google.crypto.tink.shaded.protobuf.n0
    public m0 a(Class cls) {
        if (!x.class.isAssignableFrom(cls)) {
            throw new IllegalArgumentException("Unsupported message type: " + cls.getName());
        }
        try {
            return (m0) x.p(cls.asSubclass(x.class)).i();
        } catch (Exception e10) {
            throw new RuntimeException("Unable to get message info for " + cls.getName(), e10);
        }
    }

    @Override // com.google.crypto.tink.shaded.protobuf.n0
    public boolean b(Class cls) {
        return x.class.isAssignableFrom(cls);
    }
}
