package com.bytedance.ies.nle.editor_jni;

import com.bytedance.covode.number.Covode;
import com.bytedance.frameworks.apm.trace.MethodCollector;

public class NLETemplateModel extends NLEModel {
    public transient boolean swigCMemOwnDerived;
    public transient long swigCPtr;

    static {
        Covode.recordClassIndex(29887);
    }

    public void finalize() {
        delete();
    }

    public static String NLE_TEMPLATE_JSON_FILENAME() {
        MethodCollector.i(12790);
        String NLETemplateModel_NLE_TEMPLATE_JSON_FILENAME = NLETemplateJNI.NLETemplateModel_NLE_TEMPLATE_JSON_FILENAME();
        MethodCollector.o(12790);
        return NLETemplateModel_NLE_TEMPLATE_JSON_FILENAME;
    }

    public String store() {
        MethodCollector.i(12998);
        String NLETemplateModel_store = NLETemplateJNI.NLETemplateModel_store(this.swigCPtr, this);
        MethodCollector.o(12998);
        return NLETemplateModel_store;
    }

    public NLETemplateModel() {
        this(NLETemplateJNI.new_NLETemplateModel(), true);
        MethodCollector.i(12789);
        MethodCollector.o(12789);
    }

    public static VecUInt32 getSupportFeatureBits() {
        MethodCollector.i(7878);
        VecUInt32 vecUInt32 = new VecUInt32(NLETemplateJNI.NLETemplateModel_getSupportFeatureBits());
        MethodCollector.o(7878);
        return vecUInt32;
    }

    public NLENode clone() {
        MethodCollector.i(12525);
        long NLETemplateModel_clone = NLETemplateJNI.NLETemplateModel_clone(this.swigCPtr, this);
        if (NLETemplateModel_clone == 0) {
            MethodCollector.o(12525);
            return null;
        }
        NLENode nLENode = new NLENode(NLETemplateModel_clone, true);
        MethodCollector.o(12525);
        return nLENode;
    }

    public VecNLENode getAllMutableItems() {
        MethodCollector.i(9276);
        VecNLENode vecNLENode = new VecNLENode(NLETemplateJNI.NLETemplateModel_getAllMutableItems(this.swigCPtr, this));
        MethodCollector.o(9276);
        return vecNLENode;
    }

    public VecNLETrackSlotSPtr getMutableAssetItems() {
        MethodCollector.i(8895);
        VecNLETrackSlotSPtr vecNLETrackSlotSPtr = new VecNLETrackSlotSPtr(NLETemplateJNI.NLETemplateModel_getMutableAssetItems(this.swigCPtr, this));
        MethodCollector.o(8895);
        return vecNLETrackSlotSPtr;
    }

    public VecNLETrackSlotSPtr getMutableTextItems() {
        MethodCollector.i(9077);
        VecNLETrackSlotSPtr vecNLETrackSlotSPtr = new VecNLETrackSlotSPtr(NLETemplateJNI.NLETemplateModel_getMutableTextItems(this.swigCPtr, this));
        MethodCollector.o(9077);
        return vecNLETrackSlotSPtr;
    }

    public NLESize getTemplateCanvasSize() {
        MethodCollector.i(9485);
        NLESize nLESize = new NLESize(NLETemplateJNI.NLETemplateModel_getTemplateCanvasSize(this.swigCPtr, this));
        MethodCollector.o(9485);
        return nLESize;
    }

    public TemplateInfo getTemplateInfo() {
        MethodCollector.i(12527);
        long NLETemplateModel_getTemplateInfo = NLETemplateJNI.NLETemplateModel_getTemplateInfo(this.swigCPtr, this);
        if (NLETemplateModel_getTemplateInfo == 0) {
            MethodCollector.o(12527);
            return null;
        }
        TemplateInfo templateInfo = new TemplateInfo(NLETemplateModel_getTemplateInfo);
        MethodCollector.o(12527);
        return templateInfo;
    }

    public synchronized void delete() {
        MethodCollector.i(12300);
        long j = this.swigCPtr;
        if (j != 0) {
            if (this.swigCMemOwnDerived) {
                this.swigCMemOwnDerived = false;
                NLETemplateJNI.delete_NLETemplateModel(j);
            }
            this.swigCPtr = 0;
        }
        super.delete();
        MethodCollector.o(12300);
    }

    public static long getCPtr(NLETemplateModel nLETemplateModel) {
        if (nLETemplateModel == null) {
            return 0;
        }
        return nLETemplateModel.swigCPtr;
    }

    public void swigSetCMemOwn(boolean z) {
        this.swigCMemOwnDerived = z;
        super.swigSetCMemOwn(z);
    }

    public static int getFeatureIndex(String str) {
        MethodCollector.i(8105);
        int NLETemplateModel_getFeatureIndex = NLETemplateJNI.NLETemplateModel_getFeatureIndex(str);
        MethodCollector.o(8105);
        return NLETemplateModel_getFeatureIndex;
    }

    public static NLETemplateModel createFromDraft(NLEModel nLEModel) {
        NLETemplateModel nLETemplateModel;
        MethodCollector.i(7690);
        long NLETemplateModel_createFromDraft = NLETemplateJNI.NLETemplateModel_createFromDraft(NLEModel.getCPtr(nLEModel), nLEModel);
        if (NLETemplateModel_createFromDraft == 0) {
            nLETemplateModel = null;
        } else {
            nLETemplateModel = new NLETemplateModel(NLETemplateModel_createFromDraft, true);
        }
        MethodCollector.o(7690);
        return nLETemplateModel;
    }

