Interface ColGroupIO
public interface ColGroupIO
IO for ColGroups, it enables read and write ColGroups
-
Field Summary
Fields -
Method Summary
Static MethodsModifier and TypeMethodDescriptionstatic longgetExactSizeOnDisk(List<AColGroup> colGroups) Get the size on disk for the given list of column groupsstatic AColGroupreadColGroup(DataInput in, int nRows) static double[]readDoubleArray(int length, DataInput in) readGroups(DataInput in, int nRows) Read groups from a file.static voidwriteGroups(DataOutput out, Collection<AColGroup> colGroups) Writes the ColGroups out to the DataOutput.
-
Field Details
-
LOG
static final org.apache.commons.logging.Log LOG
-
-
Method Details
-
readGroups
Read groups from a file. Note that the information about how many should be in the file already.- Parameters:
in- The Data input object to read from.nRows- The number of rows in the read groups.- Returns:
- Return a List containing the ColGroups from the DataInput.
- Throws:
IOException- Throws IO Exception if the in refuses to read data.
-
writeGroups
Writes the ColGroups out to the DataOutput.- Parameters:
out- The DataOutput the ColGroups are written tocolGroups- List of the ColGroups to write to file.- Throws:
IOException- Throws IO Exception if the out refuses to write.
-
getExactSizeOnDisk
Get the size on disk for the given list of column groups- Parameters:
colGroups- A List of column groups to see the disk space required for.- Returns:
- The exact disk size required for writing the compressed matrix.
-
readColGroup
- Throws:
IOException
-
readDoubleArray
- Throws:
IOException
-