it.ssc.step.sort.SaveArrayOrderedToMemory Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jsr331-ssc Show documentation
Show all versions of jsr331-ssc Show documentation
This is a JSR331 interface for SSC (Software for the Calculation of the Simplex) is a java library for solving linear programming problems v. 3.0.1.
SSC was designed and developed by Stefano Scarioli.
The newest version!
package it.ssc.step.sort;
import it.ssc.dynamic_source.DynamicClassSortInterface;
public class SaveArrayOrderedToMemory implements MyIterator {
private DynamicClassSortInterface[] array;
private int index=0;
public boolean hasNext() {
if(this.index < array.length) return true;
else return false;
}
public DynamicClassSortInterface next() {
return array[this.index++];
}
public void close() {
array=null;
}
public void saveToMemory(DynamicClassSortInterface[] array) {
this.array=array;
}
}