package com.airbnb.epoxy;

import X.AnonymousClass0I8;
import X.AnonymousClass0IB;
import X.AnonymousClass0IG;
import com.bytedance.covode.number.Covode;
import java.util.List;

public class SimpleEpoxyController extends AnonymousClass0I8 {
    public List<? extends AnonymousClass0IB<?>> currentModels;
    public boolean insideSetModels;

    static {
        Covode.recordClassIndex(1956);
    }

    public final void requestModelBuild() {
        if (this.insideSetModels) {
            super.requestModelBuild();
            return;
        }
        throw new AnonymousClass0IG("You cannot call `requestModelBuild` directly. Call `setModels` instead.");
    }

    public final void buildModels() {
        if (isBuildingModels()) {
            add(this.currentModels);
            return;
        }
        throw new AnonymousClass0IG("You cannot call `buildModels` directly. Call `setModels` instead.");
    }

    public void setModels(List<? extends AnonymousClass0IB<?>> list) {
        this.currentModels = list;
        this.insideSetModels = true;
        requestModelBuild();
        this.insideSetModels = false;
    }
}
