what-the-bank/sources/com/kofax/mobile/sdk/j/f.java

53 lines
1.5 KiB
Java
Raw Permalink Normal View History

2024-07-27 18:17:47 +07:00
package com.kofax.mobile.sdk.j;
import android.graphics.Bitmap;
import android.util.LruCache;
import o.InterfaceC13391fZD;
import okhttp3.internal.ws.RealWebSocket;
/* loaded from: classes3.dex */
public class f implements com.kofax.mobile.sdk._internal.c {
private static final double zM = 0.2d;
private LruCache<String, Bitmap> zN = new LruCache<String, Bitmap>(this, jb()) { // from class: com.kofax.mobile.sdk.j.f.1
final f zO;
{
this.zO = this;
}
/* JADX INFO: Access modifiers changed from: protected */
@Override // android.util.LruCache
/* renamed from: b, reason: merged with bridge method [inline-methods] */
public int sizeOf(String str, Bitmap bitmap) {
return bitmap.getByteCount() / 1024;
}
};
@InterfaceC13391fZD
public f() {
}
private int jb() {
return (int) ((Runtime.getRuntime().maxMemory() / RealWebSocket.DEFAULT_MINIMUM_DEFLATE_SIZE) * zM);
}
@Override // com.kofax.mobile.sdk._internal.c
public boolean a(String str, Bitmap bitmap) {
if (getBitmap(str) != null) {
return false;
}
this.zN.put(str, bitmap);
return true;
}
@Override // com.kofax.mobile.sdk._internal.c
public Bitmap getBitmap(String str) {
return this.zN.get(str);
}
@Override // com.kofax.mobile.sdk._internal.c
public Bitmap w(String str) {
return this.zN.remove(str);
}
}