private synchronized boolean b(c cVar) { boolean z = true; synchronized (this) { if (cVar != null) { if (!cVar.e()) { this.c = new C0632i(this.b, cVar); this.c.a(true); } } C0596r.d(a, "initShoesConnection identity = " + cVar); z = false; } return z; }
public synchronized String d() { String str = null; synchronized (this) { c f = this.c.f(); if (!(f == null || f.e())) { cn.com.smartdevices.bracelet.shoes.model.a c = t.c(this.b, f); if (c != null) { str = com.xiaomi.hm.health.bt.b.c.SHOES.b() + kankan.wheel.widget.a.ci + c.c() + kankan.wheel.widget.a.ci + c.o(); } } } return str; }
private C0624a a(c cVar) { if (cVar == null || cVar.e()) { return null; } ConcurrentHashMap concurrentHashMap; if (this.f == null || this.f.get() == null) { ConcurrentHashMap concurrentHashMap2 = new ConcurrentHashMap(); concurrentHashMap2.put(cVar, new C0624a(this.b, cVar, this.d, this.g)); this.f = new WeakReference(concurrentHashMap2); concurrentHashMap = concurrentHashMap2; } else { concurrentHashMap = (ConcurrentHashMap) this.f.get(); } if (concurrentHashMap == null) { return null; } C0624a c0624a = (C0624a) concurrentHashMap.get(cVar); if (c0624a != null) { return c0624a; } c0624a = new C0624a(this.b, cVar, this.d, this.g); concurrentHashMap.put(cVar, c0624a); return c0624a; }
public static boolean a(Context context, c cVar) { if (context != null) { return (!cn.com.smartdevices.bracelet.shoes.sync.c.c.f(context) || cVar == null || cVar.e()) ? false : SyncShoesDataService.a(context, cVar); } else { throw new IllegalArgumentException(); } }