jmathlib.toolbox.io
Class load

java.lang.Object
  extended by jmathlib.core.interpreter.RootObject
      extended by jmathlib.core.functions.Function
          extended by jmathlib.core.functions.ExternalFunction
              extended by jmathlib.toolbox.io.load
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, ErrorCodes, TokenConstants

public class load
extends ExternalFunction

An external function for loading a matrix from a csv file

See Also:
Serialized Form

Field Summary
(package private)  byte[] b
           
(package private) static byte miCOMPRESSED
           
(package private) static byte miDOUBLE
           
(package private) static byte miINI64
           
(package private) static byte miINT16
           
(package private) static byte miINT32
           
(package private) static byte miINT8
           
(package private) static byte[] miLength
           
(package private) static byte miMATRIX
           
(package private) static byte miSINGLE
           
(package private) static byte miUINT16
           
(package private) static byte miUINT32
           
(package private) static byte miUINT64
           
(package private) static byte miUINT8
           
(package private) static byte miUTF16
           
(package private) static byte miUTF32
           
(package private) static byte miUTF8
           
(package private) static byte mxCELL
           
(package private) static byte mxCHAR
           
(package private) static byte mxDOUBLE
           
(package private) static byte mxINT16
           
(package private) static byte mxINT32
           
(package private) static byte mxINT8
           
(package private) static byte mxOBJECT
           
(package private) static byte mxSINGLE
           
(package private) static byte mxSPARSE
           
(package private) static byte mxSTRUCT
           
(package private) static byte mxUINT16
           
(package private) static byte mxUINT32
           
(package private) static byte mxUINT8
           
 
Fields inherited from class jmathlib.core.functions.ExternalFunction
IMAG, REAL
 
Fields inherited from class jmathlib.core.functions.Function
lastModified, name, pathAndFileName
 
Fields inherited from interface jmathlib.core.constants.ErrorCodes
ERR_BRACKET_OPEN, ERR_BRACKET_ORDER, ERR_FUNCTION_NOT_FOUND, ERR_FUNCTION_NOT_IMPLEMENTED, ERR_INSUFFICIENT_PARAMETERS, ERR_INVALID_PARAMETER, ERR_LVALUE_REQUIRED, ERR_MATRIX_SINGULAR, ERR_NOT_SQUARE_MATRIX, ERR_OPNOTSUPPORTED, ERR_TOO_MANY_PARAMETERS, ERR_USER_ERROR, ERR_VARIABLE_NOTDEFINED, OK, OK_FUNCTION_PROCESS
 
Fields inherited from interface jmathlib.core.constants.TokenConstants
ADDSUB_PRIORITY, AND_PRIORITY, ANDAND_PRIORITY, ASSIGN_PRIORITY, BRACKET_PRIORITY, COMPARE_PRIORITY, CONCAT, MATRIX, MULDIV_PRIORITY, OR_PRIORITY, OROR_PRIORITY, PARAMETER, POWER_PRIORITY, RELATION_PRIORITY, SINGLE, ttDelimiter, ttNotSet, ttOperand, ttOperator
 
Constructor Summary
load()
           
 
Method Summary
 OperandToken evaluate(Token[] operands, GlobalValues globals)
          Check that the operand is a string then open the file referenced.
private  void swap(byte[] c, int len, boolean _swapEndian)
          swap bytes if type of endian coding is necessary
 
Methods inherited from class jmathlib.core.functions.ExternalFunction
getParamCount
 
Methods inherited from class jmathlib.core.functions.Function
debugLine, equals, getLastModified, getName, getNArgIn, getNArgOut, getNoOfLeftHandArguments, getPathAndFileName, setLastModified, setName, setNoOfLeftHandArguments, setPathAndFileName, throwMathLibException
 
Methods inherited from class jmathlib.core.interpreter.RootObject
clone, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

miINT8

static final byte miINT8
See Also:
Constant Field Values

miUINT8

static final byte miUINT8
See Also:
Constant Field Values

miINT16

static final byte miINT16
See Also:
Constant Field Values

miUINT16

static final byte miUINT16
See Also:
Constant Field Values

miINT32

static final byte miINT32
See Also:
Constant Field Values

miUINT32

static final byte miUINT32
See Also:
Constant Field Values

miSINGLE

static final byte miSINGLE
See Also:
Constant Field Values

miDOUBLE

static final byte miDOUBLE
See Also:
Constant Field Values

miINI64

static final byte miINI64
See Also:
Constant Field Values

miUINT64

static final byte miUINT64
See Also:
Constant Field Values

miMATRIX

static final byte miMATRIX
See Also:
Constant Field Values

miCOMPRESSED

static final byte miCOMPRESSED
See Also:
Constant Field Values

miUTF8

static final byte miUTF8
See Also:
Constant Field Values

miUTF16

static final byte miUTF16
See Also:
Constant Field Values

miUTF32

static final byte miUTF32
See Also:
Constant Field Values

miLength

static final byte[] miLength

mxCELL

static final byte mxCELL
See Also:
Constant Field Values

mxSTRUCT

static final byte mxSTRUCT
See Also:
Constant Field Values

mxOBJECT

static final byte mxOBJECT
See Also:
Constant Field Values

mxCHAR

static final byte mxCHAR
See Also:
Constant Field Values

mxSPARSE

static final byte mxSPARSE
See Also:
Constant Field Values

mxDOUBLE

static final byte mxDOUBLE
See Also:
Constant Field Values

mxSINGLE

static final byte mxSINGLE
See Also:
Constant Field Values

mxINT8

static final byte mxINT8
See Also:
Constant Field Values

mxUINT8

static final byte mxUINT8
See Also:
Constant Field Values

mxINT16

static final byte mxINT16
See Also:
Constant Field Values

mxUINT16

static final byte mxUINT16
See Also:
Constant Field Values

mxINT32

static final byte mxINT32
See Also:
Constant Field Values

mxUINT32

static final byte mxUINT32
See Also:
Constant Field Values

b

byte[] b
Constructor Detail

load

public load()
Method Detail

evaluate

public OperandToken evaluate(Token[] operands,
                             GlobalValues globals)
Check that the operand is a string then open the file referenced.

Specified by:
evaluate in class Function
Parameters:
operands[0] - = string which specifies the csv file to load
operands[1] - = the start row (optional)
operands[2] - = the start column (optional)
operands[3] - = range(optional, not implemented)
Returns:
the matrix as an OperandToken

swap

private void swap(byte[] c,
                  int len,
                  boolean _swapEndian)
swap bytes if type of endian coding is necessary

Parameters:
c -
len -

FOOTER

BOTTOM