package com.ss.android.ugc.aweme.mix.createmix.viewmodel;

import X.4HR;
import X.AY9;
import X.AYH;
import X.AYI;
import X.AYJ;
import X.AYK;
import X.AYL;
import X.AYM;
import X.AYP;
import X.C1163AUt;
import X.C1822AiQ;
import X.Crj;
import X.D65;
import X.M12;
import com.bytedance.assem.arch.viewModel.AssemViewModel;
import com.bytedance.covode.number.Covode;
import com.ss.android.ugc.aweme.feed.model.Aweme;
import java.util.Collections;
import java.util.List;

public final class MixCreateViewModel extends AssemViewModel<AYH> implements C1822AiQ {
    public static final AYM LJ = new AYM((byte) 0);
    public String LIZ = "";
    public String LIZIZ = "";
    public String LIZJ = "";
    public Aweme LIZLLL;
    public final Crj LJFF = D65.LIZ(this, C1163AUt.LIZ);

    static {
        Covode.recordClassIndex(92383);
    }

    public final String LIZIZ() {
        return "create_playlist";
    }

    public final String LIZ() {
        return this.LIZIZ;
    }

    public final /* synthetic */ 4HR defaultState() {
        return new AYH();
    }

    public final void LIZLLL() {
        withState(new AYP(this));
    }

    public final String LIZJ() {
        String str = getVmDispatcher().LIZ().LJ;
        if (str == null) {
            return "";
        }
        return str;
    }

    public final void LIZ(AY9 ay9) {
        M12.LIZ(ay9);
        setState(new AYI(ay9));
    }

    public final void LIZIZ(String str) {
        M12.LIZ(str);
        setStateImmediate(new AYL(str));
    }

    public final void LIZ(String str) {
        M12.LIZ(str);
        setState(new AYK(str));
        this.LIZ = str;
    }

    public final void LIZ(boolean z) {
        setState(new AYJ(z));
    }

    public final void LIZ(int i, int i2) {
        List<Aweme> list;
        if (i != i2 && (list = getVmDispatcher().LIZ().LIZJ) != null) {
            Collections.swap(list, i, i2);
        }
    }
}
