package com.toughra.ustadmobile.databinding;
import com.toughra.ustadmobile.R;
import com.toughra.ustadmobile.BR;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import android.view.View;
@SuppressWarnings("unchecked")
public class FragmentClazzDetailBindingImpl extends FragmentClazzDetailBinding  {

    @Nullable
    private static final androidx.databinding.ViewDataBinding.IncludedLayouts sIncludes;
    @Nullable
    private static final android.util.SparseIntArray sViewsWithIds;
    static {
        sIncludes = new androidx.databinding.ViewDataBinding.IncludedLayouts(3);
        sIncludes.setIncludes(0, 
            new String[] {"appbar_material_tabs_scrollable"},
            new int[] {1},
            new int[] {com.toughra.ustadmobile.R.layout.appbar_material_tabs_scrollable});
        sViewsWithIds = new android.util.SparseIntArray();
        sViewsWithIds.put(R.id.fragment_clazz_detail_viewpager, 2);
    }
    // views
    // variables
    // values
    // listeners
    // Inverse Binding Event Handlers

    public FragmentClazzDetailBindingImpl(@Nullable androidx.databinding.DataBindingComponent bindingComponent, @NonNull View root) {
        this(bindingComponent, root, mapBindings(bindingComponent, root, 3, sIncludes, sViewsWithIds));
    }
    private FragmentClazzDetailBindingImpl(androidx.databinding.DataBindingComponent bindingComponent, View root, Object[] bindings) {
        super(bindingComponent, root, 1
            , (androidx.coordinatorlayout.widget.CoordinatorLayout) bindings[0]
            , (androidx.viewpager2.widget.ViewPager2) bindings[2]
            , (com.toughra.ustadmobile.databinding.AppbarMaterialTabsScrollableBinding) bindings[1]
            );
        this.coordinationLayout.setTag(null);
        setContainedBinding(this.fragmentClazzTabs);
        setRootTag(root);
        // listeners
        invalidateAll();
    }

    @Override
    public void invalidateAll() {
        synchronized(this) {
                mDirtyFlags = 0x40L;
        }
        fragmentClazzTabs.invalidateAll();
        requestRebind();
    }

    @Override
    public boolean hasPendingBindings() {
        synchronized(this) {
            if (mDirtyFlags != 0) {
                return true;
            }
        }
        if (fragmentClazzTabs.hasPendingBindings()) {
            return true;
        }
        return false;
    }

    @Override
    public boolean setVariable(int variableId, @Nullable Object variable)  {
        boolean variableSet = true;
        if (BR.loading == variableId) {
            setLoading((boolean) variable);
        }
        else if (BR.fragmentEventHandler == variableId) {
            setFragmentEventHandler((com.ustadmobile.port.android.view.ClazzDetailFragmentEventHandler) variable);
        }
        else if (BR.clazz == variableId) {
            setClazz((com.ustadmobile.lib.db.entities.Clazz) variable);
        }
        else if (BR.editButtonMode == variableId) {
            setEditButtonMode((com.ustadmobile.core.view.EditButtonMode) variable);
        }
        else if (BR.fieldsEnabled == variableId) {
            setFieldsEnabled((boolean) variable);
        }
        else {
            variableSet = false;
        }
            return variableSet;
    }

    public void setLoading(boolean Loading) {
        this.mLoading = Loading;
    }
    public void setFragmentEventHandler(@Nullable com.ustadmobile.port.android.view.ClazzDetailFragmentEventHandler FragmentEventHandler) {
        this.mFragmentEventHandler = FragmentEventHandler;
    }
    public void setClazz(@Nullable com.ustadmobile.lib.db.entities.Clazz Clazz) {
        this.mClazz = Clazz;
    }
    public void setEditButtonMode(@Nullable com.ustadmobile.core.view.EditButtonMode EditButtonMode) {
        this.mEditButtonMode = EditButtonMode;
    }
    public void setFieldsEnabled(boolean FieldsEnabled) {
        this.mFieldsEnabled = FieldsEnabled;
    }

    @Override
    public void setLifecycleOwner(@Nullable androidx.lifecycle.LifecycleOwner lifecycleOwner) {
        super.setLifecycleOwner(lifecycleOwner);
        fragmentClazzTabs.setLifecycleOwner(lifecycleOwner);
    }

    @Override
    protected boolean onFieldChange(int localFieldId, Object object, int fieldId) {
        switch (localFieldId) {
            case 0 :
                return onChangeFragmentClazzTabs((com.toughra.ustadmobile.databinding.AppbarMaterialTabsScrollableBinding) object, fieldId);
        }
        return false;
    }
    private boolean onChangeFragmentClazzTabs(com.toughra.ustadmobile.databinding.AppbarMaterialTabsScrollableBinding FragmentClazzTabs, int fieldId) {
        if (fieldId == BR._all) {
            synchronized(this) {
                    mDirtyFlags |= 0x1L;
            }
            return true;
        }
        return false;
    }

    @Override
    protected void executeBindings() {
        long dirtyFlags = 0;
        synchronized(this) {
            dirtyFlags = mDirtyFlags;
            mDirtyFlags = 0;
        }
        // batch finished
        executeBindingsOn(fragmentClazzTabs);
    }
    // Listener Stub Implementations
    // callback impls
    // dirty flag
    private  long mDirtyFlags = 0xffffffffffffffffL;
    /* flag mapping
        flag 0 (0x1L): fragmentClazzTabs
        flag 1 (0x2L): loading
        flag 2 (0x3L): fragmentEventHandler
        flag 3 (0x4L): clazz
        flag 4 (0x5L): editButtonMode
        flag 5 (0x6L): fieldsEnabled
        flag 6 (0x7L): null
    flag mapping end*/
    //end
}