*/
private HashMap getTargetNameSpaces(Collection<SQLXML> schemas) throws TeiidException {
HashMap nameSpaceMap = new HashMap();
SAXParserFactory spf = SAXParserFactory.newInstance();
spf.setNamespaceAware(true);
SAXParser parser;
try {
parser = spf.newSAXParser();
} catch (ParserConfigurationException err) {
throw new TeiidException(err);
} catch (SAXException err) {
throw new TeiidException(err);
}
PeekContentHandler pch = new PeekContentHandler();
for (SQLXML schema : schemas) {
InputStream is;
try {
is = schema.getBinaryStream();
} catch (SQLException e) {
throw new TeiidComponentException(e);
}
InputSource source = new InputSource(is);
pch.targetNameSpace = null;
try {
parser.parse(source, pch);
} catch (SAXException err) {
throw new TeiidException(err);
} catch (IOException err) {
throw new TeiidComponentException(err);
} finally {