/* ----------------------------------------------------------------------------
 * This file was automatically generated by SWIG (http://www.swig.org).
 * Version 2.0.6
 *
 * Do not make changes to this file unless you know what you are doing--modify
 * the SWIG interface file instead.
 * ----------------------------------------------------------------------------- */

package javagiac;

public class vectori {
  private long swigCPtr;
  protected boolean swigCMemOwn;

  protected vectori(long cPtr, boolean cMemoryOwn) {
    swigCMemOwn = cMemoryOwn;
    swigCPtr = cPtr;
  }

  protected static long getCPtr(vectori obj) {
    return (obj == null) ? 0 : obj.swigCPtr;
  }

  protected void finalize() {
    delete();
  }

  public synchronized void delete() {
    if (swigCPtr != 0) {
      if (swigCMemOwn) {
        swigCMemOwn = false;
        giacJNI.delete_vectori(swigCPtr);
      }
      swigCPtr = 0;
    }
  }

  public vectori() {
    this(giacJNI.new_vectori__SWIG_0(), true);
  }

  public vectori(long n) {
    this(giacJNI.new_vectori__SWIG_1(n), true);
  }

  public long size() {
    return giacJNI.vectori_size(swigCPtr, this);
  }

  public long capacity() {
    return giacJNI.vectori_capacity(swigCPtr, this);
  }

  public void reserve(long n) {
    giacJNI.vectori_reserve(swigCPtr, this, n);
  }

  public boolean isEmpty() {
    return giacJNI.vectori_isEmpty(swigCPtr, this);
  }

  public void clear() {
    giacJNI.vectori_clear(swigCPtr, this);
  }

  public void add(int x) {
    giacJNI.vectori_add(swigCPtr, this, x);
  }

  public int get(int i) {
    return giacJNI.vectori_get(swigCPtr, this, i);
  }

  public void set(int i, int val) {
    giacJNI.vectori_set(swigCPtr, this, i, val);
  }

}
