private CatalogTable validatePartitionedTable(ObjectPath tablePath)
		throws TableNotExistException, TableNotPartitionedException {

		CatalogBaseTable baseTable = getTable(tablePath);

		if (!(baseTable instanceof CatalogTable)) {
			throw new CatalogException(
				String.format("%s in Catalog %s is not a CatalogTable", tablePath.getFullName(), catalogName));
		}

		CatalogTable table = (CatalogTable) baseTable;

		if (!table.isPartitioned()) {
			throw new TableNotPartitionedException(catalogName, tablePath);
		}

		return table;
	}
private CatalogTable validatePartitionedTable ( ObjectPath tablePath ) throws TableNotExistException , TableNotPartitionedException { CatalogBaseTable baseTable = getTable ( tablePath ) ; if ( ! ( baseTable instanceof CatalogTable ) ) { throw new CatalogException ( String . format ( "%s in Catalog %s is not a CatalogTable" , tablePath . getFullName ( ) , catalogName ) ) ; } CatalogTable table = ( CatalogTable ) baseTable ; if ( ! table . isPartitioned ( ) ) { throw new TableNotPartitionedException ( catalogName , tablePath ) ; } return table ; }
Validate the partitioned table.