* @return
*/
@SuppressWarnings({"unchecked", "rawtypes"})
protected ColumnFamily getColumnFamilyViaColumnName(String columnFamilyName, Class rowKeyClass) {
if (rowKeyClass == String.class) {
return new ColumnFamily(columnFamilyName, StringSerializer.get(), StringSerializer.get());
} else if (rowKeyClass == Integer.class) {
return new ColumnFamily(columnFamilyName, IntegerSerializer.get(), StringSerializer.get());
} else if (rowKeyClass == Long.class) {
return new ColumnFamily(columnFamilyName, LongSerializer.get(), StringSerializer.get());
} else {
throw new IllegalArgumentException("RowKeyType is not supported: " + rowKeyClass.getSimpleName() + ". String/Integer/Long are supported, or you can define the ColumnFamily yourself and use the other constructor.");
}
}