if (name == null || name.equals("")) {
throw new XmlReaderException(Strings.get("compNameMissingError"));
}
String libName = elt.getAttribute("lib");
Library lib = reader.findLibrary(libName);
if (lib == null) {
throw new XmlReaderException(Strings.get("compUnknownError", "no-lib"));
}
Tool tool = lib.getTool(name);
if (tool == null || !(tool instanceof AddTool)) {
if (libName == null || libName.equals("")) {
throw new XmlReaderException(Strings.get("compUnknownError", name));
} else {
throw new XmlReaderException(Strings.get("compAbsentError", name, libName));