if (routes == null) {
CamelComponentMessages.MESSAGES.noRoutesFoundInXMLFile(xmlPath);
}
return routes;
} catch (SAXException e) {
throw new SwitchYardException(e);
} catch (ParserConfigurationException e) {
throw new SwitchYardException(e);
} catch (JAXBException e) {
throw new SwitchYardException(e);
} catch (IOException e) {
throw new SwitchYardException(e);
}
}