Пример #1
0
 static ColumnMetadata build(TableMetadata tm, Row row) {
   try {
     String name = row.getString(COLUMN_NAME);
     AbstractType<?> t = TypeParser.parse(row.getString(VALIDATOR));
     ColumnMetadata cm = new ColumnMetadata(tm, name, Codec.rawTypeToDataType(t), row);
     tm.add(cm);
     return cm;
   } catch (RequestValidationException e) {
     // The server will have validated the type
     throw new RuntimeException(e);
   }
 }