} else {
log.info("Writing to stdout");
out = System.out;
}
MappingGenerator generator = loader.openMappingGenerator();
try {
if (cmd.contains(vocabAsOutput)) {
Model model = generator.vocabularyModel();
model.write(out, "TURTLE");
} else {
generator.writeMapping(out);
}
} finally {
loader.closeMappingGenerator();
}
}