org.robovm.llvm.binding.BasicBlockRefArray Maven / Gradle / Ivy
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.4
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
package org.robovm.llvm.binding;
public class BasicBlockRefArray {
private long swigCPtr;
protected boolean swigCMemOwn;
protected BasicBlockRefArray(long cPtr, boolean cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = cPtr;
}
protected static long getCPtr(BasicBlockRefArray obj) {
return (obj == null) ? 0 : obj.swigCPtr;
}
protected void finalize() {
delete();
}
public synchronized void delete() {
if (swigCPtr != 0) {
if (swigCMemOwn) {
swigCMemOwn = false;
LLVMJNI.delete_BasicBlockRefArray(swigCPtr);
}
swigCPtr = 0;
}
}
public void setValue(BasicBlockRef value) {
LLVMJNI.BasicBlockRefArray_value_set(swigCPtr, this, BasicBlockRef.getCPtr(value));
}
public BasicBlockRef getValue() {
long cPtr = LLVMJNI.BasicBlockRefArray_value_get(swigCPtr, this);
return (cPtr == 0) ? null : new BasicBlockRef(cPtr, false);
}
public BasicBlockRefArray(int nelements) {
this(LLVMJNI.new_BasicBlockRefArray(nelements), true);
}
public BasicBlockRef get(int index) {
long cPtr = LLVMJNI.BasicBlockRefArray_get(swigCPtr, this, index);
return (cPtr == 0) ? null : new BasicBlockRef(cPtr, false);
}
public void set(int index, BasicBlockRef value) {
LLVMJNI.BasicBlockRefArray_set(swigCPtr, this, index, BasicBlockRef.getCPtr(value));
}
}