jAER project on SourceForge

net.sf.jaer.stereopsis
Class MatrixLoader

java.lang.Object
  extended by net.sf.jaer.stereopsis.MatrixLoader

public class MatrixLoader
extends java.lang.Object

A conveniance function which loads a matrix into a 2D array. The data is row-wise loaded from a textfile with space-delimited numbers. The array will be automatically allocated to the size of the loaded matrix. If not all rows have the same size, the longest row will determine the row length and unspecified values will be 0. If file loading should file, the returnd matrix will be of size 1x1 with value 0.

Author:
Peter Hess

Constructor Summary
MatrixLoader()
          Creates a new instance of MatrixLoader
 
Method Summary
static int[][] loadInt(java.lang.String file)
          Loads the values of the stored matrix as integers from the specified file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MatrixLoader

public MatrixLoader()
Creates a new instance of MatrixLoader

Method Detail

loadInt

public static int[][] loadInt(java.lang.String file)
Loads the values of the stored matrix as integers from the specified file.


jAER project on SourceForge