package h6; import c7.a; /* loaded from: classes2.dex */ final class v implements h, a.b { /* renamed from: e, reason: collision with root package name */ private static final y.e f10523e = c7.a.d(20, new a()); /* renamed from: a, reason: collision with root package name */ private final c7.c f10524a = c7.c.b(); /* renamed from: b, reason: collision with root package name */ private h f10525b; /* renamed from: c, reason: collision with root package name */ private boolean f10526c; /* renamed from: d, reason: collision with root package name */ private boolean f10527d; class a implements a.InterfaceC0061a { a() { } @Override // c7.a.InterfaceC0061a /* renamed from: b, reason: merged with bridge method [inline-methods] */ public v a() { return new v(); } } v() { } private void e() { this.f10525b = null; f10523e.a(this); } private void f(h hVar) { this.f10527d = false; this.f10526c = true; this.f10525b = hVar; } static v g(h hVar) { v vVar = (v) b7.j.d((v) f10523e.b()); vVar.f(hVar); return vVar; } @Override // h6.h public synchronized void a() { this.f10524a.c(); this.f10527d = true; if (!this.f10526c) { this.f10525b.a(); e(); } } @Override // h6.h public int b() { return this.f10525b.b(); } @Override // c7.a.b public c7.c c() { return this.f10524a; } @Override // h6.h public Class d() { return this.f10525b.d(); } @Override // h6.h public Object get() { return this.f10525b.get(); } synchronized void h() { this.f10524a.c(); if (!this.f10526c) { throw new IllegalStateException("Already unlocked"); } this.f10526c = false; if (this.f10527d) { a(); } } }