package com.bytedance.ies.nle.editor_jni;

import X.AnonymousClass51X;
import com.bytedance.covode.number.Covode;
import com.bytedance.frameworks.apm.trace.MethodCollector;
import java.util.AbstractList;
import java.util.RandomAccess;

public class VecNLETrackType extends AbstractList<AnonymousClass51X> implements RandomAccess {
    public transient boolean LIZ;
    public transient long LIZIZ;

    static {
        Covode.recordClassIndex(29966);
    }

    public void finalize() {
        LIZ();
    }

    public VecNLETrackType() {
        this(NLEEditorJniJNI.new_VecNLETrackType__SWIG_0());
        MethodCollector.i(19003);
        MethodCollector.o(19003);
    }

    public void clear() {
        MethodCollector.i(19005);
        NLEEditorJniJNI.VecNLETrackType_clear(this.LIZIZ, this);
        MethodCollector.o(19005);
    }

    public boolean isEmpty() {
        MethodCollector.i(19004);
        boolean VecNLETrackType_isEmpty = NLEEditorJniJNI.VecNLETrackType_isEmpty(this.LIZIZ, this);
        MethodCollector.o(19004);
        return VecNLETrackType_isEmpty;
    }

    public int size() {
        MethodCollector.i(19002);
        int VecNLETrackType_doSize = NLEEditorJniJNI.VecNLETrackType_doSize(this.LIZIZ, this);
        MethodCollector.o(19002);
        return VecNLETrackType_doSize;
    }

    private synchronized void LIZ() {
        MethodCollector.i(15250);
        long j = this.LIZIZ;
        if (j != 0) {
            if (this.LIZ) {
                this.LIZ = false;
                NLEEditorJniJNI.delete_VecNLETrackType(j);
            }
            this.LIZIZ = 0;
        }
        MethodCollector.o(15250);
    }

    public static long LIZ(VecNLETrackType vecNLETrackType) {
        if (vecNLETrackType == null) {
            return 0;
        }
        return vecNLETrackType.LIZIZ;
    }

    /* renamed from: LIZ */
    public final boolean add(AnonymousClass51X r3) {
        this.modCount++;
        LIZIZ(r3);
        return true;
    }

    public VecNLETrackType(long j) {
        this.LIZ = true;
        this.LIZIZ = j;
    }

    private void LIZIZ(AnonymousClass51X r5) {
        MethodCollector.i(19006);
        NLEEditorJniJNI.VecNLETrackType_doAdd__SWIG_0(this.LIZIZ, this, r5.swigValue());
        MethodCollector.o(19006);
    }

    public /* synthetic */ Object get(int i) {
        MethodCollector.i(19016);
        AnonymousClass51X swigToEnum = AnonymousClass51X.swigToEnum(NLEEditorJniJNI.VecNLETrackType_doGet(this.LIZIZ, this, i));
        MethodCollector.o(19016);
        return swigToEnum;
    }

    public /* synthetic */ Object remove(int i) {
        MethodCollector.i(19008);
        this.modCount++;
        AnonymousClass51X swigToEnum = AnonymousClass51X.swigToEnum(NLEEditorJniJNI.VecNLETrackType_doRemove(this.LIZIZ, this, i));
        MethodCollector.o(19008);
        return swigToEnum;
    }

    public VecNLETrackType(AnonymousClass51X[] r6) {
        this();
        MethodCollector.i(15426);
        NLEEditorJniJNI.VecNLETrackType_reserve(this.LIZIZ, this, 3);
        int i = 0;
        do {
            add(r6[i]);
            i++;
        } while (i < 3);
        MethodCollector.o(15426);
    }

    public /* synthetic */ void add(int i, Object obj) {
        MethodCollector.i(19011);
        this.modCount++;
        NLEEditorJniJNI.VecNLETrackType_doAdd__SWIG_1(this.LIZIZ, this, i, ((AnonymousClass51X) obj).swigValue());
        MethodCollector.o(19011);
    }

    public void removeRange(int i, int i2) {
        MethodCollector.i(15427);
        this.modCount++;
        NLEEditorJniJNI.VecNLETrackType_doRemoveRange(this.LIZIZ, this, i, i2);
        MethodCollector.o(15427);
    }

    public /* synthetic */ Object set(int i, Object obj) {
        MethodCollector.i(19013);
        AnonymousClass51X swigToEnum = AnonymousClass51X.swigToEnum(NLEEditorJniJNI.VecNLETrackType_doSet(this.LIZIZ, this, i, ((AnonymousClass51X) obj).swigValue()));
        MethodCollector.o(19013);
        return swigToEnum;
    }
}
