private Logger getLogger() {
return LoggingUtils.getLogger(this);
}
private void initialize(File file) throws TaskConfigurationException {
XmlDocument document = null;
try {
document = new XmlDocument(file);
} catch (Exception ex) {
this.getLogger().severe("Error parsing document: " + ex.getMessage());
throw new TaskConfigurationException("Error parsing document: " + ex.getMessage());
}
if (null == document) {
this.getLogger().severe("Invalid document: " + file.getAbsoluteFile());
throw new TaskConfigurationException("Invalid document: " + file.getAbsoluteFile());
}
XmlNode documentRoot = document.getDocumentElement();
if (null == documentRoot) {
this.getLogger().severe("Invalid document root: " + file.getAbsoluteFile());
throw new TaskConfigurationException("Invalid document root: " + file.getAbsoluteFile());
}