package ca.canadapost.module.sendingexperience;

import android.util.SparseIntArray;
import android.view.View;
import androidx.databinding.d;
import androidx.databinding.e;
import androidx.databinding.n;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import nf.b;

/* loaded from: classes4.dex */
public class DataBinderMapperImpl extends d {

    /* renamed from: a, reason: collision with root package name */
    private static final SparseIntArray f10825a;

    /* loaded from: classes4.dex */
    private static class a {

        /* renamed from: a, reason: collision with root package name */
        static final HashMap f10826a;

        static {
            HashMap hashMap = new HashMap(2);
            f10826a = hashMap;
            hashMap.put("layout/activity_sending_experience_0", Integer.valueOf(mf.d.f29098a));
            hashMap.put("layout/fragment_details_0", Integer.valueOf(mf.d.f29099b));
        }
    }

    static {
        SparseIntArray sparseIntArray = new SparseIntArray(2);
        f10825a = sparseIntArray;
        sparseIntArray.put(mf.d.f29098a, 1);
        sparseIntArray.put(mf.d.f29099b, 2);
    }

    @Override // androidx.databinding.d
    public List a() {
        ArrayList arrayList = new ArrayList(3);
        arrayList.add(new androidx.databinding.library.baseAdapters.DataBinderMapperImpl());
        arrayList.add(new ca.canadapost.core.common.DataBinderMapperImpl());
        arrayList.add(new ca.canadapost.core.data.DataBinderMapperImpl());
        return arrayList;
    }

    @Override // androidx.databinding.d
    public n b(e eVar, View view, int i10) {
        int i11 = f10825a.get(i10);
        if (i11 <= 0) {
            return null;
        }
        Object tag = view.getTag();
        if (tag == null) {
            throw new RuntimeException("view must have a tag");
        }
        if (i11 == 1) {
            if ("layout/activity_sending_experience_0".equals(tag)) {
                return new b(eVar, view);
            }
            throw new IllegalArgumentException("The tag for activity_sending_experience is invalid. Received: " + tag);
        }
        if (i11 != 2) {
            return null;
        }
        if ("layout/fragment_details_0".equals(tag)) {
            return new nf.d(eVar, view);
        }
        throw new IllegalArgumentException("The tag for fragment_details is invalid. Received: " + tag);
    }

    @Override // androidx.databinding.d
    public n c(e eVar, View[] viewArr, int i10) {
        if (viewArr == null || viewArr.length == 0 || f10825a.get(i10) <= 0 || viewArr[0].getTag() != null) {
            return null;
        }
        throw new RuntimeException("view must have a tag");
    }

    @Override // androidx.databinding.d
    public int d(String str) {
        Integer num;
        if (str == null || (num = (Integer) a.f10826a.get(str)) == null) {
            return 0;
        }
        return num.intValue();
    }
}
