xsdHelper = XSDHelper.INSTANCE;
} else {
extendedMetaData = (ExtendedMetaData) option;
xsdHelper = (new HelperContextImpl(extendedMetaData, false)).getXSDHelper();
}
xmlOptions.setEcoreBuilder(new DefaultEcoreBuilder(extendedMetaData) {
public Collection generate(Map targetNamespaceToURI) throws IOException {
for (Iterator iterator = targetNamespaceToURI.values().iterator(); iterator.hasNext();) {
String uri = iterator.next().toString();
xsdHelper.define(uri.indexOf(":/") == -1 ? Thread.currentThread().getContextClassLoader().getResourceAsStream(uri)
: new URL(uri).openStream(), uri);