Hi
I am working on a java service. One of the methods takes in a task ID and returns list of files attached to that task.
try {
task = client.getTask(taskID);
if (task == null) {
throw new TaskIdInvalidException("Task Id is Invalid");
}
CSAreaRelativePath[] taskFiles = task.getFiles();
for (CSAreaRelativePath path : taskFiles) {
CSFile file = task.getArea().getFile(path);
if (file != null) {
attachedFiles.add(FileHandler.populateFileBean(file.getVPath().toString(), client));
}
}
} catch (Exception ex) {
LOGGER.error("Exception: " + ex.toString());
// LOGGER.debug("StackTrace:", ex);
}
If a user passes an invalid task ID, the method keeps throwing the below exception
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/xerces/util/DOMUtil
Any idea how can I capture this error? I expect the method to throw NullPointerException
Thanks
Teamsite 6.7
Solaris