the value stored in the column named 'info:name' with a timestamp of 42. final String name = row.getValue("info", "name", 42L);
We also provide additional methods for accessing data stored withing a row. See the documentation below for methods with the name 'get*' for more information.
Checking for existence of cells
Since rows within a Kiji table may not contain all the columns defined within a layout we need a way to check this in code. KijiRowData contains several methods to help with this:
final KijiRowData row = myTableReader.get(myEntityId, myDataRequest); if (row.containsColumn("info", "name")) { // Now that we know the cell exists, read the value. final String name = row.getMostRecentValue("info", "name"); } if (row.containsCell("info", "name", 42L)) { // Now that we know that this cell exists at the timestamp of 42. final String name = row.getValue("info", "name", 42L); }
Dealing with large rows
Rows in Kiji tables may contain large amounts of data. In some cases, this is caused by storing many versions of a cell with different timestamps in a row. This can become a problem when the size of a row/cell exceeds the amount of RAM available. To deal with large rows, you may use paging through a {@link KijiPager}. When paging is enabled on a column, cells from that column may only be accessed through {@link #getPager(String)} and {@link #getPager(String,String)}. See the documentation for {@link KijiPager} for more information.