import jtransit.tags.TagResultArray; public class ArrayInfoBean { private TagResultArray array; public void setArrayValue( TagResultArray array ) { // This line allows the original JTransit array // to be modified: // this.array = array; // // If you want to make sure the original array can't be // modified, use the following code instead (it's slower // because it creates a copy of the array): // // this.array = new TagResultArray( array ); } public int getNumCols() { return array.getNumCols(); } public int getNumRows() { return array.getNumRows(); } public double getAverage() { return array.average(); } public double getMax() { return array.max(); } public double getMin() { return array.min(); } public void doStuff() { // array.getCell( int row, int col ) // or array.getCell( int row, String colName ) will return data // (row and col start with 1) } }