/******************************************************* Mosel User Guide Example Problems ================================= file ugstreamdense.java ``````````````````````` Exchanging data between model and host application using Java streams. - Dense data - (c) 2008 Fair Isaac Corporation author: S. Heipcke, July 2008 ********************************************************/ import java.io.*; import java.nio.*; import com.dashoptimization.*; public class ugstreamdense { // Input data static final double[] vdata={15,100,90,60,40,15,10, 1}; // VALUE static final double[] wdata={ 2, 20,20,30,40,30,60,10}; // WEIGHT // Array to receive solution values static final int SOLSIZE=8; static double[] solution = new double[SOLSIZE]; // A stream to send the 'MyData' array in a form suitable for the 'raw:' driver public static class MyInitStream extends InputStream { int ndx; double mydata[]; MyInitStream(double data[]) { ndx=0; mydata=data; } public int read(byte[] b) { ByteBuffer buf; byte [] bs; if(ndx