}
static TableDescriptorModtime getTableDescriptorModtime(FileSystem fs, Path tableDir)
throws NullPointerException, IOException {
if (tableDir == null) throw new NullPointerException();
FileStatus status = getTableInfoPath(fs, tableDir);
if (status == null) {
throw new TableInfoMissingException("No .tableinfo file under "
+ tableDir.toUri());
}
FSDataInputStream fsDataInputStream = fs.open(status.getPath());
HTableDescriptor hTableDescriptor = null;
try {
hTableDescriptor = new HTableDescriptor();
hTableDescriptor.readFields(fsDataInputStream);
} finally {
fsDataInputStream.close();
}
return new TableDescriptorModtime(status.getModificationTime(), hTableDescriptor);
}