Class CacheDataInput
- java.lang.Object
- 
- org.apache.sysds.runtime.controlprogram.caching.CacheDataInput
 
- 
- All Implemented Interfaces:
- DataInput,- MatrixBlockDataInput
 
 public class CacheDataInput extends Object implements DataInput, MatrixBlockDataInput 
- 
- 
Constructor SummaryConstructors Constructor Description CacheDataInput(byte[] mem)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanreadBoolean()bytereadByte()charreadChar()doublereadDouble()longreadDoubleArray(int len, double[] varr)Reads the double array from the data input into the given dense block and returns the number of non-zeros.floatreadFloat()voidreadFully(byte[] b)voidreadFully(byte[] b, int off, int len)intreadInt()StringreadLine()longreadLong()shortreadShort()longreadSparseRows(int rlen, long nnz, SparseBlock rows)Reads the sparse rows array from the data input into a sparse block and returns the number of non-zeros.intreadUnsignedByte()intreadUnsignedShort()StringreadUTF()intskipBytes(int n)
 
- 
- 
- 
Method Detail- 
readFullypublic void readFully(byte[] b) throws IOException- Specified by:
- readFullyin interface- DataInput
- Throws:
- IOException
 
 - 
readFullypublic void readFully(byte[] b, int off, int len) throws IOException- Specified by:
- readFullyin interface- DataInput
- Throws:
- IOException
 
 - 
skipBytespublic int skipBytes(int n) throws IOException- Specified by:
- skipBytesin interface- DataInput
- Throws:
- IOException
 
 - 
readBooleanpublic boolean readBoolean() throws IOException- Specified by:
- readBooleanin interface- DataInput
- Throws:
- IOException
 
 - 
readBytepublic byte readByte() throws IOException- Specified by:
- readBytein interface- DataInput
- Throws:
- IOException
 
 - 
readUnsignedBytepublic int readUnsignedByte() throws IOException- Specified by:
- readUnsignedBytein interface- DataInput
- Throws:
- IOException
 
 - 
readShortpublic short readShort() throws IOException- Specified by:
- readShortin interface- DataInput
- Throws:
- IOException
 
 - 
readUnsignedShortpublic int readUnsignedShort() throws IOException- Specified by:
- readUnsignedShortin interface- DataInput
- Throws:
- IOException
 
 - 
readCharpublic char readChar() throws IOException- Specified by:
- readCharin interface- DataInput
- Throws:
- IOException
 
 - 
readIntpublic int readInt() throws IOException- Specified by:
- readIntin interface- DataInput
- Throws:
- IOException
 
 - 
readLongpublic long readLong() throws IOException- Specified by:
- readLongin interface- DataInput
- Throws:
- IOException
 
 - 
readFloatpublic float readFloat() throws IOException- Specified by:
- readFloatin interface- DataInput
- Throws:
- IOException
 
 - 
readDoublepublic double readDouble() throws IOException- Specified by:
- readDoublein interface- DataInput
- Throws:
- IOException
 
 - 
readLinepublic String readLine() throws IOException - Specified by:
- readLinein interface- DataInput
- Throws:
- IOException
 
 - 
readUTFpublic String readUTF() throws IOException - Specified by:
- readUTFin interface- DataInput
- Throws:
- IOException
 
 - 
readDoubleArraypublic long readDoubleArray(int len, double[] varr) throws IOExceptionDescription copied from interface:MatrixBlockDataInputReads the double array from the data input into the given dense block and returns the number of non-zeros.- Specified by:
- readDoubleArrayin interface- MatrixBlockDataInput
- Parameters:
- len- ?
- varr- ?
- Returns:
- number of non-zeros
- Throws:
- IOException- if IOException occurs
 
 - 
readSparseRowspublic long readSparseRows(int rlen, long nnz, SparseBlock rows) throws IOExceptionDescription copied from interface:MatrixBlockDataInputReads the sparse rows array from the data input into a sparse block and returns the number of non-zeros.- Specified by:
- readSparseRowsin interface- MatrixBlockDataInput
- Parameters:
- rlen- number of rows
- nnz- number of non-zeros
- rows- sparse block
- Returns:
- number of non-zeros
- Throws:
- IOException- if IOExcepton occurs
 
 
- 
 
-