private static < T > void readFields ( BufferedReader reader , DatabaseTableConfig < T > config ) throws SQLException { List < DatabaseFieldConfig > fields = new ArrayList < DatabaseFieldConfig > ( ) ; while ( true ) { String line ; try { line = reader . readLine ( ) ; } catch ( IOException e ) { throw SqlExceptionUtil . create ( "Could not read next field from config file" , e ) ; } if ( line == null || line . equals ( CONFIG_FILE_FIELDS_END ) ) { break ; } DatabaseFieldConfig fieldConfig = DatabaseFieldConfigLoader . fromReader ( reader ) ; if ( fieldConfig == null ) { break ; } fields . add ( fieldConfig ) ; } config . setFieldConfigs ( fields ) ; }
Read all of the fields information from the configuration file .