in core/src/main/java/org/apache/sdap/mudrod/ontology/pre/AggregateTriples.java [55:85]
public Object execute() {
File file = new File(this.props.getProperty(MudrodConstants.ONTOLOGY_PATH));
if (file.exists()) {
file.delete();
}
try {
file.createNewFile();
} catch (IOException e2) {
LOG.error("File creation failed: ", e2);
}
try(OutputStreamWriter osw = new OutputStreamWriter(new FileOutputStream(file.getAbsoluteFile()), StandardCharsets.UTF_8)) {
OSW = osw;
File[] files = new File(this.props.getProperty(MudrodConstants.ONTOLOGY_INPUT_PATH)).listFiles();
for (File fileIn : files) {
String ext = FilenameUtils.getExtension(fileIn.getAbsolutePath());
if ("owl".equals(ext)) {
try {
loadXml(fileIn.getAbsolutePath());
getAllClass();
} catch (JDOMException | IOException e1) {
LOG.error("Couldn't load Owl file into memory: ", e1);
}
}
}
} catch (IOException e) {
LOG.error("Couldn't open file!", e);
}
return null;
}