/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 3.0.7
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
* ----------------------------------------------------------------------------- */
package com.revolsys.gis.esri.gdb.file.capi.swig;
public class EnumRows implements java.io.Closeable {
protected static long getCPtr(final EnumRows obj) {
return obj == null ? 0 : obj.swigCPtr;
}
private transient long swigCPtr;
protected transient boolean swigCMemOwn;
public EnumRows() {
this(EsriFileGdbJNI.new_EnumRows(), true);
}
protected EnumRows(final long cPtr, final boolean cMemoryOwn) {
this.swigCMemOwn = cMemoryOwn;
this.swigCPtr = cPtr;
}
@Override
public void close() {
Close();
delete();
}
public void Close() {
EsriFileGdbJNI.EnumRows_Close(this.swigCPtr, this);
}
public synchronized void delete() {
if (this.swigCPtr != 0) {
if (this.swigCMemOwn) {
this.swigCMemOwn = false;
EsriFileGdbJNI.delete_EnumRows(this.swigCPtr);
}
this.swigCPtr = 0;
}
}
@Override
protected void finalize() {
}
public Row next() {
final long cPtr = EsriFileGdbJNI.EnumRows_next(this.swigCPtr, this);
return cPtr == 0 ? null : new Row(cPtr, true);
}
}