Map<String, Integer> results = getResultsFrom(log);
final String rawOutput = readOutputFrom(log);
return Collections2.transform(results.entrySet(), new Function<Map.Entry<String, Integer>, WarningRecord>(){
@Override
public WarningRecord apply(Map.Entry<String, Integer> from) {
return WarningRecord.newRecord(version, new WarningSource(id, from.getKey()), from.getValue(), rawOutput,
baseDir);
}
});
}