//
// Build schema dictionary out of the "train" set
//
File dictDir = new File(workingDir, "dict");
SchemaDictionary sd = new SchemaDictionary(dictDir);
System.err.println("Building schema dictionary...");
try {
// Insert the files
File targetList[] = trainDbDir.listFiles();
for (int i = 0; i < targetList.length; i++) {
File f = targetList[i];
if (f.getName().endsWith(".avro")) {
sd.addDictionaryElt(f, f.getName());
if (i >= maxDictSize) {
break;
}
}
}