    public static NLETemplateModel dynamicCast(NLENode nLENode) {
        NLETemplateModel nLETemplateModel;
        MethodCollector.i(12524);
        long NLETemplateModel_dynamicCast = NLETemplateJNI.NLETemplateModel_dynamicCast(NLENode.getCPtr(nLENode), nLENode);
        if (NLETemplateModel_dynamicCast == 0) {
            nLETemplateModel = null;
        } else {
            nLETemplateModel = new NLETemplateModel(NLETemplateModel_dynamicCast, true);
        }
        MethodCollector.o(12524);
        return nLETemplateModel;
    }

    public static SetString featureListInTemplateModel(String str) {
        MethodCollector.i(7876);
        SetString setString = new SetString(NLETemplateJNI.NLETemplateModel_featureListInTemplateModel(str));
        MethodCollector.o(7876);
        return setString;
    }

    public static NLETemplateModel restore(String str) {
        NLETemplateModel nLETemplateModel;
        MethodCollector.i(7288);
        long NLETemplateModel_restore = NLETemplateJNI.NLETemplateModel_restore(str);
        if (NLETemplateModel_restore == 0) {
            nLETemplateModel = null;
        } else {
            nLETemplateModel = new NLETemplateModel(NLETemplateModel_restore, true);
        }
        MethodCollector.o(7288);
        return nLETemplateModel;
    }

    public static NLETemplateModel restoreFromPath(String str) {
        NLETemplateModel nLETemplateModel;
        MethodCollector.i(7500);
        long NLETemplateModel_restoreFromPath = NLETemplateJNI.NLETemplateModel_restoreFromPath(str);
        if (NLETemplateModel_restoreFromPath == 0) {
            nLETemplateModel = null;
        } else {
            nLETemplateModel = new NLETemplateModel(NLETemplateModel_restoreFromPath, true);
        }
        MethodCollector.o(7500);
        return nLETemplateModel;
    }

    public VecNLETextTemplateClipSPtr getAllMutableTextClipsFromSlot(NLETrackSlot nLETrackSlot) {
        MethodCollector.i(9280);
        NLETrackSlot nLETrackSlot2 = nLETrackSlot;
        VecNLETextTemplateClipSPtr vecNLETextTemplateClipSPtr = new VecNLETextTemplateClipSPtr(NLETemplateJNI.NLETemplateModel_getAllMutableTextClipsFromSlot(this.swigCPtr, this, NLETrackSlot.LIZ(nLETrackSlot2), nLETrackSlot2));
        MethodCollector.o(9280);
        return vecNLETextTemplateClipSPtr;
    }

    public void setTemplateInfo(TemplateInfo templateInfo) {
        long j;
        MethodCollector.i(12526);
        long j2 = this.swigCPtr;
        TemplateInfo templateInfo2 = templateInfo;
        if (templateInfo2 == null) {
            j = 0;
        } else {
            j = templateInfo2.LIZ;
        }
        NLETemplateJNI.NLETemplateModel_setTemplateInfo(j2, this, j, templateInfo2);
        MethodCollector.o(12526);
    }

    public NLEMappingNode convertNLEMappingNode(NLENode nLENode) {
        NLEMappingNode nLEMappingNode;
        MethodCollector.i(9278);
        NLENode nLENode2 = nLENode;
        long NLETemplateModel_convertNLEMappingNode = NLETemplateJNI.NLETemplateModel_convertNLEMappingNode(this.swigCPtr, this, NLENode.getCPtr(nLENode2), nLENode2);
        if (NLETemplateModel_convertNLEMappingNode == 0) {
            nLEMappingNode = null;
        } else {
            nLEMappingNode = new NLEMappingNode(NLETemplateModel_convertNLEMappingNode);
        }
        MethodCollector.o(9278);
        return nLEMappingNode;
    }

    public void updateResourcePath(String str, String str2) {
        MethodCollector.i(9486);
        NLETemplateJNI.NLETemplateModel_updateResourcePath(this.swigCPtr, this, str, str2);
        MethodCollector.o(9486);
    }

    public NLETemplateModel(long j, boolean z) {
        super(NLETemplateJNI.NLETemplateModel_SWIGSmartPtrUpcast(j), true);
        MethodCollector.i(12298);
        this.swigCMemOwnDerived = z;
        this.swigCPtr = j;
        MethodCollector.o(12298);
    }

    public String storeToZip(String str, String str2, NLEBaseTemplateZipProgressHandler nLEBaseTemplateZipProgressHandler) {
        MethodCollector.i(12997);
        NLEBaseTemplateZipProgressHandler nLEBaseTemplateZipProgressHandler2 = nLEBaseTemplateZipProgressHandler;
        String str3 = str;
        String NLETemplateModel_storeToZip = NLETemplateJNI.NLETemplateModel_storeToZip(this.swigCPtr, this, str3, str2, NLEBaseTemplateZipProgressHandler.getCPtr(nLEBaseTemplateZipProgressHandler2), nLEBaseTemplateZipProgressHandler2);
        MethodCollector.o(12997);
        return NLETemplateModel_storeToZip;
    }
}
